Design, implementation, and evaluation of the constraint language \(cc(FD)\).

*(English)*Zbl 0920.68026Summary: This paper describes the design, implementation, and applications of the constraint logic language \(cc(FD)\). \(cc(FD)\) is a declarative nondeterministic constraint logic language over finite domains based on the \(cc\) framework, an extension of the Constraint Logic Programming (CLP) scheme. Its constraint solver includes (nonlinear) arithmetic constraints over natural numbers which are approximated using domain and interval consistency. The main novelty of \(cc(FD)\) is the inclusion of a number of general-purpose combinators, in particular cardinality, constructive disjunction, and blocking implication, in conjunction with new constraint operations such as constraint entailment and generalization. These combinators significantly improve the operational expressiveness, extensibility, and flexibility of CLP languages and allow issues such as the definition of nonprimitive constraints and disjunctions to be tackled at the language level. The implementation of \(cc(FD)\) (about 40,000 lines of C) includes a WAM-based engine, optimal arc-consistency algorithms based on AC-5, and incremental implementation of the combinators. Results on numerous problems, including scheduling, resource allocation, sequencing, packing, and Hamiltonian paths are reported and indicate that \(cc(FD)\) comes close to procedural languages on a number of combinatorial problems. In addition, a small \(cc(FD)\) program was able to find the optimal solution and prove optimality to a famous 10/10 disjunctive scheduling problem, which was left open for more than 20 years and finally solved in 1986.

##### MSC:

68N15 | Theory of programming languages |