HOME

TheInfoList



OR:

In
theoretical computer science Theoretical computer science (TCS) is a subset of general computer science and mathematics that focuses on mathematical aspects of computer science such as the theory of computation, lambda calculus, and type theory. It is difficult to circumsc ...
, in particular in
automated reasoning In computer science, in particular in knowledge representation and reasoning and metalogic, the area of automated reasoning is dedicated to understanding different aspects of reasoning. The study of automated reasoning helps produce computer progra ...
about formal equations, reduction orderings are used to prevent
endless loop , also called Eiko or Peko, is a female J-pop singer-songwriter, and producer who is currently affiliated with Heart Company. She is best known for singing the opening themes of the anime series ''Higurashi When They Cry''. Eiko also handles a s ...
s. Rewrite orders, and, in turn, rewrite relations, are generalizations of this concept that have turned out to be useful in theoretical investigations.


Motivation

Intuitively, a reduction order ''R'' relates two formal expressions ''s'' and ''t'' if ''t'' is properly "simpler" than ''s'' in some sense. For example, simplification of terms may be a part of a
computer algebra In mathematics and computer science, computer algebra, also called symbolic computation or algebraic computation, is a scientific area that refers to the study and development of algorithms and software for manipulating mathematical expressions ...
program, and may be using the rule set . In order to prove impossibility of endless loops when simplifying a term, the reduction order defined by "''sRt'' if expression ''t'' is properly shorter than expression ''s''" can be used; applying any rule from the set will always properly shorten the term. In contrast, to establish termination of "distributing-out" using the rule ''x''*(''y''+''z'') → ''x''*''y''+''x''*''z'', a more elaborate reduction order will be needed, since this rule may blow up the term size due to duplication of ''x''. The theory of rewrite orders aims at helping to provide an appropriate order in such cases.


Formal definitions

Formally, a
binary relation In mathematics, a binary relation associates elements of one set, called the ''domain'', with elements of another set, called the ''codomain''. A binary relation over Set (mathematics), sets and is a new set of ordered pairs consisting of ele ...
(→) on the set of
term Term may refer to: * Terminology, or term, a noun or compound word used in a specific context, in particular: **Technical term, part of the specialized vocabulary of a particular field, specifically: ***Scientific terminology, terms used by scient ...
s is called a rewrite relation if it is
closed Closed may refer to: Mathematics * Closure (mathematics), a set, along with operations, for which applying those operations on members always results in a member of the set * Closed set, a set which contains all its limit points * Closed interval, ...
under contextual embedding and under instantiation; formally: if ''l''→''r'' implies ''u'' σ.html" ;"title="Substitution (logic)#First-order logic">σ">Substitution (logic)#First-order logic">σsub>''p''→''u'' 'r''σsub>''p'' for all terms ''l'', ''r'', ''u'', each path ''p'' of ''u'', and each
substitution Substitution may refer to: Arts and media *Chord substitution, in music, swapping one chord for a related one within a chord progression * Substitution (poetry), a variation in poetic scansion * "Substitution" (song), a 2009 song by Silversun Pi ...
σ. If (→) is also
irreflexive In mathematics, a binary relation ''R'' on a set ''X'' is reflexive if it relates every element of ''X'' to itself. An example of a reflexive relation is the relation " is equal to" on the set of real numbers, since every real number is equal to ...
and transitive, then it is called a rewrite ordering, or rewrite
preorder In mathematics, especially in order theory, a preorder or quasiorder is a binary relation that is reflexive and transitive. Preorders are more general than equivalence relations and (non-strict) partial orders, both of which are special c ...
. If the latter (→) is moreover
well-founded In mathematics, a binary relation ''R'' is called well-founded (or wellfounded) on a class ''X'' if every non-empty subset ''S'' ⊆ ''X'' has a minimal element with respect to ''R'', that is, an element ''m'' not related by ''s& ...
, it is called a reduction ordering,Dershowitz, Jouannaud (1990), sect.5.1, p.270 or a reduction preorder. Given a binary relation ''R'', its rewrite closure is the smallest rewrite relation containing ''R''.Dershowitz, Jouannaud (1990), sect.2.2, p.252 A transitive and reflexive rewrite relation that contains the
subterm In mathematical logic, a term denotes a mathematical object while a formula denotes a mathematical fact. In particular, terms appear as components of a formula. This is analogous to natural language, where a noun phrase refers to an object and a wh ...
ordering is called a simplification ordering.Dershowitz, Jouannaud (1990), sect.5.2, p.274


Properties

* The
converse Converse may refer to: Mathematics and logic * Converse (logic), the result of reversing the two parts of a definite or implicational statement ** Converse implication, the converse of a material implication ** Converse nonimplication, a logical c ...
, the
symmetric closure In mathematics, the symmetric closure of a binary relation R on a set X is the smallest symmetric relation on X that contains R. For example, if X is a set of airports and xRy means "there is a direct flight from airport x to airport y", then the ...
, the
reflexive closure In mathematics, the reflexive closure of a binary relation ''R'' on a set ''X'' is the smallest reflexive relation on ''X'' that contains ''R''. For example, if ''X'' is a set of distinct numbers and ''x R y'' means "''x'' is less than ''y''", the ...
, and the
transitive closure In mathematics, the transitive closure of a binary relation on a set is the smallest relation on that contains and is transitive. For finite sets, "smallest" can be taken in its usual sense, of having the fewest related pairs; for infinite s ...
of a rewrite relation is again a rewrite relation, as are the union and the intersection of two rewrite relations.Dershowitz, Jouannaud (1990), sect.2.1, p.251 * The converse of a rewrite order is again a rewrite order. * While rewrite orders exist that are total on the set of
ground term In mathematical logic, a ground term of a formal system is a term that does not contain any variables. Similarly, a ground formula is a formula that does not contain any variables. In first-order logic with identity, the sentence Q(a) \lor P(b) ...
s ("ground-total" for short), no rewrite order can be total on the set of all terms.Since ''x''<''y'' implies ''y''<''x'', since the latter is an instance of the former, for variables ''x'', ''y''.Dershowitz, Jouannaud (1990), sect.5.1, p.272 * A
term rewriting system In mathematics, computer science, and logic, rewriting covers a wide range of methods of replacing subterms of a formula with other terms. Such methods may be achieved by rewriting systems (also known as rewrite systems, rewrite engines, or red ...
is terminating if its rules are a subset of a reduction ordering.i.e. if for all ''i'', where (>) is a reduction ordering; the system needn't have finitely many rules * Conversely, for every terminating term rewriting system, the
transitive closure In mathematics, the transitive closure of a binary relation on a set is the smallest relation on that contains and is transitive. For finite sets, "smallest" can be taken in its usual sense, of having the fewest related pairs; for infinite s ...
of (::=) is a reduction ordering, which needn't be extendable to a ground-total one, however. For example, the ground term rewriting system is terminating, but can be shown so using a reduction ordering only if the constants ''a'' and ''b'' are incomparable.Since e.g. implied , meaning the second rewrite rule was not decreasing.Dershowitz, Jouannaud (1990), sect.5.1, p.271 * A ground-total and well-founded rewrite orderingi.e. a ground-total reduction ordering necessarily contains the proper subterm relation on ground terms. * Conversely, a rewrite ordering that contains the subterm relationi.e. a simplification ordering is necessarily well-founded, when the set of function symbols is finite.The proof of this property is based on
Higman's lemma In mathematics, Higman's lemma states that the set of finite sequences over a finite alphabet, as partially ordered by the subsequence relation, is well-quasi-ordered. That is, if w_1, w_2, \ldots is an infinite sequence of words over some fixed ...
, or, more generally,
Kruskal's tree theorem In mathematics, Kruskal's tree theorem states that the set of finite trees over a well-quasi-ordered set of labels is itself well-quasi-ordered under homeomorphic embedding. History The theorem was conjectured by Andrew Vázsonyi and proved by ...
.
* A finite term rewriting system is terminating if its rules are subset of the strict part of a simplification ordering. Here: p.287; the notions are named slightly different.


Notes


References

{{Reflist Rewriting systems Order theory