3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-10-19 05:42:15 +00:00

First pass at free variable elimination

This commit is contained in:
Jakob Rath 2022-10-31 15:22:03 +01:00
parent 4cdd3bf77d
commit 29695391de
5 changed files with 144 additions and 21 deletions

View file

@ -62,11 +62,13 @@ namespace polysat {
class conflict_resolver {
inf_saturate m_saturate;
ex_polynomial_superposition m_poly_sup;
free_variable_elimination m_free_variable_elimination;
public:
conflict_resolver(solver& s)
: m_saturate(s)
, m_poly_sup(s)
, m_free_variable_elimination(s)
{}
bool try_resolve_value(pvar v, conflict& core) {
@ -76,6 +78,11 @@ namespace polysat {
return true;
return false;
}
// Analyse current conflict core to extract additional lemmas
void find_extra_lemmas(conflict& core) {
m_free_variable_elimination.find_lemma(core);
}
};
class header_with_var : public displayable {
@ -524,6 +531,10 @@ namespace polysat {
clause_ref conflict::build_lemma() {
LOG_H3("Build lemma from core");
LOG("core: " << *this);
// TODO: do this after each step?
m_resolver->find_extra_lemmas(*this);
clause_builder lemma(s);
#if 0