| Overview | Group | Tree | Graph | Deprecated | Index | Concepts |

This class adds functionality to IlcCPEngine
in order to access Ilc-level objects, particularly variables from Concert
technology objects such as IloIntVar and
IloIntervalVar.
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.
See Also:
IlcCPEngine, IloIntVarEvalI, IloIntValueEvalI, IloIntVarChooserI, IloIntValueChooserI
Inherited Methods from IlcCPEngine |
|---|
add, addReversibleAction, exitSearch, fail, getHeap, getInfo, getInfo, getRandomInt, getRandomNum, out, solve |
| Inner Class | |
|---|---|
| IloCPEngine::IntVarIterator | The class for iterating over the current domain of an integer variable. |
| Method Detail |
|---|
IloCPEngine from one of
of type IlcCPEngine.
This constructor can be useful to have accesses to services such as
IloCPEngine::getIntVar(IloIntVar) which is not
available on IlcCPEngine as it does not know
about Concert Technology objects.
This member function returns the undocumented class
IloCPEngine::PrintIntervalVarDomains which can be
inserted into a stream to print the current domain of interval
variable a as maintained by the invoking instance
of IloCPEngine. Here is an example of its use:
cp.out() << cp.domain(a) << std::endl;
This member function returns the undocumented class
IloCPEngine::PrintNumVarDomains which can be
inserted into a stream to print the current
domains of vars as maintained by the
invoking instance of IloCPEngine. Here is
an example of its use:
cp.out() << cp.domain(vars) << std::endl;
This member function returns the undocumented class
IloCPEngine::PrintNumVarDomains which can be
inserted into a stream to print the current
domain of var as maintained by the
invoking instance of IloCPEngine. Here is
an example of its use:
cp.out() << cp.domain(var) << std::endl;
This member function returns the optimizer engine cumul element
variable corresponding to
the modeling variable f. A cumul element function
variable is an instance of IloCumulFunctionExpr
built by the shape functions IloPulse,
IloStepAtStart or
IloStepAtEnd with an
instance of IloIntervalVar as first argument.
For more information on the scheduling search API, see the concept Search API for scheduling in CP Optimizer.
See Also:
IloCumulFunctionExpr, IlcCumulElementVar
This member function returns the size of the domain of variable
var as maintained in the invoking instance of
IloCPEngine.
This member function returns the size of the domain of variable
var as maintained in the invoking instance of
IloCPEngine. An assertion is violated if var
is not of integral type.
This member function returns the current value of the end of
interval variable a in the invoking instance of
IloCPEngine. An assertion is violated if a
is not fixed.
This member function returns the maximum value for the end of
interval variable a in the invoking instance of
IloCPEngine.
This member function returns the minimum value for the end of
interval variable a in the invoking instance of
IloCPEngine.
This member function assumes that interval sequence variable
seq is fixed. It returns the interval variable at
the first position in the sequence. The returned interval
variable is necessarily present. If all interval variables of the
sequence are absent, it returns an empty handle. An assertion is
violated if the sequence seq is not fixed.
This function can be used to print the total order corresponding to the sequence value as illustrated by the following code sample.
for(IloIntervalVar a = cp.getFirst(seq); a.getImpl()!=0; a = cp.getNext(seq, a))
cp.out() << cp.domain(a) << std::endl;
For more information on interval sequence variables see the concept Interval variable sequencing in CP Optimizer.
This member function returns the optimizer engine floating-point array corresponding to
the modeling array arg.
This member function assumes that cumul function expression
f is fixed. It returns the total contribution of the interval
variable var to the cumul function expressionf
at the end time of var. Note that contribution of absent
interval variable is always zero.
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function assumes that cumul function expression
f is fixed. It returns the total contribution of the interval
variable var to the cumul function expressionf
at the start time of var. Note that contribution of absent
interval variable is always zero.
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function returns the optimizer engine integer array corresponding to
the modeling array arg.
This member function returns the optimizer engine interval
variable corresponding to the modeling variable var.
For more information on the search API for scheduling, see the concept Search API for scheduling in CP Optimizer.
See Also:
IlcIntervalVar, IloIntervalVar
This member function returns the optimizer engine interval
variable corresponding to
the modeling variable var.
For more information on the scheduling search API, see the concept Search API for scheduling in CP Optimizer.
See Also:
IloIntervalSequenceVar, IlcIntervalSequenceVar
This function returns the optimizer engine tuple set
corresponding to the modeling tuple set ts.
This member function returns the optimizer engine integer variable corresponding to
the modeling variable var.
This member function returns the optimizer engine integer variable array corresponding to
the modeling variable array vars.
This member function assumes that interval sequence variable
seq is fixed. It returns the interval variable at
the last position in the sequence. The returned interval
variable is necessarily present. If all interval variables of the
sequence are absent, it returns an empty handle. An assertion is
violated if the sequence seq is not fixed.
This function can be used to print the reverse total order corresponding to the sequence value as illustrated by the following code sample.
for(IloIntervalVar a = cp.getLast(seq); a.getImpl()!=0; a = cp.getPrev(seq, a))
cp.out() << cp.domain(a) << std::endl;
For more information on interval sequence variables see the concept Interval variable sequencing in CP Optimizer.
This member function returns the current value of the length
of interval variable a in the invoking instance of
IloCPEngine. An assertion is violated if a is
not fixed.
This member function returns the maximum value for the length
of interval variable a in the invoking instance of
IloCPEngine.
This member function returns the minimum value for the length
of interval variable a in the invoking instance of
IloCPEngine.
Retrieves the master IloCP object which controls
the invoking IloCPEngine object.
This member function returns the maximum value of the variable
var in the invoking instance of IloCPEngine.
This member function returns the minimum value of the variable
var in the invoking instance of IloCPEngine.
This member function assumes that interval sequence variable
seq is fixed. It returns the interval variable that
immediately follows interval a in the sequence. The
returned interval variable is necessarily present. An assertion
is violated if a is absent or is not an interval
variable of sequence seq and if the sequence is not
fixed. If a is at the last position of the sequence,
the function returns an empty handle.
This function can be used to print the total order corresponding to the sequence value as illustrated by the following code sample.
for(IloIntervalVar a = cp.getFirst(seq); a.getImpl()!=0; a = cp.getNext(seq, a))
cp.out() << cp.domain(a) << std::endl;
For more information on interval sequence variables see the concept Interval variable sequencing in CP Optimizer.
This member function assumes that state function
f is fixed. It returns the number of segments of the
corresponding stepwise function. A segment is an
interval [start, end) on which the value of
f is constant. If the state function is not defined,
the value is IloCP::NoState; otherwise the value is a non-negative
integer. An assertion is violated if state
function f is not fixed.
This function can be used to print the content of a state function as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on state function see the concept State functions in CP Optimizer.
This member function assumes that cumul function expression
f is fixed. It returns the number of segments of the
corresponding stepwise non-negative function. A segment is an
interval [start, end) on which the value of
f is constant. An assertion is violated if cumul
function expression f is not fixed.
This function can be used to print the content of a cumul function expression as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function assumes that interval sequence variable
seq is fixed. It returns the interval variable that
immediately precedes interval a in the sequence. The
returned interval variable is necessarily present. An assertion
is violated if a is absent or is not an interval
variable of sequence seq and if the sequence is not
fixed. If a is at the first position of the sequence,
the function returns an empty handle.
This function can be used to print the reverse total order corresponding to the sequence value as illustrated by the following code sample.
for(IloIntervalVar a = cp.getLast(seq); a.getImpl()!=0; a = cp.getPrev(seq, a))
cp.out() << cp.domain(a) << std::endl;
For more information on interval sequence variables see the concept Interval variable sequencing in CP Optimizer.
This member function assumes that state function
f is fixed. It returns the end of the
ith segment of the
corresponding stepwise function. A segment is an
interval [start, end) on which the value of
f is constant. If the state function is not defined,
the value is IloCP::NoState; otherwise the value is a non-negative
integer. An assertion is violated if state
function f is not fixed.
This function can be used to print the content of a state function as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on state function see the concept State functions in CP Optimizer.
This member function assumes that cumul function expression
f is fixed. It returns the end of the
ith segment of the corresponding stepwise
non-negative function. A segment is an interval [start,
end) on which the value of f is constant. If
n is the number of segments of the function
segments are indexed starting from 0 so index
i should belong to the range [0,n). An
assertion is violated if cumul function expression f
is not fixed or if i is not a valid segment
index.
This function can be used to print the content of a cumul function expression as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function assumes that state function
f is fixed. It returns the start of the
ith segment of the
corresponding stepwise function. A segment is an
interval [start, end) on which the value of
f is constant. If the state function is not defined,
the value is IloCP::NoState; otherwise the value is a non-negative
integer. An assertion is violated if state
function f is not fixed.
This function can be used to print the content of a state function as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on function see the concept State functions in CP Optimizer.
This member function assumes that cumul function expression
f is fixed. It returns the start of the
ith segment of the corresponding stepwise
non-negative function. A segment is an interval [start,
end) on which the value of f is constant. If
n is the number of segments of the function
segments are indexed starting from 0 so index
i should belong to the range [0,n). An
assertion is violated if cumul function expression f
is not fixed or if i is not a valid segment
index.
This function can be used to print the content of a cumul function expression as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function assumes that state function
f is fixed. It returns the value of the
ith segment of the
corresponding stepwise function. A segment is an
interval [start, end) on which the value of
f is constant. If the state function is not defined,
the value is IloCP::NoState; otherwise the returned value is a non-negative
integer. An assertion is violated if state
function f is not fixed.
This function can be used to print the content of a state function as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on state function see the concept State functions in CP Optimizer.
This member function assumes that cumul function expression
f is fixed. It returns the value of the
ith segment of the corresponding stepwise
non-negative function. A segment is an interval [start,
end) on which the value of f is constant. If
n is the number of segments of the function
segments are indexed starting from 0 so index
i should belong to the range [0,n). An
assertion is violated if cumul function expression f
is not fixed or if i is not a valid segment
index.
This function can be used to print the content of a cumul function expression as illustrated by the following code sample.
for (IloInt i=0; i < cp.getNumberOfSegments(f); ++i)
cp.out() << "[" << cp.getSegmentStart(f, i)
<< "," << cp.getSegmentEnd(f, i)
<< "):" << cp.getSegmentValue(f, i)
<< std::endl;
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function returns the current value of the size of
interval variable a in the invoking instance of
IloCPEngine. An assertion is violated if a
is not fixed.
This member function returns the maximum value for the size
of interval variable a in the invoking instance of
IloCPEngine.
This member function returns the minimum value for the size
of interval variable a in the invoking instance of
IloCPEngine.
This member function returns the current value of the start of
interval variable a in the invoking instance of
IloCPEngine. An assertion is violated if a
is not fixed.
This member function returns the maximum value for the start
of interval variable a in the invoking instance of
IloCPEngine.
This member function returns the minimum value for the start
of interval variable a in the invoking instance of
IloCPEngine.
This member function assumes that state function
f is fixed. It returns the value of the
corresponding stepwise non-negative function at point
t. If the state function is not defined,
the value is IloCP::NoState; otherwise the returned value is a non-negative
integer. An assertion is violated if state function
f is not fixed or if t does
not belong to the interval [IloIntervalMin,
IloIntervalMax).
For more information on state function see the concept State functions in CP Optimizer.
This member function assumes that cumul function expression
f is fixed. It returns the value of the
corresponding stepwise non-negative function at point
t. An assertion is violated if cumul function
expression f is not fixed or if t does
not belong to the interval [IloIntervalMin,
IloIntervalMax).
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function returns the current value of the variable
v in the invoking instance of IloCPEngine.
An assertion is violated if v is not fixed to a value.
This member function returns IloTrue if and only if interval
variable a is absent in the invoking instance of
IloCPEngine.
This member function checks whether an extractable ext has been
extracted.
This member function indicates if the state function
f takes on a particular value as
maintained by the invoking IloCPEngine instance. A state
function f is said to be fixed if it
defines a fixed value f(t) for all t in
[IloIntervalMin,IloIntervalMax). When fixed, a state
function is a stepwise function. If the state function is not defined,
the value is IloCP::NoState; otherwise the value is a non-negative
integer.
For more information on state functions see the concept State functions in CP Optimizer.
This member function indicates if the cumul function
expression f takes on a particular value as
maintained by the invoking IloCPEngine instance. A cumul
function expression f is said to be fixed if it
defines a fixed value f(t) for all t in
[IloIntervalMin,IloIntervalMax). When fixed, a cumul
function expression is a stepwise non-negative function.
For more information on cumul function expressions see the concept Cumul functions in CP Optimizer.
This member function indicates if the domain of the interval
sequence variable seq takes on a particular value as
maintained by the invoking IloCPEngine instance. An
interval sequence variable is said to be fixed if and only if all
the interval variables of the sequence are either absent or
ordered.
For more information on interval sequence variables see the concept Interval variable sequencing in CP Optimizer.
This member function indicates if the domain of
a takes on a particular value as maintained by the
invoking IloCPEngine instance. An interval variable is
said to be fixed if and only if it is either absent or present
with fixed start, end and size value.
This member function indicates if the domain of var
takes on a particular value as maintained by the invoking
IloCPEngine instance.
This member function indicates whether value is
contained in the current domain of var as maintained
by the invoking IloCPEngine instance.
This member function returns IloTrue if and only if interval
variable a is present in the invoking instance of
IloCPEngine.
This member function returns an iterator to iterate over
the domain of var, as maintained by the
invoking CP optimizer. It is equivalent to:
IloCPEngine::IntVarIterator(this, var).
This member function uses the invoking CP optimizer to instantiate the
variables in solution with their saved values. The value
of any objective added to the solution is not restored.
If the solution does not violate any constraints of the model extracted
by the invoking CP optimizer, then IloTrue is returned and
the state of the constraint variables in the CP optimizer reflect those
stored in solution. Otherwise the CP optimizer's state
remains unchanged and IloFalse is returned.