[ library(eplex) | The ECLiPSe Libraries | Reference Manual | Alphabetic Index ]

# EplexInstance: (?Vars :: ++Lo..Hi)

Constrains list elements to lie between the given bounds.

Vars
  Variable or number, or a list or submatrix of variables/numbers
Lo..Hi
  Lo, Hi are numbers or arithmetic expressions

## Description

Constrain a variable (or all variables in a list) to take only values in a given range for the eplex instance EplexInstance. Any variables that are not already problem variables for EplexInstance will be added to the problem. The range information is passed to the external solver state associated with EplexInstance as floats. No type information are implied by the bounds.

In particular, if the bounds are given as integers, this information is not passed to the external solver. Unless eplex:integers/1 is invoked, any invocation of the eplex external solver (whether via eplex_solve/1, lp_solve/2, lp_demon_setup/5 or optimize/2) will only solve a continuous relaxation, even when problem variables have been declared as integers in other solvers (e.g. ic).

No propagation is done at the ECLiPSe level with the bounds. In particular, the variable is not instantiated even if the lower and upper bounds are identical. The bounds may be inconsistent with the bounds given for the variables in other EplexInstances or solvers (i.e. this will not result in immediate failure).

### Fail Conditions

Lo is greater than Hi.

### Exceptions

(5) type error
  Lo..Hi is not in correct form
(5) type error
  Lo and Hi are of different numeric types

## See Also

integers / 1, reals / 1, ic_hybrid_sets : :: / 2, suspend : :: / 2, fd : :: / 2, ic : :: / 2, ic_sets : :: / 2, fd_sets : :: / 2, suspend : #:: / 2, fd : #:: / 2, ic : #:: / 2, $:: / 2, get_var_bounds / 3