Overview | Group | Tree | Graph | Index | Concepts |
Boolean variables are also known as binary decision variables. They can assume the values 0 (zero) or 1 (one).
Most member functions in this class contain assert
statements. For an
explanation of the macro NDEBUG
(a way to turn on or turn off these
assert
statements), see the concept
Assert and NDEBUG.
What Is Extracted
An instance of IloBoolVar
is extracted by
IloSolver
(documented in the IBM ILOG Solver Reference Manual)
as an instance of the class IlcBoolVar
(also documented in the IBM ILOG Solver Reference Manual).
An instance of IloBoolVar
is extracted by
IloCplex
(documented in the IBM ILOG CPLEX Reference Manual)
as a column representing a
numeric variable of type Bool
with bounds as specified by
IloBoolVar
.
See Also:
Constructor Summary | |
---|---|
public | IloBoolVar(IloEnv env, IloInt min=0, IloInt max=1, const char * name=0) |
public | IloBoolVar(IloEnv env, const char * name) |
public | IloBoolVar(const IloAddNumVar & column, const char * name=0) |
Inherited Methods from IloIntVar |
---|
getImpl, getLB, getMax, getMin, getUB, setBounds, setLB, setMax, setMin, setPossibleValues, setUB |
Inherited Methods from IloIntExprArg |
---|
getImpl |
Inherited Methods from IloNumExprArg |
---|
getImpl |
Inherited Methods from IloExtractable |
---|
asConstraint, asIntExpr, asModel, asNumExpr, asObjective, asVariable, end, getEnv, getId, getImpl, getName, getObject, isConstraint, isIntExpr, isModel, isNumExpr, isObjective, isVariable, setName, setObject |
Constructor Detail |
---|
This constructor creates a Boolean variable
and makes it part of the environment
env
.
By default, the Boolean variable assumes a value of 0 (zero)
or 1 (one). By default, its name is the empty string, but you
can specify a name of your own choice.
This constructor creates a Boolean variable
and makes it part of the environment
env
. By default, its name is the empty string, but you
can specify a name of your own choice.
This constructor creates an instance of IloBoolVar
like this:
IloNumVar(column, 0.0, 1.0, ILOBOOL, name);