11 #ifndef COUENNE_EXPRBDIV_H
12 #define COUENNE_EXPRBDIV_H
27 if (a > COUENNE_INFINITY)
return ((sign < 0) ? -COUENNE_INFINITY : COUENNE_INFINITY);
28 if (a < -COUENNE_INFINITY)
return ((sign < 0) ? -COUENNE_INFINITY : COUENNE_INFINITY);
72 if (n > 0)
return safeDiv (n,D,-1);
76 else if (N > 0)
return safeDiv (N,D,-1);
120 if (N < 0)
return safeDiv (N,D,1);
124 else if (n < 0)
return safeDiv (n,D,1);
expression * clone(Domain *d=NULL) const
cloning method
CouNumber operator()()
function for the evaluation of the expression
pos
position where the operator should be printed when printing the expression
class to compute upper bound of a fraction based on the bounds of both numerator and denominator ...
void fint fint fint real * a
exprLBDiv(expression **al, int n)
Constructors, destructor.
std::string printOp() const
print operator
exprUBDiv(expression **al, int n)
Constructors, destructor.
enum pos printPos() const
print position (PRE, INSIDE, POST)
expression * clone(Domain *d=NULL) const
cloning method
expression ** clonearglist(Domain *d=NULL) const
clone argument list (for use with clone method)
CouNumber operator()()
function for the evaluation of the expression
expression ** arglist_
argument list is an array of pointers to other expressions
double CouNumber
main number type in Couenne
int nargs_
number of arguments (cardinality of arglist)
general n-ary operator-type expression: requires argument list.
enum pos printPos() const
print position (PRE, INSIDE, POST)
static CouNumber safeDiv(register CouNumber a, register CouNumber b, int sign)
division that avoids NaN's and considers a sign when returning infinity
std::string printOp() const
print operator
class to compute lower bound of a fraction based on the bounds of both numerator and denominator ...
Define a dynamic point+bounds, with a way to save and restore previous points+bounds through a LIFO s...