Originally posted by: Laser.Cho
======================================================================
inline IloIntExprArg IloLengthOf(const IloIntervalVar a, IloInt absVal =0){
IloAssert(a.getImpl(), "IloIntervalVar: empty handle.");
return a._makeLengthExpr(a.getEnv(),absVal);
}
======================================================================
this is one of the given function from concert, in the ilosmodel.h.
and it is used like this
-===========================
ilointervalvar movingVar;
_model.add(TimeVar >= IloPresenceOf(_env, movingVar) * IloLengthOf(movingVar));
======================================
what is the function of "IloLengthOf" or "_makeLengthExpr" ?
As I understand(it can be incorrect)
the example what i mentioned is meaning
" If movingvar is exist, then the length of movingvar is smaller than timevar. "
so, "ilolengthof" means doing return value length of intervalvar. <- Am I right?
#CPOptimizer#DecisionOptimization