[ library(fd) | Reference Manual | Alphabetic Index ]

dom_union(+Dom1, +Dom2, -DomUnion, -Size)

The domain DomUnion is the union of domains Dom1 and Dom2 and Size is the number of its elements.
+Dom1
A finite domain.
+Dom2
A finite domain.
-DomUnion
A variable.
-Size
A variable.

Description

The domain DomUnion is the union of domains Dom1 and Dom2 and Size is the number of its elements.

Note that the main use of the predicate is to yield the most specific generalisation of two domains, in the usual cases the domains become smaller, not bigger.

Fail Conditions

Fails if the union is empty.

Resatisfiable

No.

See Also

dom_compare / 3, dom_member / 2, dom_range / 3, dom_size / 2, dvar_domain / 2