Abstract
We study a restricted programming language over tree structures. For this language, we give systematic translation rules which map programs into complexity descriptors. The descriptors are in the form of generating functions of average costs. Such a direct approach avoids recourse to recurrences; it therefore simplifies the task of analyzing algorithms in the class considered and permits analysis of structurally complex programs. It also allows a clear discussion of analytic properties of complexity descriptors whose singularities are related to the asymptotic behavior of average costs. Algorithms that are analyzed in this way include formal differentiation, tree matching, tree compatibility, and simplification of expressions in a diversity of contexts. Some general results relating (average case) complexity properties to structural properties of programs in the class can also be derived in this framework.
Similar content being viewed by others
References
J. Berstel and C. Reutenauer, Recognizable formal power series on trees,Theoret. Comput. Sci.,18 (1982), 128–145.
W. Burge,Recursive Programming Techniques, Addison-Wesley, Reading, MA, 1975.
G. Darboux, Mémoire sur l'approximation des fonctions de très grands nombres, et sur une classe étendue de développements en série,J. Math. Pures Appl. (3)IV (1878), 1–56.
P. Flajolet, Analyse d'algorithmes de manipulation d'arbres et de fichiers, Thèse, Paris, 1979; Cahiers du B.U.R.O. No. 34–35, Paris, 1981.
P. Flajolet and A. Odlyzko, The average height of binary trees and other simple trees,J. Comput. System Sci.,25 (1982), 171–213.
D. Foata and M.-P. Schützenberger,Théorie géométrique des polynômes eulériens, Lecture Notes in Mathematics, Vol. 138, Springer-Verlag, Berlin, 1970.
I. J. Good, Generalizations to several variables of Lagrange's expansion, with applications to stochastic processes,Math. Proc. Cambridge Philos. Soc.,56 (1960), 367–380.
I. J. Good, The generalization of Lagrange's expansion and the enumeration of trees,Math. Proc. Cambridge Philos. Soc.,61 (1965), 499–517.
I. Goulden and D. Jackson,Combinatorial Enumeration, Wiley, New York, 1983.
P. Henrici,Applied and Computational Complex Analysis, Wiley, New York, 1974.
D. E. Knuth,The Art of Computer Programming: Fundamental Algorithms, Addison-Wesley, Reading, MA, 1968.
D. E. Knuth,The Art of Computer Programming: Sorting and Searching, Addison-Wesley, Reading, MA, 1973.
A. Meir and J. W. Moon, On the altitude of nodes in random trees,Canad. J. Math.,30 (1978), 997–1015.
A. Odlyzko, Periodic oscillations of coefficients of power series that satisfy functional equations,Adv. in Math.,44 (1982), 180–205.
G. Polya, Kombinatorische Anzahlbestimmungen für Graphen, Gruppen und chemische Verbindungen,Acta Math.,68 (1937), 145–254.
L. Ramshaw, Formalizing the analysis of algorithms, Ph.D. thesis, Stanford University, Stanford, CA, 1979.
G.-C. Rota,Finite Operator Calculus, Academic Press, New York, 1975.
J.-M. Steyaert, Structure et complexité des algorithmes, Thèse, Paris, 1984.
J.-M. Steyaert and P. Flajolet, Patterns and pattern-matching in trees: an analysis,Inform. and Control,58 (1983), 19–58.
J. W. Thatcher, Tree automata: an informal survey, inCurrents in the Theory of Computing (A. V. Aho, ed.), Prentice Hall, Englewood Cliffs, NJ, 1973, pp. 143–178.
J. Vuillemin, A unifying look at data structures,Comm. ACM,23 (1980), 229–239.
B. Wegbreit, Mechanical program analysis,Comm. ACM,18 (1975), 528–532.
B. Wegbreit, Verifying program performance,J. Assoc. Comput. Mach.,23 (1976), 691–699.
Author information
Authors and Affiliations
Rights and permissions
About this article
Cite this article
Flajolet, P., Steyaert, JM. A complexity calculus for recursive tree algorithms. Math. Systems Theory 19, 301–331 (1986). https://doi.org/10.1007/BF01704918
Revised:
Issue Date:
DOI: https://doi.org/10.1007/BF01704918