Next: CHIP Compatibility Constraints Predicates
Up: The Finite Domains Library
Previous: Logical Constraint Predicates
  Index
These constraint predicates evaluate given constraint expression(s)
and associate its truth value with a boolean variable.
They can be very useful to define more complex constraints.
They can be used both to test entailment of a constraint
and to impose a constraint or its negation on the current constraint store.
- ?B isd +Expr
-
B is equal to 1 iff
the constraint expression Expr is true, 0 otherwise.
This predicate is the constraint counterpart of is/2 -
it takes a constraint expression, transforms all its subexpressions
into calls to predicates with arity one higher and combines
the resulting boolean values to yield B.
For instance,
B isd X #= Y
is equivalent to
#=(X, Y, B)
- #
<
(?T1, ?T2, ?B)
-
B is equal to 1 iff
the value of the rational term T1 is less than the value of the
rational term T2, 0 otherwise.
- #
<=
(?T1, ?T2, ?B)
-
B is equal to 1 iff
the value of the rational term T1 is less than or equal to the value of the
rational term T2, 0 otherwise.
- #=(?T1, ?T2, ?B)
-
B is equal to 1 iff
the value of the rational term T1 is equal to the
value of the rational term T2, 0 otherwise.
- #
\
=(?T1, ?T2, ?B)
-
B is equal to 1 iff
the value of the rational term T1 is different from the
value of the rational term T2, 0 otherwise.
- #
>
(?T1, ?T2, ?B)
-
B is equal to 1 iff
the value of the rational term T1 is greater than the
value of the rational term T2, 0 otherwise.
- #
>=
(?T1, ?T2, ?B)
-
B is equal to 1 iff
the value of the rational term T1 is greater than or equal to the
value of the rational term T2, 0 otherwise.
- #
/\
(+E1, +E2, ?B)
-
B is equal to 1 iff
both constraint expressions E1 and E2 are true,
0 otherwise.
- #
\/
(+E1, +E2, ?B)
-
B is equal to 1 iff
at least one of the constraint expressions E1 and E2 is true,
0 otherwise.
- #
<=>
(+E1, +E2, ?B)
-
B is equal to 1 iff
the constraint expression E1 is equivalent to the
constraint expression E2,
0 otherwise.
- #=
>
(+E1, +E2, ?B)
-
B is equal to 1 iff
the constraint expression E1 implies the
constraint expression E2,
0 otherwise.
- #
\
+(+E1, ?B)
-
B is equal to 1 iff
E1 is false,
0 otherwise.
Next: CHIP Compatibility Constraints Predicates
Up: The Finite Domains Library
Previous: Logical Constraint Predicates
  Index
1999-08-06