Next: Propositional Constraints, Previous: Arithmetic Constraints, Up: Available Constraints [Contents][Index]
domain(+Variables, +Range) polymorphic,since release 4.10.0where Variables is a list of variables. True if the variables all are elements of Range.
domain/2 can be used for integer variables as well as for real
variables.
For integer variables, Range should be an IntegerRange;
For real variables, Range should be a RealRange.
See Syntax of Range Expressions.
domain(+Variables, +Min, +Max) polymorphicwhere Variables is a list of variables. True if the variables
all are elements of the range Min..Max.
domain/3 can be used for integer variables as well as for real
variables. For integer variables, Min is an integer or the atom
inf (minus infinity), and Max is an integer or the atom
sup (plus infinity). For real variables, Min is a real
or the atom finf (minus infinity), and Max is a real or
the atom fsup (plus infinity).
?X in +Range reifiable,polymorphicwhere X is a domain variable.
in/2 can be used for integer variables as well as for real
variables.
True if X is an element of the range.
For integer variables, Range should be an IntegerRange;
For real variables, Range should be a RealRange.
See Syntax of Range Expressions.
?X in_set +FDSet reifiablewhere X is an integer variable and FDSet is an FD set (see FD Set Operations). True if X is an element of the FD set.
in/2 and in_set/2 constraints maintain domain consistency
and their reified versions detect domain entailment and disentailment.