3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-10-07 08:21:56 +00:00

reworking pd-maxres

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2015-08-20 12:06:27 -07:00
parent 980e74b4ff
commit e3cb0e2d8b
13 changed files with 192 additions and 170 deletions

View file

@ -239,7 +239,6 @@ namespace sat {
if (memory::get_allocation_size() > m_config.m_max_memory) throw solver_exception(Z3_MAX_MEMORY_MSG);
}
typedef std::pair<literal, literal> bin_clause;
void initialize_soft(unsigned sz, literal const* lits, double const* weights);
protected:
watch_list & get_wlist(literal l) { return m_watches[l.index()]; }
watch_list const & get_wlist(literal l) const { return m_watches[l.index()]; }
@ -271,7 +270,11 @@ namespace sat {
//
// -----------------------
public:
lbool check(unsigned num_lits = 0, literal const* lits = 0);
lbool check(unsigned num_lits = 0, literal const* lits = 0) {
return check(num_lits, lits, 0, 0);
}
lbool check(unsigned num_lits, literal const* lits, double const* weights, double max_weight);
model const & get_model() const { return m_model; }
bool model_is_current() const { return m_model_is_current; }
literal_vector const& get_core() const { return m_core; }
@ -291,7 +294,8 @@ namespace sat {
bool_var next_var();
lbool bounded_search();
void init_search();
void init_assumptions(unsigned num_lits, literal const* lits);
void init_assumptions(unsigned num_lits, literal const* lits, double const* weights, double max_weight);
bool init_weighted_assumptions(unsigned num_lits, literal const* lits, double const* weights, double max_weight, svector<literal>& blocker);
void reinit_assumptions();
bool tracking_assumptions() const;
bool is_assumption(literal l) const;