A Brief Introduction to Categories, Part 5: Universal Properties and Representable Functors

This post is part of a series on category theory. See Overview of Blog Posts for all posts.


Many objects or contstructions can be characterized by a so-called universal property that describes either the morphisms to them or the morphisms from them. By the virtue of the Yoneda lemma, we can forget about any concrete representation of the object and can only work with its universal property. One can think of a universal property as a “universal” solution to a problem in the sense that it is uniquely related to all other solutions. For example, consider the problem of finding a commutative ring R and two elements a,b \in R such that a^2=b^3. The universal solution to this problem is given by the elements x and y in \mathbb{Z}[x,y]/(x^2-y^3); this solution is universal in the sense that for every other commutative ring R and elements a,b \in R such that a^2=b^3, there’s a unique ring homomorphism f: \mathbb{Z}[x,y]/(x^2-y^3) \to R such that f(x)=a and f(y)=b. The general definition is a straightforward abstraction from this example. Universal properties are closely related to representable functors and this relation is established by the Yoneda lemma. Understanding objects in terms of universal properties is the epitome of categorial thinking.

Representability and Universal Elements

Throughout this section, let \mathcal C be a locally small category and let F:\mathcal C \to \mathbf{Set} be a functor.

Definition C5.1 F is called representable if there is natural isomorphism \alpha:\mathrm{Hom}_{\mathcal C}(A,-) \to F for some object A \in \mathcal C. We say that F is represented by A and call A a representing object. The pair (A,\alpha) is called a representation of F.

Definition C5.2 For an object A \in \mathcal C, we say that an element u \in F(A) is universal if the following property holds: For any object B \in \mathcal C and v \in F(B), there’s a unique morphism f:A \to B with v=F(f)(u). In this case, this property is called the universal property of (A,u).

Lemma C5.3 For an object A \in \mathcal C, the representations \alpha: \mathrm{Hom}_{\mathcal C}(A,-) \to F are in bijection to universal elements of the form (A,u) via \alpha \mapsto \alpha_A(\mathrm{id}_A)

Proof Via the Yoneda lemma, we know that natural transformations \alpha:\mathrm{Hom}_{\mathcal C}(A,-) \to F correspond to elements in F(A) via \alpha \mapsto \alpha_A(\mathrm{id}_A). We need to check that \alpha is an isomorphism if and only if \alpha_A(\mathrm{id}_A) \in F(A) is an universal element. For every object B, we have \alpha_B:\mathrm{Hom}_{\mathcal C}(A,B) \xrightarrow{\sim} F(B), but by naturality of \alpha, we have for any morphism f: A \to B, \alpha_B(f)=\alpha_B(f \circ \mathrm{id}_A)=F(f)(\alpha_A(\mathrm{id}_A)) (cf. the proof of the Yoneda lemma). Thus \alpha is a natural isomorphism if and only if for every object B, the map \mathrm{Hom}_{\mathcal C}(A,B) \to F(B), f \mapsto F(f)(\alpha_A(\mathrm{id}_A)) is a bijection, which is just a restatement of saying that \alpha_A(\mathrm{id}_A) \in F(A) is a universal element.

Example C5.4 Let A be a commutative ring and consider the forgetful functor V from the category of commutative A-algebras A\textrm{-}\mathbf{CAlg} to the category of sets \mathbf{Set}, that sends an A-algebra to its underlying set. Then V is the represented by the polynomial ring A[x]. Concretely, we have a natural isomorphism \alpha:\mathrm{Hom}_{A\textrm{-}\mathbf{CAlg}}(A[x],B) \to V(B), f \mapsto f(x). x \in V(A[x]) is the corresponding universal element. This holds, because any A-algebra homomorphism f:A[x] \to B is given by evaluation at a uniquely determined element, namely f(x).

Example C5.5 Let G be a group with a presentation G=\langle S \mid R \rangle with S being the set of generators and R the set of relations. Then for if we have for a group H for every generator s \in S an element h_s \in H such that the relations in R are satisfied by those corresponding elements, this uniquely determines a group homomorphism G \to H. Consequently, for the functor F sending a group H to the families of elements in H indexed by S such that the corresponding relations are satisfied, we see that the family (s)_{s \in S} in F(G) is an universal element and F is represented by G.

Example C5.6 Let R be a ring and r \in R, then consider the functor R\textrm{-}\mathbf{Mod} \to \mathbf{Set}, i.e. from the category of left R-modules with R-linear maps to the category of sets that sends a module M to the set M[a]:= \{m \in M \mid am=0\}. Then this functor is represented by R/Ra and \overline{1} \in R/Ra is a universal element.

Example C5.7 Let \mathrm{Mor}:\mathbf{Cat} \to \mathbf{Set} be the functor from the category of small categories to the category of sets that sends a small category \mathcal C  to the set of all morphisms in \mathcal C. Then \mathrm{Mor} is represented by the arrow category from definition C3.6. The unique morphism \iota:0 \to 1 in the arrow category is a universal element.

Example C5.8 Let \mathcal C be a small category, let A \in \mathcal C be an object and consider the functor from the functor category [\mathcal{C},\mathbf{Set}] to \mathbf{Set} sending a functor F to F(A) and a natural transformation \eta: F \Rightarrow G to \eta_A:F(A) \to G(A). Then the Yoneda lemma in this context can be stated by saying that this functor is representable by \mathrm{Hom}_{\mathcal C}(A,-) and the identity \mathrm{id}_A \in \mathrm{Hom}_{\mathcal C}(A,A) is a universal element.

