mirror of
https://github.com/Z3Prover/z3
synced 2025-04-23 17:15:31 +00:00
parent
d3e1d250a7
commit
6558999cef
5 changed files with 11 additions and 13 deletions
|
@ -18,8 +18,9 @@ Revision History:
|
|||
|
||||
--*/
|
||||
|
||||
#include "model_based_opt.h"
|
||||
#include "uint_set.h"
|
||||
#include "math/simplex/model_based_opt.h"
|
||||
#include "util/uint_set.h"
|
||||
#include "util/z3_exception.h"
|
||||
|
||||
std::ostream& operator<<(std::ostream& out, opt::ineq_type ie) {
|
||||
switch (ie) {
|
||||
|
@ -868,6 +869,9 @@ namespace opt {
|
|||
for (unsigned i = 0; i < mod_rows.size(); ++i) {
|
||||
D = lcm(D, m_rows[mod_rows[i]].m_mod);
|
||||
}
|
||||
if (D.is_zero()) {
|
||||
throw default_exception("modulo 0 is not defined");
|
||||
}
|
||||
TRACE("opt", display(tout << "lcm: " << D << " tableau\n"););
|
||||
rational val_x = m_var2value[x];
|
||||
rational u = mod(val_x, D);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue