functional-programming-jargon icon indicating copy to clipboard operation
functional-programming-jargon copied to clipboard

Natural transformations

Open MostAwesomeDude opened this issue 3 years ago • 1 comments

The goal of category theory is to define natural transformations; categories were originally an auxiliary concept. If categories and functors are covered, then natural transformations should be covered too.

MostAwesomeDude avatar Jul 04 '22 14:07 MostAwesomeDude

As a strawman suggestion which I hope people can improve, I might start with something like...

A natural transformation is a mapping from one functor to another. They are "natural" because the transformation does not care which type is inside the functor. For example, there is a natural transformation from binary trees to lists; if we take a binary tree and traverse it, then we can build a list of its leaves, and we can do this for any type of leaf. We can turn a binary tree of integers into a list of integers, or a binary tree of strings into a list of strings.

See also #217.

MostAwesomeDude avatar Jul 11 '22 17:07 MostAwesomeDude