Abstract
An accumulation is a higher-order operation over structured objects of some type; it leaves the shape of an object unchanged, but replaces each element of that object with some accumulated information about the other elements. Upwards and downwards accumulations on trees are two instances of this scheme; they replace each element of a tree with some function—in fact, some homomorphism—of that element's descendants and of its ancestors, respectively. These two operations can be thought of as passing information up and down the tree.
We introduce these two accumulations, and show how together they solve the so-called prefix sums problem.
The author is grateful to Richard Bird, Geraint Jones, Lambert Meertens, David Skillicorn, and the anonymous referees, all of whom have made suggestions to improve the presentation of this paper.
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Selim G. Akl. Design and Analysis of Parallel Algorithms. Prentice-Hall, 1989.
Roland Backhouse. An exploration of the Bird-Meertens formalism. In International Summer School on Constructive Algorithmics, Hollum, Ameland. STOP project, 1989. Also available as Technical Report CS 8810, Department of Computer Science, Groningen University, 1988.
Richard S. Bird. An introduction to the theory of lists. In M. Broy, editor, Logic of Programming and Calculi of Discrete Design, pages 3–42. Springer-Verlag, 1987. Also available as Technical Monograph PRG-56, from the Programming Research Group, Oxford University.
Richard S. Bird. Lectures on constructive functional programming. In Manfred Broy, editor, Constructive Methods in Computer Science. Springer-Verlag, 1988. Also available as Technical Monograph PRG-69, from the Programming Research Group, Oxford University.
G. Estrin. Organization of computer systems—the fixed plus variable structure computer. In Proceedings Western Joint Computer Conference, pages 33–40, May 1960.
Maarten M. Fokkinga. Tupling and mutumorphisms. The Squiggolist, 1(4):81–82, June 1990.
Jeremy Gibbons. Algebras for Tree Algorithms. D. Phil. thesis, Programming Research Group, Oxford University, 1991. Also available as Technical Monograph PRG-94 from the Programming Research Group, Oxford.
Tatsuya Hagino. A Categorical Programming Language. PhD thesis, Laboratory for the Foundations of Computer Science, Edinburgh, September 1987.
Peter M. Kogge and Harold S. Stone. A parallel algorithm for the efficient solution of a general class of recurrence equations. IEEE Transactions on Computers, C-22(8):786–793, August 1973.
Richard E. Ladner and Michael J. Fischer. Parallel prefix computation. Journal of the ACM, 27(4):831–838, October 1980.
Grant Malcolm. Algebraic Data Types and Program Transformation. PhD thesis, Rijksuniversiteit Groningen, September 1990.
Lambert Meertens. Algorithmics: Towards programming as a mathematical activity. In J. W. de Bakker, M. Hazewinkel, and J. K. Lenstra, editors, Proc. CWI Symposium on Mathematics and Computer Science, pages 289–334. North-Holland, 1986.
Lambert Meertens. Paramorphisms. Technical Report CS-R9005, CWI, Amsterdam, 1990.
Gary L. Miller and John H. Reif. Parallel tree contraction and its application. In 26th FOCS, pages 478–489, 1985.
John T. O'Donnell. Derivation of fine-grain algorithms. Presentation at IFIP Working Group 2.8 meeting, Rome, 1990.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1993 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Gibbons, J. (1993). Upwards and downwards accumulations on trees. In: Bird, R.S., Morgan, C.C., Woodcock, J.C.P. (eds) Mathematics of Program Construction. MPC 1992. Lecture Notes in Computer Science, vol 669. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-56625-2_11
Download citation
DOI: https://doi.org/10.1007/3-540-56625-2_11
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-56625-0
Online ISBN: 978-3-540-47613-9
eBook Packages: Springer Book Archive