mirror of
https://github.com/Z3Prover/z3
synced 2025-04-29 03:45:51 +00:00
align lengths of weights and soft constraints
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
ddbff6f77b
commit
1c56d6ee95
4 changed files with 14 additions and 6 deletions
|
@ -179,7 +179,7 @@ public:
|
|||
lbool mus_mss_solver() {
|
||||
init();
|
||||
init_local();
|
||||
enable_sls(m_asms);
|
||||
sls();
|
||||
ptr_vector<expr> mcs;
|
||||
vector<ptr_vector<expr> > cores;
|
||||
while (m_lower < m_upper) {
|
||||
|
@ -221,7 +221,7 @@ public:
|
|||
lbool mss_solver() {
|
||||
init();
|
||||
init_local();
|
||||
enable_sls(m_asms);
|
||||
sls();
|
||||
set_mus(false);
|
||||
ptr_vector<expr> mcs;
|
||||
lbool is_sat = l_true;
|
||||
|
@ -383,6 +383,14 @@ public:
|
|||
return m_asm2weight.find(e);
|
||||
}
|
||||
|
||||
void sls() {
|
||||
vector<rational> ws;
|
||||
for (unsigned i = 0; i < m_asms.size(); ++i) {
|
||||
ws.push_back(get_weight(m_asms[i].get()));
|
||||
}
|
||||
enable_sls(m_asms, ws);
|
||||
}
|
||||
|
||||
rational split_core(ptr_vector<expr> const& core) {
|
||||
|
||||
// find the minimal weight:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue