next up previous index
Next: Utility Constraints Predicates Up: The Finite Domains Library Previous: Evaluation Constraint Predicates   Index

CHIP Compatibility Constraints Predicates

These constraints, defined in the module fd_chip, are provided for CHIP v.3 compatibility and they are defined using native ECLiPSe constraints. Their source is available in the file fd_chip.pl.

?T1 ## ?T2
The value of the rational term T1 is not equal to the value of the rational term T2.

alldistinct(?List)
All elements of List (domain variables and ground terms) are pairwise different.

deleteff(?Var, +List, -Rest)
This predicate is used to select a variable from a list of domain variables which has the smallest domain. Var is the selected variable from List, Rest is the rest of the list without Var.

deleteffc(?Var, +List, -Rest)
This predicate is used to select the most constrained variable from a list of domain variables. Var is the selected variable from List which has the least domain and which has the most constraints attached to it. Rest is the rest of the list without Var.

deletemin(?Var, +List, -Rest)
This predicate is used to select the domain variable with the smallest lower domain bound from a list of domain variables. Var is the selected variable from List, Rest is the rest of the list without Var.

List is a list of domain variables or integers. Integers are treated as if they were variables with singleton domains.

dom(+DVar, -List)
List is the list of elements in the domain of the domain variable DVar. The predicate ::/2 can also be used to query the domain of a domain variable, however it yields a list of intervals.

NOTE: This predicate should not be used in ECLiPSe programs, because all intervals in the domain will be expanded into element lists which causes unnecessary space and time overhead. Unless an explicit list representation is required, finite domains should be processed by the family of the dom_* predicates in sections 2.14.2 and 2.14.3.

maxdomain(+DVar, -Max)
Max is the maximum value in the domain of the integer domain variable DVar.

mindomain(+DVar, -Min)
Min is the minimum value in the domain of the integer domain variable DVar.


next up previous index
Next: Utility Constraints Predicates Up: The Finite Domains Library Previous: Evaluation Constraint Predicates   Index
Warwick Harvey
2004-08-07