文档介绍:SOME TRANSFORMATIONS FOR DEVELOPING RECURSIVE PROGRAMS
. Burstall and John Darlington
Department of Artificial Intelligence
University of Edinburgh
Edinburgh ~8 9NW
Keywords program transformation, program get to grips with the issue; the contrast is in
manipulation, optimisation, recursion. the program structure, particularly the recursion
Abstract (or loop) structure. We are interested in
starting with programs having an extremely simple
The paper describes a system of rules for structure and only later introducing plic-
transforming programs, the programs being in the ations which we usually take for granted even in
form of recursion equations. The idea is to high level language programs. plications
start with a very simple, lucid and hopefully arise by introducing useful interactions between
correct program, then to transform it into a more what were originally separate parts of the program,
efficient one by altering the recursion structure. benefiting by what might be called 'economies of
Illustrative examples of program transformations interaction'.
are given, and a tentative implementation is
described. We hope to throw some light on the We will proceed here in a quite empirical
alternative structures for programs, also to manner, just showing examples of various kinds of
indicate a possible initial phase for an auto- progr