Overview
A natural transformation is a map between functors. Its components compare the outputs for individual objects, but those comparisons must also respect every map between the inputs. Naturality converts an informal assertion such as “this construction is compatible with change of input” into a testable equation.
Prerequisites
Understand covariant functors and composition of arrows. The two functors must have a common source and a common target. A family of maps between their values has the right shape to be a transformation, but shape alone does not guarantee naturality.
Definition and conventions
For , a natural transformation consists of arrows for every object such that, for every ,
The subscript names a component. The double arrow records a transformation between functors rather than a morphism between objects of . If every component is invertible, is a natural isomorphism. Componentwise invertibility without the naturality equation is insufficient.
Intuition
There are two routes from to . One first compares the constructions at and then transports along ; the other first transports inside and then compares at . Naturality says the routes agree, so the comparison does not depend on which route a calculation takes.
Examples and non-examples
On sets, let and let be the identity functor. First-coordinate projections form a natural transformation. Indeed, for any , both and send to .
For a non-example, use the category whose objects are sets of size two and whose morphisms are all functions between them. Choose one distinguished element in each object and define to be the constant map with that value. This is a family of endomorphisms of the identity functor. At a two-element set , the swap map gives constant at but constant at . The maps differ, so the family is not natural.
Important properties
Natural transformations compose vertically by composing components. If and , then . Substituting the two naturality equations proves naturality of the composite.
If is natural and its components invertible, rearranging gives . Thus the inverse components are automatically natural. This is the proof that a componentwise isomorphism is an isomorphism in the functor category.
Connections and further reading
Natural transformations are morphisms in functor categories and supply the unit and counit of adjunctions. Yoneda shows that some transformations are determined by just one element at one object. Read Riehl, §1.4, Definition 1.4.1 and Li, the natural-transformation definition in “函子与自然变换”.