Programming in Equational Logic: Beyond Strong Sequentiality
Orthogonal term rewriting systems (also known as regular systems) provide an elegant framework for programming in equational logic. O′Donnell showed that the parallel-outermost strategy, which replaces all outermost redexes in each step, is complete for such systems. Many of the reductions performed...
Gespeichert in:
Veröffentlicht in: | Information and computation 1993-05, Vol.104 (1), p.78-109 |
---|---|
Hauptverfasser: | , |
Format: | Artikel |
Sprache: | eng |
Online-Zugang: | Volltext |
Tags: |
Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
|
Zusammenfassung: | Orthogonal term rewriting systems (also known as regular systems) provide an elegant framework for programming in equational logic. O′Donnell showed that the parallel-outermost strategy, which replaces all outermost redexes in each step, is complete for such systems. Many of the reductions performed by this strategy could be wasteful in general. A lazy normalization algorithm that completely eliminated these wasteful reductions by reducing only "needed redexes" was later developed by Huet and Levy. However, this algorithm required the input programs to be restricted to the subclass of strongly sequential systems. This is because needed redexes do not exist for all orthogonal programs, and even when they do, they may not be computable. It is therefore quite natural to ask whether it is possible to devise a complete normalization algorithm for the entire class that minimizes (rather than eliminates) the wasteful reductions. In this paper we propose a solution to this problem using the concept of a necessary set of redexes. In such a set, at least one of the redexes must be reduced to normalize a term. We devise an algorithm to compute a necessary set for any term not in normal form and show that a strategy that repeatedly reduces all redexes in such a set is complete for orthogonal programs. We also show that our algorithm is "optimal" among all normalization algorithms that are based on left-hand sides alone. This means that our algorithm is lazy (like Huet and Levy′s) on strongly sequential parts of a program and "relaxes laziness minimally" to handle the other parts and thus does not sacrifice generality for the sake of efficiency. |
---|---|
ISSN: | 0890-5401 1090-2651 |
DOI: | 10.1006/inco.1993.1026 |