[Haskell-cafe] When is a composition of catamorphisms a catamorphism?
sebastien at chaoticresearch.com
Fri Aug 24 09:44:49 CEST 2012
More specifically (assuming I understood the statement correctly):
Suppose I have two base functors F1 and F2 and folds for each: fold1 :: (F1
a -> a) -> (μF1 -> a) and fold2 :: (F2 a -> a) -> (μF2 -> a).
Now suppose I have two algebras f :: F1 μF2 -> μF2 and g :: F2 A -> A.
When is the composition (fold2 g) . (fold1 f) :: μF1 -> A a catamorphism?
On Thu, Aug 23, 2012 at 10:11 PM, Sebastien Zany <
sebastien at chaoticresearch.com> wrote:
> From page 3 of
> it is not true in general that catamorphisms are closed under composition
> When is this true?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haskell-Cafe