20 for(
auto termIt = _expr.polynomial().begin(); termIt != _expr.polynomial().end(); ++termIt )
22 if( termIt->monomial() )
24 if( !termIt->monomial()->is_linear() )
27 result.emplace_back(
Poly(Poly::PolyType(termIt->monomial()))*_expr.coefficient());
29 result.emplace_back(
Poly(
typename Poly::PolyType(termIt->monomial()))*_expr.coefficient() );
42 if (!std::isinf(_interval.lower())) {
43 Rational bound = carl::rationalize<Rational>( _interval.lower() );
44 Poly leftEx = _lhs - bound;
46 switch( _interval.lower_bound_type() )
48 case carl::BoundType::STRICT:
49 leftTmp =
ConstraintT(leftEx, carl::Relation::GREATER);
51 case carl::BoundType::WEAK:
62 if (!std::isinf(_interval.upper())) {
63 Rational bound = carl::rationalize<Rational>( _interval.upper() );
64 Poly rightEx = _lhs - bound;
66 switch( _interval.upper_bound_type() )
68 case carl::BoundType::STRICT:
69 rightTmp =
ConstraintT(rightEx, carl::Relation::LESS);
71 case carl::BoundType::WEAK:
72 rightTmp =
ConstraintT(rightEx, carl::Relation::LEQ);
79 return std::make_pair( leftTmp, rightTmp );
84 for (
auto intervalIt = _intervals.begin(); intervalIt != _intervals.end(); ++intervalIt )
86 if ( (*intervalIt).second.is_empty() )
101 return (*target).second;
A module which performs the Simplex method on the linear part of it's received formula.
const VarVariableMap & originalVariables() const
std::vector< Poly > getNonlinearMonomials(const Poly &_expr)
Obtains the non-linear monomials of the given polynomial.
std::pair< ConstraintT, ConstraintT > intervalToConstraint(const Poly &_lhs, const smtrat::DoubleInterval _interval)
Creates a new constraint from an existing interval.
const LRAModule< LRASettings1 >::LRAVariable * getOriginalLraVar(carl::Variable::Arg _var, const LRAModule< LRASettings1 > &_lra)
bool intervalBoxContainsEmptyInterval(const EvalDoubleIntervalMap &_intervals)
Checks mIntervals if it contains an empty interval.
Class to create the formulas for axioms.
carl::Interval< double > DoubleInterval
carl::MultivariatePolynomial< Rational > Poly
carl::Constraint< Poly > ConstraintT
std::map< carl::Variable, DoubleInterval > EvalDoubleIntervalMap