3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-07-19 10:52:02 +00:00
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2019-12-20 11:29:08 -08:00
parent 6ad55cc8f6
commit 1f9aff04df
5 changed files with 48 additions and 69 deletions

View file

@ -366,7 +366,7 @@ namespace dd {
// since x is the maximal variable, it does not occur in t or v.
// thus, both a and b are linear in x
bool pdd_manager::spoly_is_invertible(pdd const& a, pdd const& b) {
return a.is_var() && b.is_var() && a.hi().is_val() && b.hi().is_val() && a.var() == b.var();
return !a.is_val() && !b.is_val() && a.hi().is_val() && b.hi().is_val() && a.var() == b.var();
}
/*
@ -617,22 +617,8 @@ namespace dd {
}
unsigned_vector const& pdd_manager::free_vars(pdd const& p) {
return free_vars_except(p, zero());
}
unsigned_vector const& pdd_manager::free_vars_except(pdd const& p, pdd const& q) {
init_mark();
m_free_vars.reset();
m_todo.push_back(q.root);
while (!m_todo.empty()) {
PDD r = m_todo.back();
m_todo.pop_back();
if (is_val(r) || is_marked(r)) continue;
set_mark(r);
set_mark(m_var2pdd[var(r)]);
if (!is_marked(lo(r))) m_todo.push_back(lo(r));
if (!is_marked(hi(r))) m_todo.push_back(hi(r));
}
m_todo.push_back(p.root);
while (!m_todo.empty()) {
PDD r = m_todo.back();