Example C5.9 Let G be a group, not necessarily abelian. Then consider the functor from the category of all abelian groups to the category of sets \mathbf{Ab} \to \mathbf{Set} given by taking all group homomorphism to an abelian group: A \to \mathrm{Hom}_{\mathbf{Grp}}(G,A) (this is a hom-functor from a larger category restricted to a subcategory). Then this functor is representable by the abelianization G^{ab}=G/[G,G] with the quotient map G \to G^{ab} as a universal element in \mathrm{Hom}_{\mathbf{Grp}}(G,G^{ab}): This is the universal property of the abelianization: Every map from G to an abelian group factorizes over the quotient map G \to G^{ab}.

Example C5.10 To give an example of a contravariant representable functor, consider the functor \mathrm{Ouv}:\mathbf{Top}^{op} \to \mathbf{Set} from the opposite category of topological spaces to the category of sets that sends a topological space to the set consisting of all of its open subsets. A continuous map f:X \to Y is sent to the map \mathrm{Ouv}(Y) \to \mathrm{Ouv}(X), U \mapsto f^{-1}(U). This functor is represented by the Sierpinski space S whose points are \{0,1\} with the topology that has as open sets \{\varnothing,\{1\},\{0,1\}\}. (For all algebraic geometers: this arises as the spectrum of a discrete valuation ring.) The open subset \{1\} \in \mathrm{Ouv}(S) is a universal element. This reason this holds is that for any map f:X \to S, we always have f^{-1}(\varnothing)=\varnothing and f^{-1}(S)=X, so the only interesting part of being continuous is requiring that f^{-1}(\{1\}) is open. Since S has only two points, knowing f^{-1}(\{1\}) completely determines f. Putting these things together, we get that the map \mathrm{Hom}_{\mathbf{Top}}(X,S) \to \mathrm{Ouv}(X), f \mapsto f^{-1}(\{1\}) is a bijection, proving the claim.

Example C5.11 Not every functor is representable. As a boring example, one can take the constant functor \mathcal C \to \mathbf{Set} that sends every object to the empty set. (Exercise: why will this never be representable, provided that \mathcal C is non-empty?) For a more interesting example, consider the functor from the category of all groups to the category of sets that sends a group to the set of all of its torsion elements, i.e. elements of finite order. [\mathrm{tors}]: \mathbf{Grp} \to \mathbf{Set},G \mapsto G[\mathrm{tors}]. (This defines a functor because group homomorphisms send torsion elements to torsion elements.) Suppose that [\mathrm{tors}] is represented by a group G and let g \in G[\mathrm{tors}] be a universal element. Then for every n \in \mathbb{N}, we have an element \overline{1} \in \mathbb{Z}/n\mathbb{Z}[\mathrm{tors}]. By universality of g, there is a group homomorphism G \to \mathbb{Z}/n\mathbb{Z} that sends g to \overline{1} \in \mathbb{Z}/n\mathbb{Z}. But this implies that n divides the order of g. As n was arbitrary, this is impossible, as the order of g is finite.

Universal Elements as Initial Objects

One can ask for a characterization for representability of a functor that doesn’t refer to a representing A. In this section, we shall introduce the notion of an initial object to obtain such a criterion, although the criterion will be a mere reformulation of the definition. This reformulation will be put to use in the future to prove a more useful criterion, for which we lack the tools at the moment. We shall return to the notion of initial objects later when we generalize them vastly to colimits.

Definition C5.12 Let \{*\} be a one-point set. An object x in a category \mathcal C is called initial if it represents the constant functor \mathcal C \to \mathbf{Set}, given by sending each object in \mathcal C to \{*\} and every morphism to \mathrm{id}_{\{*\}}.

Unfolding the definition, this means that for an object x is initial if for any object y, there is exactly one morphism x \to y.

We prove an elementary, but useful property of initial objects:

Lemma C5.13 If a category \mathcal C has an initial object, it is unique up to unique isomorphism.

Proof Let x and y be initial objects in \mathcal C, then there are unique morphisms f:x \to y and g:y \to x. Then both \mathrm{id}_x and g \circ f are morphisms x \to x, so they must agree, thus g \circ f=\mathrm{id}_x. By symmetry, f \circ g = \mathrm{id}_y proving that f and g are mutually inverse isomorphisms. f:x \to y is necessarily unique as x is initial.

Definition C5.14 Let F:\mathcal C \to \mathbf{Set} be a functor where \mathcal C is a locally small category. Define the category of elements \int F as follows:

  • Objects are pairs (A,a) consisting of an element A \in \mathcal C and an element a \in F(A).
  • Morphisms (A,a) \to (B,b) are morphisms f:A \to B in \mathcal C such that that F(f)(a)=b.

Lemma C5.15 (A,a) satisfies the universal property for F if and only if (A,a) is an initial object in \int F.

Proof Immediate from the definitions.

Corollary C5.16  Object characterized by a universal property are unique up to unique isomorphism in the following sense: if (X,u) and (Y,v) both satisfy the universal property for a functor F, then there exists a unique isomorphism f:X \to Y such that F(f)(u)=v.

Proof By lemma C5.15, both (X,u) and (Y,v) are initial objects in \int F. Now apply lemma C5.13.


This concludes this post on representability and universal properties. Next time, we will see an important class of examples for those concepts, given by (co)limits.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s