Improving programs by the introduction of recursion
- 1 November 1977
- journal article
- Published by Association for Computing Machinery (ACM) in Communications of the ACM
- Vol. 20 (11) , 856-863
- https://doi.org/10.1145/359863.359889
Abstract
A new technique of program transformation, called “recursion introduction,” is described and applied to two algorithms which solve pattern matching problems. By using recursion introduction, algorithms which manipulate a stack are first translated into recursive algorithms in which no stack operations occur. These algorithms are then subjected to a second transformation, a method of recursion elimination called “tabulation,” to produce programs with a very efficient running time. In particular, it is shown how the fast linear pattern matching algorithm of Knuth, Morris, and Pratt can be derived in a few steps from a simple nonlinear stack algorithm.Keywords
This publication has 4 references indexed in Scilit:
- Notes on recursion eliminationCommunications of the ACM, 1977
- Structured Programming with go to StatementsACM Computing Surveys, 1974
- Program Schemes with Pushdown StoresSIAM Journal on Computing, 1972
- Another recursion induction principleCommunications of the ACM, 1971