Skip to main content
FRAMES NO FRAMES

IlcSplit

public IlcGoal IlcSplit(const IlcFloatVarArray vars, IlcBool increaseMinFirst=IlcTrue)
Definition file: ilcp/cpext.h
Include file: <ilcp/cpext.h>
A goal to assign values to an array of variables.

This function creates and returns a goal, a primitive in the algorithms that search for solutions. This goal binds each constrained variable in its argument vars.

IlcSplit scans the variables from the first to the last and repeats its procedure until all the variables are bound.

At each step of the scan, if the current variable is not yet bound, IlcSplit sets a choice point, replaces the domain of the current variable by one of the halves, and examines the next variable.

The optional argument increaseMinFirst must be a Boolean value, either IlcTrue or IlcFalse. If it is IlcTrue, then the upper half of the domain is tried first; otherwise, the lower half is tried first.

For example, IlcSplit starts with the first variable; if the first variable has not already been bound, IlcSplit sets a choice point, then replaces the domain of that variable by one of the halves; IlcSplit then examines the second variable. In contrast, if the first variable has already been bound, IlcSplit examines the second variable directly.

See Also: