The Constraint Programming Paradigm
Introduces constraint programming (CP) as a declarative paradigm for combinatorial problems. Covers the three components of a CP model (variables, finite domains, constraints), constraint propagation for domain reduction, and global constraints such as alldifferent.
Tutorial
The Constraint Programming Paradigm
The constraint programming (CP) paradigm is a declarative approach to combinatorial problems. We describe what conditions a solution must satisfy, rather than how to find it.
A CP model consists of three components:
- Decision variables
- A finite domain for each variable — the set of values it may take.
- A set of constraints — arbitrary relations over the variables that solutions must satisfy.
For example, the problem "choose integers and between and such that and " becomes:
- Variables:
- Domains:
- Constraints:
Unlike in integer programming, CP constraints are not restricted to linear (in)equalities. They may include , logical implications, table lookups, and structured global relations stated directly.