mirror of
https://github.com/Z3Prover/z3
synced 2025-04-24 01:25:31 +00:00
gauss jordan
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
361888f299
commit
ad2445e423
8 changed files with 183 additions and 9 deletions
|
@ -79,4 +79,17 @@ namespace arith {
|
|||
lp().settings().stats().collect_statistics(st);
|
||||
if (m_nla) m_nla->collect_statistics(st);
|
||||
}
|
||||
|
||||
char const* solver::bounds_pragma() {
|
||||
if (!ctx.use_drat())
|
||||
return nullptr;
|
||||
m_bounds_pragma.clear();
|
||||
m_bounds_pragma += "bounds ";
|
||||
for (sat::literal c : m_core) {
|
||||
if (c.sign()) m_bounds_pragma += "-";
|
||||
m_bounds_pragma += std::to_string(c.var());
|
||||
m_bounds_pragma += " ";
|
||||
}
|
||||
return m_bounds_pragma.c_str();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -255,7 +255,7 @@ namespace arith {
|
|||
TRACE("arith", for (auto lit : m_core) tout << lit << ": " << s().value(lit) << "\n";);
|
||||
DEBUG_CODE(for (auto lit : m_core) { VERIFY(s().value(lit) == l_true); });
|
||||
++m_stats.m_bound_propagations1;
|
||||
assign(lit, m_core, m_eqs, "bounds");
|
||||
assign(lit, m_core, m_eqs, bounds_pragma());
|
||||
}
|
||||
|
||||
if (should_refine_bounds() && first)
|
||||
|
|
|
@ -419,6 +419,9 @@ namespace arith {
|
|||
void false_case_of_check_nla(const nla::lemma& l);
|
||||
void dbg_finalize_model(model& mdl);
|
||||
|
||||
std::string m_bounds_pragma;
|
||||
char const* bounds_pragma();
|
||||
|
||||
|
||||
public:
|
||||
solver(euf::solver& ctx, theory_id id);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue