Gecode::MiniModel::ArithNonLinIntExpr Class Reference

Non-linear arithmetic expressions over integer variables. More...

## Public Types

enum | ArithNonLinIntExprType { ANLE_ABS , ANLE_MIN , ANLE_MAX , ANLE_MULT , ANLE_DIV , ANLE_MOD , ANLE_SQR , ANLE_SQRT , ANLE_POW , ANLE_NROOT , ANLE_ELMNT , ANLE_ITE }
| The expression type. More...

## Public Member Functions

| ArithNonLinIntExpr (ArithNonLinIntExprType t0, int n0)
| Constructor.
| ArithNonLinIntExpr (ArithNonLinIntExprType t0, int n0, int a0)
| Constructor.
| ArithNonLinIntExpr (ArithNonLinIntExprType t0, int n0, const BoolExpr &b0)
| Constructor.
| ~ArithNonLinIntExpr (void)
| Destructor.
virtual IntVar | post (Home home, IntVar *ret, const IntPropLevels &ipls) const
| Post expression.
virtual void | post (Home home, IntRelType irt, int c, const IntPropLevels &ipls) const
| Post expression to be in relation irt with c.
virtual void | post (Home home, IntRelType irt, int c, BoolVar b, const IntPropLevels &ipls) const
| Post reified expression to be in relation irt with c.
Public Member Functions inherited from Gecode::NonLinIntExpr
virtual | ~NonLinIntExpr (void)
| Destructor.
void * | operator new (size_t s)
| Memory management.
void | operator delete (void *p, size_t s)
| Memory management.

## Public Attributes

enum Gecode::MiniModel::ArithNonLinIntExpr::ArithNonLinIntExprType | t
LinIntExpr * | a
| Expressions.
int | n
| Size of variable array.
int | aInt
| Integer argument (used in nroot for example).
BoolExpr | b
| Boolean expression argument (used in ite for example).

## Additional Inherited Members

Static Public Member Functions inherited from Gecode::NonLinIntExpr
static IntVar | result (Home home, IntVar *x)
| Return fresh variable if x is null, x otherwise.
static IntVar | result (Home home, IntVar *x, IntVar y)
| Constrain x to be equal to y if x is not null.

## Detailed Description

Non-linear arithmetic expressions over integer variables.

Definition at line 39 of file int-arith.cpp.

## Member Enumeration Documentation

## ArithNonLinIntExprType

enum Gecode::MiniModel::ArithNonLinIntExpr::ArithNonLinIntExprType

The expression type.

Enumerator
ANLE_ABS | Absolute value expression.
ANLE_MIN | Minimum expression.
ANLE_MAX | Maximum expression.
ANLE_MULT | Multiplication expression.
ANLE_DIV | Division expression.
ANLE_MOD | Modulo expression.
ANLE_SQR | Square expression.
ANLE_SQRT | Square root expression.
ANLE_POW | Pow expression.
ANLE_NROOT | Nroot expression.
ANLE_ELMNT | Element expression.
ANLE_ITE | If-then-else expression.

Definition at line 42 of file int-arith.cpp.

## Constructor & Destructor Documentation

## ArithNonLinIntExpr() [1/3]

Gecode::MiniModel::ArithNonLinIntExpr::ArithNonLinIntExpr | ( | ArithNonLinIntExprType | t0,
|  | int | n0 )

inline

Constructor.

Definition at line 65 of file int-arith.cpp.

## ArithNonLinIntExpr() [2/3]

Gecode::MiniModel::ArithNonLinIntExpr::ArithNonLinIntExpr | ( | ArithNonLinIntExprType | t0,
|  | int | n0,
|  | int | a0 )

inline

Constructor.

Definition at line 68 of file int-arith.cpp.

## ArithNonLinIntExpr() [3/3]

Gecode::MiniModel::ArithNonLinIntExpr::ArithNonLinIntExpr | ( | ArithNonLinIntExprType | t0,
|  | int | n0,
|  | const BoolExpr & | b0 )

inline

Constructor.

Definition at line 71 of file int-arith.cpp.

## ~ArithNonLinIntExpr()

Gecode::MiniModel::ArithNonLinIntExpr::~ArithNonLinIntExpr | ( | void |  | ) |

inline

Destructor.

Definition at line 74 of file int-arith.cpp.

## Member Function Documentation

## post() [1/3]

virtual IntVar Gecode::MiniModel::ArithNonLinIntExpr::post | ( | Home | home,
|  | IntVar * | ret,
|  | const IntPropLevels & | ipls ) const

inline virtual

Post expression.

Implements Gecode::NonLinIntExpr.

Definition at line 78 of file int-arith.cpp.

## post() [2/3]

virtual void Gecode::MiniModel::ArithNonLinIntExpr::post | ( | Home | home,
|  | IntRelType | irt,
|  | int | c,
|  | const IntPropLevels & | ipls ) const

inline virtual

Post expression to be in relation irt with c.

Implements Gecode::NonLinIntExpr.

Definition at line 271 of file int-arith.cpp.

## post() [3/3]

virtual void Gecode::MiniModel::ArithNonLinIntExpr::post | ( | Home | home,
|  | IntRelType | irt,
|  | int | c,
|  | BoolVar | b,
|  | const IntPropLevels & | ipls ) const

inline virtual

Post reified expression to be in relation irt with c.

Implements Gecode::NonLinIntExpr.

Definition at line 283 of file int-arith.cpp.

## Member Data Documentation

## t

enum Gecode::MiniModel::ArithNonLinIntExpr::ArithNonLinIntExprType Gecode::MiniModel::ArithNonLinIntExpr::t

## a

LinIntExpr* Gecode::MiniModel::ArithNonLinIntExpr::a

Expressions.

Definition at line 57 of file int-arith.cpp.

## n

int Gecode::MiniModel::ArithNonLinIntExpr::n

Size of variable array.

Definition at line 59 of file int-arith.cpp.

## aInt

int Gecode::MiniModel::ArithNonLinIntExpr::aInt

Integer argument (used in nroot for example).

Definition at line 61 of file int-arith.cpp.

## b

BoolExpr Gecode::MiniModel::ArithNonLinIntExpr::b

Boolean expression argument (used in ite for example).

Definition at line 63 of file int-arith.cpp.

The documentation for this class was generated from the following file:

- gecode/minimodel/int-arith.cpp