mirror of
https://github.com/Z3Prover/z3
synced 2025-04-23 17:15:31 +00:00
integrating Nikolaj's changes
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
This commit is contained in:
parent
7a5666f1df
commit
c1e0c79a69
3 changed files with 44 additions and 9 deletions
|
@ -16,6 +16,7 @@ namespace nla {
|
|||
// fields
|
||||
lp::var_index m_v;
|
||||
svector<lp::var_index> m_vs;
|
||||
rational m_coeff;
|
||||
public:
|
||||
// constructors
|
||||
monomial(lp::var_index v, unsigned sz, lp::var_index const* vs):
|
||||
|
@ -30,6 +31,8 @@ namespace nla {
|
|||
svector<lp::var_index>::const_iterator begin() const { return m_vs.begin(); }
|
||||
svector<lp::var_index>::const_iterator end() const { return m_vs.end(); }
|
||||
const svector<lp::var_index> vars() const { return m_vs; }
|
||||
bool empty() const { return m_vs.empty(); }
|
||||
const rational& get_coeff() const { return m_coeff; }
|
||||
};
|
||||
|
||||
typedef std::unordered_map<lp::var_index, rational> variable_map_type;
|
||||
|
@ -56,7 +59,7 @@ namespace nla {
|
|||
monomial(v, vs),
|
||||
m_coeff(coeff) {}
|
||||
|
||||
rational const& coeff() const { return m_coeff; }
|
||||
rational const& coeff() const { return m_coeff; }
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -24,6 +24,8 @@ Revision History:
|
|||
#include "util/params.h"
|
||||
#include "nlsat/nlsat_solver.h"
|
||||
#include "util/lp/lar_solver.h"
|
||||
#include "util/lp/monomial.h"
|
||||
|
||||
namespace nla {
|
||||
struct ineq {
|
||||
lp::lconstraint_kind m_cmp;
|
||||
|
@ -36,7 +38,7 @@ struct ineq {
|
|||
};
|
||||
|
||||
typedef vector<ineq> lemma;
|
||||
|
||||
typedef vector<monomial> polynomial;
|
||||
// nonlinear integer incremental linear solver
|
||||
class solver {
|
||||
struct imp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue