Next: , Previous: Lat-Card, Up: Lattice functors


4.15.3 Domain functor

The domain lattice encodes constants from a finite domain as integers. Before encoding, the list of atoms is sorted lexically using Value.'<'.

4.15.3.1 Select function

The select function uses the selection constraint for Oz finite domain variables to select one value from the list of values.

4.15.3.2 Make variable function

The make variable function creates an Oz finite domain variable ranging over the domain of the lattice.

4.15.3.3 Count function

The count function returns:

     o(fd: 1
       fs: 0)
4.15.3.4 Additional interface features

Below, we show the additional interface features of this lattice:

     constants: As
     card: CardI
     dSpec: DSpec
     a2I: A2I
     i2A: I2A

The constants feature corresponds to the list of atoms which constitute the finite domain, sorted lexically.

The card feature corresponds to an integer denoting the cardinality of the finite domain.

The dSpec feature corresponds to the finite domain specification of the finite domain.

The a2I feature corresponds to a function from Oz atoms in the finite domain to their corresponding Oz integers.

The i2A feature corresponds to a function from Oz integers in the finite domain to their corresponding Oz atoms.