Recent Advances in Constraints

Volume 3978 of the series Lecture Notes in Computer Science pp 14-28

Complete Propagation Rules for Lexicographic Order Constraints over Arbitrary Domains

  • Thom FrühwirthAffiliated withFaculty of Computer Science, University of Ulm

* Final gross prices may vary according to local VAT.

Get Access


We give an efficiently executable specification of the global constraint of lexicographic order in the Constraint Handling Rules (CHR) language. In contrast to previous approaches, the implementation is short and concise without giving up on the best known worst case time complexity. It is incremental and concurrent by nature of CHR. It is provably correct and confluent. It is independent of the underlying constraint system, and therefore not restricted to finite domains. We have found a direct recursive decomposition of the problem. We also show completeness of constraint propagation, i.e. that all possible logical consequences of the constraint are generated by the implementation. Finally, we report about some practical implementation experiments.