Recursion Patterns and Time-analysis

Citation:
Barbosa MB, Cunha A, Pinto JS.  2005.  Recursion Patterns and Time-analysis. SIGPLAN Notices. 40(5):45–54.

Abstract:

This paper explores some ideas concerning the time-analysis of functional programs defined by instantiating typical recursion patterns such as folds, unfolds, and hylomorphisms. The concepts in this paper are illustrated through a rich set of examples in the Haskell programming language. We concentrate on unfolds and folds (also known as anamorphisms and catamorphisms respectively) of recursively defined types, as well as the more general hylomorphism pattern. For the latter, we use as case-studies two famous sorting algorithms, mergesort and quicksort. Even though time analysis is not compositional, we argue that splitting functions to expose the explicit construction of the recursion tree and its later consumption helps with this analysis.

Citation Key:

BarbosaCunhaPinto:05a

DOI:

10.1145/1071221.1071226

PreviewAttachmentSize
recpta.pdf269.34 KB