# Universal Properties III: Bringing it all together

So last time I mentioned that we could describe the kernel of a group homomorphism via a universal property.  For example, let $\varphi: G \to H$ be a group homomorphism, and let D be the full subcategory of Grp consisting of all groups $K$ such that for any group homomorphism $f: K \to G$ we have $\varphi \circ f = 0_H$ is the zero homomorphism from $K$ to $H$.  Good.  Now if A is the category with one element, and $S : \textbf{A} \to \textbf{Grp}$ is a functor with $S(*) = G$, $U: \textbf{D} \to \textbf{Grp}$ the inclusion functor,  then the terminal object in the comma category $(U \downarrow G)$ is the kernel of $\varphi$!  Simple.

If you can understand all that, then it shouldn’t be too hard to see that the cokernel has a similar description.  Cokernels are a bit more annoying to deal with when we’re just talking about ordinary groups (the image of a homomorphism is not necessarily a normal subgroup of the target group).  Let’s then just restrict our attention to Ab, where things are much nicer.   Ordinarily, we would define the cokernel of a homomorphism $\varphi: G \to H$ as the quotient group $H/ Im(\varphi)$.    As before, let D be the full subcategory of Ab such that for any group $C$ in D, we have that for any homomorphism $f: H \to C$, the composition $f \circ \varphi = 0_C$, the homomorphism that sends everything in $G$ to $0$ in $C$.  Let $U : \textbf{D} \to \textbf{Ab}$ be the inclusion functor, and $S: \textbf{A} \to \textbf{Ab}$ the functor from the category with one element with value $S(*) = H$.  Then the cokernel is the initial object in the comma category $(H \downarrow U)$.

If we’re in a “nice” category, like the category Ab of abelian groups.  Then the image of a group homomorphism $\varphi: G \to H$ has a particularly cool “set free” definition.  Recall that when we defined the cokernel of a homomorphism, the object is actually a pair $(C,f)$, where $f: H \to C$ is a homomorphism and $C$ is the object that we normally think of as a cokernel.  Since $f$ is a group homomorphism, we can ask “what is the kernel of $f$?”  It’s the image of $f$! You should check this for yourself, but its pretty mechanical if you know the definition of what the cokernel is and have been following along.  This property is often expressed as “The image is the kernel of the cokernel of $\varphi$.”

Of course, there is a much more “involved” definition of the image of a morphism for when we don’t have things like kernels or cokernels to play with.  I don’t really like it as much, but it follows the same basic idea of being an initial object in a certain comma category.

If we’re back in Ab, and have the same group homomorphism $\varphi: G \to H$, what would the “cokernel of the kernel” be?  What would it mean for the “cokernel of the  kernel” and the “kernel of the cokernel” of $\varphi$ to be isomorphic, and how does this relate to the first isomorphism theorem for groups?