mirror of
https://github.com/Z3Prover/z3
synced 2025-04-24 01:25:31 +00:00
adding pre-processing to nlsat for equations
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
5bc4c9809e
commit
79a9dfd8fd
11 changed files with 696 additions and 222 deletions
|
@ -44,6 +44,8 @@ namespace nlsat {
|
|||
bool is_learned() const { return m_learned; }
|
||||
literal * begin() { return m_lits; }
|
||||
literal * end() { return m_lits + m_size; }
|
||||
literal const * begin() const { return m_lits; }
|
||||
literal const * end() const { return m_lits + m_size; }
|
||||
literal const * c_ptr() const { return m_lits; }
|
||||
void inc_activity() { m_activity++; }
|
||||
void set_activity(unsigned v) { m_activity = v; }
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -35,7 +35,7 @@ namespace nlsat {
|
|||
struct imp;
|
||||
imp * m_imp;
|
||||
public:
|
||||
solver(reslimit& rlim, params_ref const & p);
|
||||
solver(reslimit& rlim, params_ref const & p, bool incremental);
|
||||
~solver();
|
||||
|
||||
/**
|
||||
|
|
|
@ -47,6 +47,8 @@ namespace nlsat {
|
|||
typedef polynomial::var_vector var_vector;
|
||||
typedef polynomial::manager pmanager;
|
||||
typedef polynomial::polynomial poly;
|
||||
typedef polynomial::monomial monomial;
|
||||
typedef polynomial::numeral numeral;
|
||||
const var null_var = polynomial::null_var;
|
||||
|
||||
const var true_bool_var = 0;
|
||||
|
|
|
@ -32,11 +32,11 @@ class nlsat_tactic : public tactic {
|
|||
ast_manager & m;
|
||||
expr_ref_vector m_var2expr;
|
||||
expr_display_var_proc(ast_manager & _m):m(_m), m_var2expr(_m) {}
|
||||
virtual void operator()(std::ostream & out, nlsat::var x) const {
|
||||
virtual std::ostream& operator()(std::ostream & out, nlsat::var x) const {
|
||||
if (x < m_var2expr.size())
|
||||
out << mk_ismt2_pp(m_var2expr.get(x), m);
|
||||
return out << mk_ismt2_pp(m_var2expr.get(x), m);
|
||||
else
|
||||
out << "x!" << x;
|
||||
return out << "x!" << x;
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -51,7 +51,7 @@ class nlsat_tactic : public tactic {
|
|||
m(_m),
|
||||
m_params(p),
|
||||
m_display_var(_m),
|
||||
m_solver(m.limit(), p) {
|
||||
m_solver(m.limit(), p, false) {
|
||||
}
|
||||
|
||||
void updt_params(params_ref const & p) {
|
||||
|
|
|
@ -48,11 +48,15 @@ tactic * mk_qfnra_nlsat_tactic(ast_manager & m, params_ref const & p) {
|
|||
purify_p),
|
||||
mk_propagate_values_tactic(m, p),
|
||||
mk_solve_eqs_tactic(m, p),
|
||||
using_params(mk_purify_arith_tactic(m, p),
|
||||
purify_p),
|
||||
mk_elim_uncnstr_tactic(m, p),
|
||||
mk_elim_term_ite_tactic(m, p)),
|
||||
and_then(/* mk_degree_shift_tactic(m, p), */ // may affect full dimensionality detection
|
||||
factor,
|
||||
mk_solve_eqs_tactic(m, p),
|
||||
using_params(mk_purify_arith_tactic(m, p),
|
||||
purify_p),
|
||||
using_params(mk_simplify_tactic(m, p),
|
||||
main_p),
|
||||
mk_tseitin_cnf_core_tactic(m, p),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue