## 5.135. domain

Origin

Domain definition.

Constraint

$\mathrm{\pi \pi \pi \pi \pi \pi }\left(\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi },\mathrm{\pi »\pi Ύ\pi },\mathrm{\pi \pi Ώ}\right)$

Synonym

$\mathrm{\pi \pi \pi }$.

Arguments
 $\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }$ $\mathrm{\pi \pi \pi \pi \pi \pi \pi \pi \pi \pi }\left(\mathrm{\pi \pi \pi }-\mathrm{\pi \pi \pi \pi }\right)$ $\mathrm{\pi »\pi Ύ\pi }$ $\mathrm{\pi \pi \pi }$ $\mathrm{\pi \pi Ώ}$ $\mathrm{\pi \pi \pi }$
Restrictions
 $\mathrm{\pi \pi \pi \pi \pi \pi \pi \pi }$$\left(\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi },\mathrm{\pi \pi \pi }\right)$ $\mathrm{\pi »\pi Ύ\pi }\beta €\mathrm{\pi \pi Ώ}$
Purpose

Enforce all the variables of the collection $\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }$ to take a value within the interval $\left[\mathrm{\pi »\pi Ύ\pi },\mathrm{\pi \pi Ώ}\right]$.

Example
$\left(β©2,8,2βͺ,1,9\right)$

The $\mathrm{\pi \pi \pi \pi \pi \pi }$ constraint holds since all the values 2, 8 and 2 of its first argument are greater than or equal to its second argument $\mathrm{\pi »\pi Ύ\pi }=1$ and less than or equal to its third argument $\mathrm{\pi \pi Ώ}=9$.

Typical
 $|\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }|>1$ $\mathrm{\pi »\pi Ύ\pi }<\mathrm{\pi \pi Ώ}$
Symmetries
• Items of $\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }$ are permutable.

• An occurrence of a value of $\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }.\mathrm{\pi \pi \pi }$ can be replaced by any other value in $\left[\mathrm{\pi »\pi Ύ\pi },\mathrm{\pi \pi Ώ}\right]$.

• $\mathrm{\pi »\pi Ύ\pi }$ can be decreased.

• $\mathrm{\pi \pi Ώ}$ can be increased.

• One and the same constant can be added to the $\mathrm{\pi \pi \pi }$ attribute of all items of $\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }$ as well as to $\mathrm{\pi »\pi Ύ\pi }$ and $\mathrm{\pi \pi Ώ}$.

Arg. properties

Contractible wrt. $\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }$.

Remark

The $\mathrm{\pi \pi \pi \pi \pi \pi }$ constraint is called $\mathrm{\pi \pi \pi }$ in Gecode (http://www.gecode.org/).

Reformulation

The $\mathrm{\pi \pi \pi \pi \pi \pi }$$\left(\beta ©\mathrm{\pi \pi \pi }-{V}_{1},\mathrm{\pi \pi \pi }-{V}_{2},\beta ―,\mathrm{\pi \pi \pi }-{V}_{|\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }|}\beta ͺ,\mathrm{\pi »\pi Ύ\pi },\mathrm{\pi \pi Ώ}\right)$ constraint can be expressed in term of the conjunction

Β Β Β ${V}_{1}\beta ₯\mathrm{\pi »\pi Ύ\pi }\beta §{V}_{1}\beta €\mathrm{\pi \pi Ώ}$,

Β Β Β ${V}_{2}\beta ₯\mathrm{\pi »\pi Ύ\pi }\beta §{V}_{2}\beta €\mathrm{\pi \pi Ώ}$,

Β Β Β Β $\beta ―\beta ―\beta ―\beta ―\beta ―\beta ―$

Β Β Β ${V}_{|\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }|}\beta ₯\mathrm{\pi »\pi Ύ\pi }\beta §{V}_{|\mathrm{\pi  \pi °\pi \pi Έ\pi °\pi ±\pi »\pi ΄\pi }|}\beta €\mathrm{\pi \pi Ώ}$.

Systems

member in Choco, dom in Gecode, domain in SICStus.