12 #ifndef COUENNE_EXPRAUX_HPP
13 #define COUENNE_EXPRAUX_HPP
22 class CouenneCutGenerator;
92 {
return new exprAux (*
this, d);}
98 virtual void print (std::ostream & = std::cout,
115 int DepList (std::set <int> &deplist,
214 int signDiff = (e0 -> sign () - e1 -> sign ());
216 assert (e0 -> Image () != NULL);
217 assert (e1 -> Image () != NULL);
219 return ((signDiff < 0) ||
221 ((e0 -> Image () != NULL) &&
222 (e1 -> Image () != NULL) &&
223 (e0 -> Image () -> compare (*(e1 -> Image ())) < 0))));
229 void draw_cuts (OsiCuts &,
const CouenneCutGenerator *,
230 int, expression *, expression *);
Cut Generator for linear convexifications.
void increaseMult()
Tell this variable appears once more.
enum intType integer_
is this variable integer?
int multiplicity_
number of appearances of this aux in the formulation.
OsiObject for auxiliary variables $w=f(x)$.
bool & top_level()
return top_level_
int rank_
used in rank-based branching variable choice: original variables have rank 1; auxiliary w=f(x) has ra...
CouNumber operator()()
Null function for evaluating the expression.
status of lower/upper bound of a variable, to be checked/modified in bound tightening ...
void crossBounds()
Get lower and upper bound of an expression (if any)
enum auxSign sign_
"sign" of the defining constraint
void draw_cuts(OsiCuts &, const CouenneCutGenerator *, int, expression *, expression *)
allow to draw function within intervals and cuts introduced
virtual int rank()
used in rank-based branching variable choice
Domain * domain_
Pointer to a descriptor of the current point/bounds.
void generateCuts(OsiCuts &, const CouenneCutGenerator *, t_chg_bounds *=NULL, int=-1, CouNumber=-COUENNE_INFINITY, CouNumber=COUENNE_INFINITY)
generate cuts for expression associated with this auxiliary
virtual void setInteger(bool value)
Set this variable as integer.
expression * simplify()
simplify
Structure for comparing expressions.
expression * Image() const
The expression associated with this auxiliary variable.
expression * Ub()
get upper bound expression
A class to have all elements necessary to setup a branch-and-bound.
auxSign
"sign" of the constraint defining an auxiliary.
virtual ~exprAux()
Destructor.
void zeroMult()
Disable this auxiliary variable.
virtual CouNumber & ub()
Get/set upper bound value.
virtual void print(std::ostream &=std::cout, bool=false) const
Print expression.
enum nodeType Type() const
Node type.
Class for MINLP problems with symbolic information.
intType
integrality type of an auxiliary variable: unset, continuous, integer
int DepList(std::set< int > &deplist, enum dig_type type=ORIG_ONLY)
fill in the set with all indices of variables appearing in the expression
expression * lb_
lower bound, a function of the associated expression and the bounds on the variables in the expressio...
bool operator()(exprAux *e0, exprAux *e1) const
virtual enum auxSign sign() const
return its sign in the definition constraint
CouenneObject * properObject(CouenneCutGenerator *c, CouenneProblem *p, Bonmin::BabSetupBase *base, JnlstPtr jnlst)
return proper object to handle expression associated with this variable (NULL if this is not an auxil...
double CouNumber
main number type in Couenne
virtual exprVar * clone(Domain *d=NULL) const
Cloning method.
nodeType
type of a node in an expression tree
int Linearity()
Get a measure of "how linear" the expression is (see CouenneTypes.h)
void linkDomain(Domain *d)
link this variable to a domain
dig_type
type of digging when filling the dependence list
virtual bool isInteger()
is this expression integer?
virtual bool isDefinedInteger()
is this expression defined as integer?
expression * Lb()
get lower bound expression
exprAux(expression *, int, int, intType=Unset, Domain *=NULL, enum auxSign=expression::AUX_EQ)
Constructor.
bool top_level_
True if this variable replaces the lhs of a constraint, i.e., if it is a top level variable in the DA...
void decreaseMult()
Tell this variable appears once less (standardized within exprSum, for instance)
expression * ub_
upper bound, a function of the associated expression and the bounds on the variables in the expressio...
int varIndex_
The index of the variable.
expression * image_
The expression associated with this auxiliary variable.
void Image(expression *image)
Sets expression associated with this auxiliary variable.
int Multiplicity()
How many times this variable appears.
Define a dynamic point+bounds, with a way to save and restore previous points+bounds through a LIFO s...
virtual CouNumber & lb()
Get/set lower bound value.
void fint fint fint real fint real * x