mirror of
https://github.com/Z3Prover/z3
synced 2025-09-05 17:47:41 +00:00
refactor
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
This commit is contained in:
parent
4acdd952c2
commit
f74d1fc8ec
4 changed files with 11 additions and 11 deletions
|
@ -48,8 +48,8 @@ namespace nlsat {
|
|||
bool m_signed_project;
|
||||
bool m_cell_sample;
|
||||
|
||||
assignment const & sample() const { return m_solver.get_assignment(); }
|
||||
assignment & sample() { return m_solver.get_assignment(); }
|
||||
assignment const & sample() const { return m_solver.sample(); }
|
||||
assignment & sample() { return m_solver.sample(); }
|
||||
|
||||
struct todo_set {
|
||||
polynomial::cache & m_cache;
|
||||
|
@ -264,7 +264,7 @@ namespace nlsat {
|
|||
polynomial_ref f(m_pm);
|
||||
for (unsigned i = 0; i < num_factors; i++) {
|
||||
f = m_factors.get(i);
|
||||
if (is_zero(sign(f, m_solver.get_assignment(), m_am))) {
|
||||
if (is_zero(sign(f, m_solver.sample(), m_am))) {
|
||||
m_zero_fs.push_back(m_factors.get(i));
|
||||
m_is_even.push_back(false);
|
||||
}
|
||||
|
@ -321,7 +321,7 @@ namespace nlsat {
|
|||
lc = m_pm.coeff(p, x, k, reduct);
|
||||
TRACE(nlsat_explain, tout << "lc: " << lc << " reduct: " << reduct << "\n";);
|
||||
if (!is_zero(lc)) {
|
||||
if (!::is_zero(sign(lc, m_solver.get_assignment(), m_am))) {
|
||||
if (!::is_zero(sign(lc, m_solver.sample(), m_am))) {
|
||||
TRACE(nlsat_explain, tout << "lc does no vaninsh\n";);
|
||||
return;
|
||||
}
|
||||
|
@ -409,7 +409,7 @@ namespace nlsat {
|
|||
if (max_var(p) == max)
|
||||
elim_vanishing(p); // eliminate vanishing coefficients of max
|
||||
if (is_const(p) || max_var(p) < max) {
|
||||
int s = sign(p, m_solver.get_assignment(), m_am);
|
||||
int s = sign(p, m_solver.sample(), m_am);
|
||||
if (!is_const(p)) {
|
||||
SASSERT(max_var(p) != null_var);
|
||||
SASSERT(max_var(p) < max);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue