A category specifies objects of a category, categorical morphisms between them, and composition in a category. An arrow can be followed by , giving . Every object has an identity morphism , and the rules satisfyAssociativity means that grouping a chain differently does not change its composite. It does not assert commutativity, and the sources and targets must match before a composite is defined.
In the Category of sets, arrows are functions. Take two functions on the real numbers, and . Then , whereas . At , the two orders give 8 and 7, respectively. Both orders are defined here because these maps share their source and target; for arbitrary arrows the reverse composite need not exist.
Function composition remembers order, while a naturality square gives equal results along both routes
. Details. A partially ordered set supplies a different example: its elements are the objects of a category, with exactly one arrow when , and none otherwise. Transitivity gives composition in a category, and reflexivity gives identity morphisms. For subsets ordered by inclusion, the two chains and have the same composite arrow. Thus arrows need not be maps of elements: they can record a relation.
New to topics? Read the docs here!
