Abstract rewriting system
In mathematical logic and theoretical computer science, an abstract rewriting system (also (abstract) reduction system or abstract rewrite system; abbreviated ARS) is a formalism that captures the quintessential notion and properties of rewriting systems. In its simplest form, an ARS is simply a set (of "objects") together with a binary relation, traditionally denoted with [math]\displaystyle{ \rightarrow }[/math]; this definition can be further refined if we index (label) subsets of the binary relation. Despite its simplicity, an ARS is sufficient to describe important properties of rewriting systems like normal forms, termination, and various notions of confluence.
Historically, there have been several formalizations of rewriting in an abstract setting, each with its idiosyncrasies. This is due in part to the fact that some notions are equivalent, see below in this article. The formalization that is most commonly encountered in monographs and textbooks, and which is generally followed here, is due to Gérard Huet (1980).[1]
Definition
An abstract reduction system (ARS) is the most general (unidimensional) notion about specifying a set of objects and rules that can be applied to transform them. More recently, authors use the term abstract rewriting system as well.[2] (The preference for the word "reduction" here instead of "rewriting" constitutes a departure from the uniform use of "rewriting" in the names of systems that are particularizations of ARS. Because the word "reduction" does not appear in the names of more specialized systems, in older texts reduction system is a synonym for ARS.)[3]
An ARS is a set A, whose elements are usually called objects, together with a binary relation on A, traditionally denoted by →, and called the reduction relation, rewrite relation[2] or just reduction.[3] This (entrenched) terminology using "reduction" is a little misleading, because the relation is not necessarily reducing some measure of the objects.
In some contexts it may be beneficial to distinguish between some subsets of the rules, i.e. some subsets of the reduction relation →, e.g. the entire reduction relation may consist of associativity and commutativity rules. Consequently, some authors define the reduction relation → as the indexed union of some relations; for instance if [math]\displaystyle{ {\rightarrow_1 \cup \rightarrow_2} = {\rightarrow} }[/math], the notation used is (A, →1, →2).
As a mathematical object, an ARS is exactly the same as an unlabeled state transition system, and if the relation is considered as an indexed union, then an ARS is the same as a labeled state transition system with the indices being the labels. The focus of the study, and the terminology are different however. In a state transition system one is interested in interpreting the labels as actions, whereas in an ARS the focus is on how objects may be transformed (rewritten) into others.[4]
Example 1
Suppose the set of objects is T = {a, b, c} and the binary relation is given by the rules a → b, b → a, a → c, and b → c. Observe that these rules can be applied to both a and b to get c. Furthermore, nothing can be applied to c to transform it any further. Such a property is clearly an important one.
Basic notions
First define some basic notions and notations.[5]
- [math]\displaystyle{ \stackrel{+}{\rightarrow} }[/math] is the transitive closure of [math]\displaystyle{ \rightarrow }[/math].
- [math]\displaystyle{ \stackrel{*}{\rightarrow} }[/math] is the reflexive transitive closure of [math]\displaystyle{ \rightarrow }[/math], i.e. the transitive closure of [math]\displaystyle{ (\rightarrow) \cup (=) }[/math], where = is the identity relation. Equivalently, [math]\displaystyle{ \stackrel{*}{\rightarrow} }[/math] is the smallest preorder containing [math]\displaystyle{ \rightarrow }[/math].
- [math]\displaystyle{ \leftrightarrow }[/math] is the symmetric closure of [math]\displaystyle{ \rightarrow }[/math], that is, [math]\displaystyle{ (\rightarrow) \cup (\rightarrow)^{-1} }[/math] i.e. the union of the relation → with its converse relation.
- [math]\displaystyle{ \stackrel{*}{\leftrightarrow} }[/math] is the reflexive transitive symmetric closure of [math]\displaystyle{ \rightarrow }[/math], i.e. the transitive closure of [math]\displaystyle{ (\leftrightarrow) \cup (=) }[/math]. Equivalently, [math]\displaystyle{ \stackrel{*}{\leftrightarrow} }[/math] is the smallest equivalence relation containing [math]\displaystyle{ \rightarrow }[/math].
Normal forms
An object x in A is called reducible if there exist some other y in A and [math]\displaystyle{ x \rightarrow y }[/math]; otherwise it is called irreducible or a normal form. An object y is called a normal form of x if [math]\displaystyle{ x \stackrel{*}{\rightarrow} y }[/math] and y is irreducible. If x has a unique normal form, then this is usually denoted with [math]\displaystyle{ x\downarrow }[/math]. In example 1 above, c is a normal form, and [math]\displaystyle{ c = a\downarrow = b\downarrow }[/math]. If every object has at least one normal form, the ARS is called normalizing.
Joinability
A related, but weaker notion than the existence of normal forms is that of two objects being joinable: x and y are said to be joinable if there exists some z with the property that [math]\displaystyle{ x \stackrel{*}{\rightarrow} z \stackrel{*}{\leftarrow} y }[/math]. From this definition, it's apparent one may define the joinability relation as [math]\displaystyle{ \stackrel{*}{\rightarrow} \circ \stackrel{*}{\leftarrow} }[/math], where [math]\displaystyle{ \circ }[/math] is the composition of relations. Joinability is usually denoted, somewhat confusingly, also with [math]\displaystyle{ \downarrow }[/math], but in this notation the down arrow is a binary relation, i.e. we write [math]\displaystyle{ x\mathbin\downarrow y }[/math] if x and y are joinable.
The Church–Rosser property and notions of confluence
An ARS is said to possess the Church–Rosser property if and only if [math]\displaystyle{ x \stackrel{*}{\leftrightarrow} y }[/math] implies [math]\displaystyle{ x\mathbin\downarrow y }[/math] for all objects x, y. Equivalently, the Church–Rosser property means that the reflexive transitive symmetric closure is contained in the joinability relation. Alonzo Church and J. Barkley Rosser proved in 1936 that lambda calculus has this property;[6] hence the name of the property.[7] In an ARS with the Church–Rosser property the word problem may be reduced to the search for a common successor. In a Church–Rosser system, an object has at most one normal form; that is, the normal form of an object is unique if it exists, but it may well not exist.
Various properties, simpler than Church–Rosser, are equivalent to it. The existence of these equivalent properties allows one to prove that a system is Church–Rosser with less work. Furthermore, the notions of confluence can be defined as properties of a particular object, something that's not possible for Church–Rosser. An ARS [math]\displaystyle{ (A,\rightarrow) }[/math] is said to be,
- confluent if and only if for all w, x, and y in A, [math]\displaystyle{ x \stackrel{*}{\leftarrow} w \stackrel{*}{\rightarrow} y }[/math] implies [math]\displaystyle{ x\mathbin\downarrow y }[/math]. Roughly speaking, confluence says that no matter how two paths diverge from a common ancestor (w), the paths are joining at some common successor. This notion may be refined as property of a particular object w, and the system called confluent if all its elements are confluent.
- semi-confluent if and only if for all w, x, and y in A, [math]\displaystyle{ x \leftarrow w \stackrel{*}{\rightarrow} y }[/math] implies [math]\displaystyle{ x\mathbin\downarrow y }[/math]. This differs from confluence by the single step reduction from w to x.
- locally confluent if and only if for all w, x, and y in A, [math]\displaystyle{ x \leftarrow w \rightarrow y }[/math] implies [math]\displaystyle{ x\mathbin\downarrow y }[/math]. This property is sometimes called weak confluence.
Theorem. For an ARS the following three conditions are equivalent: (i) it has the Church–Rosser property, (ii) it is confluent, (iii) it is semi-confluent.[8]
Corollary.[9] In a confluent ARS if [math]\displaystyle{ x \stackrel{*}{\leftrightarrow} y }[/math] then
- If both x and y are normal forms, then x = y.
- If y is a normal form, then [math]\displaystyle{ x \stackrel{*}{\rightarrow} y }[/math].
Because of these equivalences, a fair bit of variation in definitions is encountered in the literature. For instance, in Terese the Church–Rosser property and confluence are defined to be synonymous and identical to the definition of confluence presented here; Church–Rosser as defined here remains unnamed, but is given as an equivalent property; this departure from other texts is deliberate.[10] Because of the above corollary, one may define a normal form y of x as an irreducible y with the property that [math]\displaystyle{ x \stackrel{*}{\leftrightarrow} y }[/math]. This definition, found in Book and Otto, is equivalent to the common one given here in a confluent system, but it is more inclusive in a non-confluent ARS.
Local confluence on the other hand is not equivalent with the other notions of confluence given in this section, but it is strictly weaker than confluence. The typical counterexample is [math]\displaystyle{ \{b\rightarrow c, c\rightarrow b, b\rightarrow a, c\rightarrow d\} }[/math], which is locally confluent but not confluent (cf. picture).
Termination and convergence
An abstract rewriting system is said to be terminating or noetherian if there is no infinite chain [math]\displaystyle{ x_0 \rightarrow x_1 \rightarrow x_2 \rightarrow \cdots }[/math]. (This is just saying that the rewriting relation is a Noetherian relation.) In a terminating ARS, every object has at least one normal form, thus it is normalizing. The converse is not true. In example 1 for instance, there is an infinite rewriting chain, namely [math]\displaystyle{ a \rightarrow b \rightarrow a \rightarrow b \rightarrow \cdots }[/math], even though the system is normalizing. A confluent and terminating ARS is called canonical,[11] or convergent. In a convergent ARS, every object has a unique normal form. But it is sufficient for the system to be confluent and normalizing for a unique normal to exist for every element, as seen in example 1.
Theorem (Newman's Lemma): A terminating ARS is confluent if and only if it is locally confluent.
The original 1942 proof of this result by Newman was rather complicated. It wasn't until 1980 that Huet published a much simpler proof exploiting the fact that when [math]\displaystyle{ \rightarrow }[/math] is terminating we can apply well-founded induction.[12]
See also
- Word problem (mathematics) — particularly the section on abstract rewriting systems
Notes
- ↑ Book & Otto 1993, p. 9
- ↑ 2.0 2.1 Terese 2003, p. 7
- ↑ 3.0 3.1 Book & Otto 1993, p. 10
- ↑ Terese 2003, pp. 7–8
- ↑ Baader & Nipkow 1998, pp. 8–9
- ↑ Church & Rosser 1936
- ↑ Baader & Nipkow 1998, p. 9
- ↑ Baader & Nipkow 1998, p. 11
- ↑ Baader & Nipkow 1998, p. 12
- ↑ Terese 2003, p. 11
- ↑ Duffy 1991, p. 153, sect.7.2.1
- ↑ Harrison 2009, p. 260
References
- Baader, Franz; Nipkow, Tobias (1998). Term Rewriting and All That. Cambridge University Press. ISBN 9780521779203. https://books.google.com/books?id=N7BvXVUCQk8C. A textbook suitable for undergraduates.
- Nachum Dershowitz and Jean-Pierre Jouannaud Rewrite Systems, Chapter 6 in Jan van Leeuwen (Ed.), Handbook of Theoretical Computer Science, Volume B: Formal Models and Semantics, Elsevier and MIT Press, 1990, ISBN:0-444-88074-7, pp. 243–320. The preprint of this chapter is freely available from the authors, but it misses the figures.
- Book, Ronald V.; Otto, Friedrich (1993). "1, "Abstract reduction systems"". String-rewriting Systems. Springer. ISBN 0-387-97965-4.
- Marc Bezem; Jan Willem Klop; Roel de Vrijer; Terese (2003). "1". Term rewriting systems. Cambridge University Press. ISBN 0-521-39115-6. This is a comprehensive monograph. It uses, however, a fair deal of notations and definitions not commonly encountered elsewhere. For instance the Church–Rosser property is defined to be identical with confluence.
- Harrison, John (2009). "4 "Equality"". Handbook of Practical Logic and Automated Reasoning Cambridge University Press. ISBN 978-0-521-89957-4. Abstract rewriting from the practical perspective of solving problems in equational logic.
- Gérard Huet, Confluent Reductions: Abstract Properties and Applications to Term Rewriting Systems, Journal of the ACM (JACM), October 1980, Volume 27, Issue 4, pp. 797–821. Huet's paper established many of the modern concepts, results and notations.
- Sinyor, J.; "The 3x+1 Problem as a String Rewriting System", International Journal of Mathematics and Mathematical Sciences, Volume 2010 (2010), Article ID 458563, 6 pages.
- Duffy, David A. (1991). Principles of Automated Theorem Proving. Wiley.
- Church, Alonzo; Rosser, J. B. (1936). "Some Properties of Conversion". Transactions of the American Mathematical Society 39 (3): 472–482. doi:10.2307/1989762. ISSN 0002-9947.
Original source: https://en.wikipedia.org/wiki/Abstract rewriting system.
Read more |