# Morphisms A morphism (a.k.a. a [[Category]] arrow) **is a way of mapping one mathematical structure to another one of the same type, in such a way that certain properties of the type are preserved**. The properties in question are defined by the [[Category]]. ![[Category Theory - Wikipedia#^qp7cz1]] Morphisms **can be composed, and this composition must form a [[Monoid]] whose [[Identity]] is called the identity morphism**. This implies that **for every object in a [[Category]], there must exist an arrow that links the object to itself (the identity morphism).** **If the composition [[Monoid]] is actually a group (i.e. it is [[Invertibility|invertible]]), the morphism is known as an *isomorphism*.** This means that for every morphism f:$x \rightarrow y$, there exists a morphism g:$y \rightarrow x$ such that $g \circ f = I_x$ where $I_x$ is the identity morphism that maps object x to itself. When talking about sets (in the category of sets), this means that the two sets must be of the same size. For example, in the category of monoids, a mapping is a morphism if it preserves the existence of a monoid operation and maps the input monoid's identity element to the output monoid's identity element. $M:(A, \star) \rightarrow (B, \cdot)$ Mapping M is an $A \rightarrow B$ morphism if: $M(x \star y) = M(x) \cdot M(y)$ for all (x, y) in A, and $M(I_A) = I_B$ where $I_A$ and $I_B$ are the identity elements of monoids A and B. ## Examples from algebra **In the category of monoids, $x \rightarrow 2^x$ is a monoid morphism that maps the $(\mathbb{N}, +, 0)$ monoid to the $(\mathbb{N}, \times, 1)$ monoid.** **In the category of sets, any [[Function (in Algebra)]] is a set morphism that maps the domain set to the codomain set.**