On Confluence of Constraint Handling Rules

07/1996; DOI: 10.1007/3-540-61551-2_62
Source: CiteSeer

ABSTRACT . We introduce the notion of confluence for Constraint Handling Rules (CHR), a powerful language for writing constraint solvers. With CHR one simplifies and solves constraints by applying rules. Confluence guarantees that a CHR program will always compute the same result for a given set of constraints independent of which rules are applied. We give a decidable, sufficient and necessary syntactic condition for confluence. Confluence turns out to be an essential syntactical property of CHR programs for two reasons. First, confluence implies correctness (as will be shown in this paper). In a correct CHR program, application of CHR rules preserves logical equivalence of the simplified constraints. Secondly, even when the program is already correct, confluence is highly desirable. Otherwise, given some constraints, one computation may detect their inconsistency while another one may just simplify them into a still complex constraint. As a side-effect, the paper also gives soundness and com...

1 Follower
  • Source
    [Show abstract] [Hide abstract]
    ABSTRACT: The programming language of Constraint Handling Rules (CHR) is gaining more and more popularity and this has motivated the development of new optimization techniques to be applied in implemen-tations of CHR. As for other logic programming languages, a program written CHR can be understood declaratively as a logical formula and as a procedural specification, and CHR has different tools for manual optimization at the procedural level whose application may (or may not) sacrifice the declarative reading. One such optimization is given by pas-sive declarations by means of which the search for rules to be applied can be optimized, perhaps changing which rules that are applied and in which order. A framework for analyzing the effect of passive declarations is presented in terms of a slightly abstract operational semantics which takes into account the effect of passive declarations. Based on it, we can give different classifications of the effect of some passive declarations that do not affect the logical semantics. This may be used for reasoning about manual optimizations as well as proposals for automatic strategies to be applied by a compiler for adding passive declarations.
  • Source
  • [Show abstract] [Hide abstract]
    ABSTRACT: In this paper, parsing as deduction and constraint programming are brought together to outline a procedure for the specication of constraint-based (chart) parsers. Extending the proposal in Shieber (1995) which provides a meta interpreter for several deduction sys- tems, we show how to directly realize the inference rules for chart parsers as Constraint Handling Rules (Fr uhwirth, 1998) by viewing the items of a conventional chart parser as constraints and the constraint base as a chart. This allows the direct use of the con- straint resolution process to parse sentences in diverse natural language formalisms such as minimalist grammars (Stabler, 1997; Stabler, 2001) or property grammars (Blache, 2000; Balfourier et al., 2002).