exprConst Class Reference

constant-type operator More...

#include <exprConst.hpp>

Inheritance diagram for exprConst:

Inheritance graph
[legend]
Collaboration diagram for exprConst:

Collaboration graph
[legend]
List of all members.

Public Member Functions

enum nodeType Type () const
 node type
CouNumber Value () const
 value of expression
 exprConst (CouNumber value)
 Constructor.
 exprConst (const exprConst &e, Domain *d=NULL)
 Copy constructor.
virtual expressionclone (Domain *d=NULL) const
 Cloning method.
void print (std::ostream &out=std::cout, bool=false) const
 I/O.
CouNumber operator() ()
 return constant's value
expressiondifferentiate (int)
 differentiation
int dependsOn (int *ind, int n, enum dig_type type=STOP_AT_AUX)
 dependence on variable set
int Linearity ()
 get a measure of "how linear" the expression is (see CouenneTypes.h)
void getBounds (expression *&lower, expression *&upper)
 Get lower and upper bound of an expression (if any).
void getBounds (CouNumber &lower, CouNumber &upper)
 Get value of lower and upper bound of an expression (if any).
void generateCuts (expression *, OsiCuts &, const CouenneCutGenerator *, t_chg_bounds *=NULL, int=-1, CouNumber=-COUENNE_INFINITY, CouNumber=COUENNE_INFINITY)
 generate convexification cut for constraint w = this
virtual enum expr_type code ()
 code for comparisons
virtual bool isInteger ()
 is this expression integer?
virtual int rank ()
 used in rank-based branching variable choice

Private Attributes

CouNumber value_
 the value of this constant

Detailed Description

constant-type operator

Definition at line 22 of file exprConst.hpp.


Constructor & Destructor Documentation

exprConst::exprConst ( CouNumber  value  )  [inline]

Constructor.

Definition at line 40 of file exprConst.hpp.

Referenced by clone(), differentiate(), and getBounds().

exprConst::exprConst ( const exprConst e,
Domain d = NULL 
) [inline]

Copy constructor.

Definition at line 44 of file exprConst.hpp.

References value_.


Member Function Documentation

enum nodeType exprConst::Type (  )  const [inline, virtual]

node type

Reimplemented from expression.

Definition at line 32 of file exprConst.hpp.

References CONST.

CouNumber exprConst::Value (  )  const [inline, virtual]

value of expression

Reimplemented from expression.

Definition at line 36 of file exprConst.hpp.

References value_.

virtual expression* exprConst::clone ( Domain d = NULL  )  const [inline, virtual]

Cloning method.

Reimplemented from expression.

Definition at line 48 of file exprConst.hpp.

References exprConst(), and value_.

void exprConst::print ( std::ostream &  out = std::cout,
bool  = false 
) const [inline, virtual]

I/O.

Reimplemented from expression.

Definition at line 52 of file exprConst.hpp.

References value_.

CouNumber exprConst::operator() (  )  [inline, virtual]

return constant's value

Implements expression.

Definition at line 57 of file exprConst.hpp.

References value_.

expression* exprConst::differentiate ( int   )  [inline, virtual]

differentiation

Reimplemented from expression.

Definition at line 61 of file exprConst.hpp.

References exprConst().

int exprConst::dependsOn ( int *  ind,
int  n,
enum dig_type  type = STOP_AT_AUX 
) [inline, virtual]

dependence on variable set

Reimplemented from expression.

Definition at line 65 of file exprConst.hpp.

int exprConst::Linearity (  )  [inline, virtual]

get a measure of "how linear" the expression is (see CouenneTypes.h)

Reimplemented from expression.

Definition at line 69 of file exprConst.hpp.

References CONSTANT, COUENNE_EPS, value_, and ZERO.

void exprConst::getBounds ( expression *&  lower,
expression *&  upper 
) [inline, virtual]

Get lower and upper bound of an expression (if any).

Reimplemented from expression.

Definition at line 73 of file exprConst.hpp.

References exprConst(), and value_.

void exprConst::getBounds ( CouNumber lower,
CouNumber upper 
) [inline, virtual]

Get value of lower and upper bound of an expression (if any).

Reimplemented from expression.

Definition at line 79 of file exprConst.hpp.

References value_.

void exprConst::generateCuts ( expression ,
OsiCuts &  ,
const CouenneCutGenerator ,
t_chg_bounds = NULL,
int  = -1,
CouNumber  = -COUENNE_INFINITY,
CouNumber  = COUENNE_INFINITY 
) [virtual]

generate convexification cut for constraint w = this

Reimplemented from expression.

virtual enum expr_type exprConst::code (  )  [inline, virtual]

code for comparisons

Reimplemented from expression.

Definition at line 90 of file exprConst.hpp.

References COU_EXPRCONST.

virtual bool exprConst::isInteger (  )  [inline, virtual]

is this expression integer?

Reimplemented from expression.

Definition at line 94 of file exprConst.hpp.

References isInteger(), and value_.

virtual int exprConst::rank (  )  [inline, virtual]

used in rank-based branching variable choice

Reimplemented from expression.

Definition at line 98 of file exprConst.hpp.


Member Data Documentation

CouNumber exprConst::value_ [private]

the value of this constant

Definition at line 27 of file exprConst.hpp.

Referenced by clone(), exprConst(), getBounds(), isInteger(), Linearity(), operator()(), print(), and Value().


The documentation for this class was generated from the following file:
Generated on Sun Feb 14 03:04:19 2010 for Couenne by  doxygen 1.4.7