Generated on Wed Jul 21 2021 00:00:00 for Gecode by doxygen 1.9.1
int-arith.cpp File Reference

Go to the source code of this file.

Classes

class  Gecode::MiniModel::ArithNonLinIntExpr
 Non-linear arithmetic expressions over integer variables. More...
 

Namespaces

 Gecode::MiniModel
 Minimalistic modeling support.
 

Functions

bool Gecode::MiniModel::hasType (const LinIntExpr &e, ArithNonLinIntExpr::ArithNonLinIntExprType t)
 Check if e is of type t. More...
 
LinIntExpr Gecode::abs (const LinIntExpr &e)
 Return expression for $|e|$. More...
 
LinIntExpr Gecode::min (const LinIntExpr &x, const LinIntExpr &y)
 Return expression for $\min(x,y)$. More...
 
LinIntExpr Gecode::max (const LinIntExpr &x, const LinIntExpr &y)
 Return expression for $\max(x,y)$. More...
 
LinIntExpr Gecode::min (const IntVarArgs &x)
 Return expression for $\min(x)$. More...
 
LinIntExpr Gecode::max (const IntVarArgs &x)
 Return expression for $\max(x)$. More...
 
LinIntExpr Gecode::operator* (const LinIntExpr &x, const LinIntExpr &y)
 Return expression for $x\cdot y$. More...
 
LinIntExpr Gecode::sqr (const LinIntExpr &x)
 Return expression for $x^2$. More...
 
LinIntExpr Gecode::sqrt (const LinIntExpr &x)
 Return expression for $\lfloor\sqrt{x}\rfloor$. More...
 
LinIntExpr Gecode::pow (const LinIntExpr &x, int n)
 Return expression for $x^n$. More...
 
LinIntExpr Gecode::nroot (const LinIntExpr &x, int n)
 Return expression for $\lfloor\sqrt[n]{x}\rfloor$. More...
 
LinIntExpr Gecode::operator/ (const LinIntExpr &x, const LinIntExpr &y)
 Return expression for $x\ \mathrm{div}\ y$. More...
 
LinIntExpr Gecode::operator% (const LinIntExpr &x, const LinIntExpr &y)
 Return expression for $x\ \mathrm{mod}\ y$. More...
 
LinIntExpr Gecode::element (const IntVarArgs &x, const LinIntExpr &y)
 Return expression for $x[y]$. More...
 
LinIntExpr Gecode::element (const IntArgs &x, const LinIntExpr &y)
 Return expression for $x[y]$. More...
 
LinIntExpr Gecode::ite (const BoolExpr &b, const LinIntExpr &x, const LinIntExpr &y)
 Return expression for if-then-else $b?x:y$. More...
 

Function Documentation

◆ abs()

LinIntExpr Gecode::abs ( const LinIntExpr e)

Return expression for $|e|$.

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

◆ min() [1/2]

LinIntExpr Gecode::min ( const LinIntExpr e0,
const LinIntExpr e1 
)

Return expression for $\min(x,y)$.

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

◆ max() [1/2]

LinIntExpr Gecode::max ( const LinIntExpr e0,
const LinIntExpr e1 
)

Return expression for $\max(x,y)$.

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

◆ min() [2/2]

LinIntExpr Gecode::min ( const IntVarArgs x)

Return expression for $\min(x)$.

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

◆ max() [2/2]

LinIntExpr Gecode::max ( const IntVarArgs x)

Return expression for $\max(x)$.

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

◆ operator*()

LinIntExpr Gecode::operator* ( const LinIntExpr e0,
const LinIntExpr e1 
)

Return expression for $x\cdot y$.

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

◆ sqr()

LinIntExpr Gecode::sqr ( const LinIntExpr e)

Return expression for $x^2$.

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

◆ sqrt()

LinIntExpr Gecode::sqrt ( const LinIntExpr e)

Return expression for $\lfloor\sqrt{x}\rfloor$.

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

◆ pow()

LinIntExpr Gecode::pow ( const LinIntExpr e,
int  n 
)

Return expression for $x^n$.

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

◆ nroot()

LinIntExpr Gecode::nroot ( const LinIntExpr e,
int  n 
)

Return expression for $\lfloor\sqrt[n]{x}\rfloor$.

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

◆ operator/()

LinIntExpr Gecode::operator/ ( const LinIntExpr e0,
const LinIntExpr e1 
)

Return expression for $x\ \mathrm{div}\ y$.

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

◆ operator%()

LinIntExpr Gecode::operator% ( const LinIntExpr e0,
const LinIntExpr e1 
)

Return expression for $x\ \mathrm{mod}\ y$.

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

◆ element() [1/2]

LinIntExpr Gecode::element ( const IntVarArgs x,
const LinIntExpr e 
)

Return expression for $x[y]$.

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

◆ element() [2/2]

LinIntExpr Gecode::element ( const IntArgs x,
const LinIntExpr e 
)

Return expression for $x[y]$.

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

◆ ite()

LinIntExpr Gecode::ite ( const BoolExpr b,
const LinIntExpr e0,
const LinIntExpr e1 
)

Return expression for if-then-else $b?x:y$.

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