Rewriting Techniques and Applications

The goal of this note is to compare two notions, one coming from the theory of rewrite systems and the other from proof theory: confluence and cut elimination. We show that to each rewrite system on terms, we can associate a logical system: asymmetric deduction modulo this rewrite system and that the confluence property of the rewrite system is equivalent to the cut elimination property of the associated logical system. This equivalence, however, does not extend to rewrite systems directly rewriting atomic propositions. The goal of this note is to compare two notions, one coming from the theory of rewrite systems and the other from proof theory: confluence and cut elimination. The confluence a rewrite system permits to reduce the search space when we want to establish that two terms are convertible. Similarly, the cut elimination property of a logical system permits to reduce the search space, when we want to establish that some proposition is provable. Moreover, both properties can be used to prove the decidability of convertibility or provability, when this reduction yields a finite search space. Finally, both properties can be used to prove independence results (i.e. that two terms are not convertible or that a proposition is not provable), and in particular consistency results, when this reduction yields an empty search space. The goal of this note is to show that this similarity between confluence and cut elimination can be seen as a consequence of the fact that to each rewrite system R rewriting terms, we can associate a logical system: asymmetric deduction modulo R, a variant of deduction modulo introduced in [5], and that the confluence property of the rewrite system is equivalent to the cut elimination property of the associated logical system. More precisely, we establish a parallel between – an equality t = u and a sequent P (t) P (u), – the notion of conversion sequence and that of proof, – the notion of peak and that of cut, and – the notion of valley sequence and that of cut free proof. Both valley sequences and cut free proofs may be called analytic as they exploit the information present in their conclusion and its sub-parts but no other information. R. Nieuwenhuis (Ed.): RTA 2003, LNCS 2706, pp. 2–13, 2003. c © Springer-Verlag Berlin Heidelberg 2003 Confluence as a Cut Elimination Property 3 Finally, we relate a method used to prove cut elimination by defining an algorithm transforming proofs step by step until all cuts are removed (see, for instance, [8]) and a method used to prove confluence by defining an algorithm transforming rewrite sequences step by step until all peaks are removed (see, for instance, [2,9,1]). As an example, we reformulate Newman’s confluence theorem [9] as a cut elimination theorem. Asymmetric deduction modulo can be extended by allowing not only rules rewriting terms in propositions, but also directly atomic propositions. With such rules, confluence and cut elimination do not coincide anymore and confluence is not a sufficient analyticity condition: it must be replaced by cut elimination. 1 Asymmetric Deduction Modulo In deduction modulo [5], the notions of language, term and proposition are that of first-order predicate logic. But a theory is formed with a set of axioms Γ and a congruence ≡ defined on propositions. Deduction rules are modified to take this congruence into account. For instance, the right rule of conjunction is not stated as usual Γ A,Δ Γ B,Δ Γ A ∧B,Δ as the conclusion need not be exactly A∧B but may be only convertible to this proposition, hence it is stated Γ A,Δ Γ B,Δ if C ≡ A ∧B Γ C,Δ All rules of sequent calculus, or natural deduction, may be defined in a similar way. In this note, we consider only congruences defined by a rewrite system on terms. A rewrite rule is a pair of terms 〈l, r〉, written l → r, such that l is not a variable. A rewrite system is a set of rules. Given such a system, the relation →1 is the smallest relation defined on terms and on propositions compatible with the structure of terms and propositions such that for all substitutions θ and all rewrite rules l → r of the rewrite system θl →1 θr. The relation →+ is the transitive closure of →1, the relation →∗ is its reflexive-transitive closure and the relation ≡ its reflexive-symmetric-transitive closure. Notice that rewriting does not change the logical structure of a proposition, in particular an atomic proposition only rewrites to an atomic proposition. A conversion sequence is a finite sequence of terms or propositions C1, ..., Cn such that for each i either Ci →1 Ci+1 or Ci ←1 Ci+1. Obviously two terms or two propositions A and B are convertible if there is a conversion sequence whose first element is A and last element is B. A peak in such a sequence is an index i such that Ci−1 ←1 Ci →1 Ci+1. A sequence is called a valley sequence if it contains no peak, i.e. if it has the form A →1 ... →1←1 ... ←1 B. For example, in arithmetic, we can define a congruence with the following rules 0 + y → y

[1]  Paliath Narendran,et al.  Complexity of Matching Problems , 1987, J. Symb. Comput..

[2]  David Monniaux Abstracting cryptographic protocols with tree automata , 2003, Sci. Comput. Program..

[3]  Toshinori Takai,et al.  Decidability and Closure Properties of Equational Tree Languages , 2002, RTA.

[4]  Ferenc Gécseg,et al.  Tree Languages , 1997, Handbook of Formal Languages.

[5]  David B. Loveman,et al.  Incorporation of units into programming languages , 1978, CACM.

[6]  George W. Macpherson A reusable Ada package for scientific dimensional integrity , 1996, ALET.

[7]  Thomas Colcombet Rewriting in the partial algebra of typed terms modulo AC , 2002, INFINITY.

[8]  Jean Goubault-Larrecq,et al.  A Method for Automatic Cryptographic Protocol Verification , 2000, IPDPS Workshops.

[9]  Mark E. Stickel The Path-Indexing Method for Indexing Terms , 1989 .

[10]  Mikael Rittri,et al.  Dimension inference under polymorphic recursion , 1995, FPCA '95.

[11]  Martin Odersky,et al.  Putting type annotations to work , 1996, POPL '96.

[12]  M. AdelsonVelskii,et al.  AN ALGORITHM FOR THE ORGANIZATION OF INFORMATION , 1963 .

[13]  Andrew John Kennedy,et al.  Programming languages and dimensions , 1995 .

[14]  Robin Milner,et al.  A Theory of Type Polymorphism in Programming , 1978, J. Comput. Syst. Sci..

[15]  Rudolf Bayer,et al.  Symmetric binary B-Trees: Data structure and maintenance algorithms , 1972, Acta Informatica.

[16]  Hitoshi Ohsaki,et al.  Beyond Regularity: Equational Tree Automata for Associative and Commutative Theories , 2001, CSL.

[17]  M. Minsky Recursive Unsolvability of Post's Problem of "Tag" and other Topics in Theory of Turing Machines , 1961 .

[18]  Thom W. Frühwirth,et al.  Logic programs as types for logic programs , 1991, [1991] Proceedings Sixth Annual IEEE Symposium on Logic in Computer Science.

[19]  Andrei Voronkov,et al.  The anatomy of vampire , 1995, Journal of Automated Reasoning.

[20]  Claude Kirchner,et al.  ELAN from a rewriting logic point of view , 2002, Theor. Comput. Sci..

[21]  Ronald T. House A Proposal for an Extended Form of Type Checking of Expressions , 1983, Comput. J..

[22]  Denis Lugiez A Good Class of Tree Automata , 1998 .

[23]  Hubert Comon,et al.  Tree automata techniques and applications , 1997 .

[24]  Mitchell Wand,et al.  First-order identities as a defining language , 1980, Acta Informatica.

[25]  Denis Lugiez,et al.  Counting and Equality Constraints for Multitree Automata , 2003, FoSSaCS.

[26]  Razvan Diaconescu,et al.  Logical foundations of CafeOBJ , 2002, Theor. Comput. Sci..

[27]  Rohit Parikh,et al.  On Context-Free Languages , 1966, JACM.

[28]  S. Ginsburg,et al.  Semigroups, Presburger formulas, and languages. , 1966 .

[29]  S. M. Eker,et al.  Associative-Commutative Matching Via Bipartite Graph Matching , 1995, Comput. J..