Fantastic Morphisms and Where to Find Them: A Guide to Recursion Schemes [article]

Zhixuan Yang, Nicolas Wu
2022 arXiv   pre-print
Structured recursion schemes have been widely used in constructing, optimising, and reasoning about programs over inductive and coinductive datatypes. Their plain forms, catamorphisms and anamorphisms, are restricted in expressiveness. Thus many generalisations have been proposed, which further lead to several unifying frameworks of structured recursion schemes. However, the existing work on unifying frameworks typically focuses on the categorical foundation, and thus is perhaps inaccessible to
more » ... practitioners who are willing to apply recursion schemes in practice but are not versed in category theory. To fill this gap, this expository paper introduces structured recursion schemes from a practical point of view: a variety of recursion schemes are motivated and explained in contexts of concrete programming examples. The categorical duals of these recursion schemes are also explained.
arXiv:2202.13633v3 fatcat:nt7pccuktrdarpy236nuuiifba