0% found this document useful (0 votes)
237 views96 pages

Introduction to Category Theory

This document provides an introduction to category theory, covering basic notions like categories and functors, functor categories, limits and colimits, adjunctions, monads, and abelian categories. It includes definitions of key concepts and examples to illustrate them, as well as exercises for readers to reinforce their understanding.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
237 views96 pages

Introduction to Category Theory

This document provides an introduction to category theory, covering basic notions like categories and functors, functor categories, limits and colimits, adjunctions, monads, and abelian categories. It includes definitions of key concepts and examples to illustrate them, as well as exercises for readers to reinforce their understanding.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Category theory

Jakob Scholbach

January 27, 2022


2
Contents

0 Preface 5

1 Introduction 7

2 Basic notions 9
2.1 Categories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
2.2 Functors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.3 Sameness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.4 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

3 Functor categories 21
3.1 The Yoneda embedding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3.2 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24

4 Limits and colimits 25


4.1 Initial and terminal objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
4.2 Diagrams and cones . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
4.3 Limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4.4 Colimits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
4.5 Functoriality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
4.6 Preservation of limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
4.7 Basic existence results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
4.8 Filtered colimits and compact objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
4.9 Commuting (co)limits with (co)limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
4.10 Final functors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
4.11 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

5 Adjunctions 49
5.1 Definitions and examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
5.2 Limits and adjoints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
5.3 The triangle identities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
5.4 Constructing adjoint functors via the solution set condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
5.5 The adjoint functor theorem for presentable categories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
5.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60

6 Monads 65
6.1 Definitions and examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
6.2 Algebras over a monad . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
6.3 Monadic adjunctions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
6.4 Monadicity theorems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
6.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77

7 Abelian categories 79
7.1 Definitions and examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79
7.2 Elementary properties of abelian categories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
7.3 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83

3
4 CONTENTS

8 Kan extensions 85
8.1 (Co)ends . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
8.2 Kan extensions via (co)ends . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
8.3 The free cocompletion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
8.4 The Ind-completion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
8.5 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94

References 94
Chapter 0

Preface

These are growing notes for a lecture on category theory offered in Fall 2021 at the University of Münster.
While category theory has practically no strict prerequisites, it is hard to appreciate category theory
without some applications in other areas of mathematics. We will therefore include examples from algebra,
topology, functional analysis and logic. Some very basic knowledge of some of these areas is therefore
helpful.
ˆ The exclamation mark (!) indicates that you should repeat some aspects of a definition etc. in order
to make sure you are following the lecture.
ˆ Three dots indicate some content that is not written in the notes, but will be explained in the lecture.
ˆ These are links to video recordings of the lecture. 04.11.

5
6 CHAPTER 0. PREFACE
Chapter 1

Introduction

Category theory offers a high-level abstraction for mathematical reasoning. It is comparable to the step of
studying general linear equations
ax by  c
instead of studying these one-by-one for specific choices of coefficients a, b and c. The process of abstracting
the solution process for such an equation from the concrete choice of coefficients helps in understanding the
essential points. A next step of abstraction is the concept of a vector space, which realizes the insight that
the choice of a coordinate system does, for many purposes, not matter. Linear algebra is the mathematical
theory that studies the totality of all vector spaces, and how they interact with each other. Category
theory, in turn, studies all mathematical theories at a time. It seeks to identify what is common in different
theories. For example, the concept of finiteness is a recurrent theme in algebra and topology. Finitely
generated algebras, finitely generated or presented modules are pervasive in algebra, while compactness is
an important condition in topology. Category theory offers a way to jointly address both conditions. While
it is unsurprising that both are “in some way” a finiteness condition, it is not a priori obvious how to make
sense of that notion since it requires to avoid talking about a set of generators of some algebra, or a finite
subcovering of a given open covering. Category theory also clarifies how the relation between compact
Hausdorff spaces and sets is similar to the relation between, say, Zrts-modules and abelian groups. Again,
it does (and has to do) this by offering a framework to express the common features of both situation
without specifically talking about topology, nor modules. This way, it helps clarify our thinking about
these notions within one theory, and also helps to establish crucial bonds between different branches of
mathematics.
Category theory, as exposed in this lecture, is only the penultimate step in this ladder of abstraction: 8-
categories and their theory, now central in branches such as contemporary algebraic topology or algebraic
geometry, are not touched upon in this course. However, the concepts learned in this course carry over,
often without any change in the statement, to 8-category theory. In this sense, this course can serve as a
preparation to go that one step further ...

7
8 CHAPTER 1. INTRODUCTION
Chapter 2

Basic notions

2.1 Categories
Category theory seeks to identify, clarify and exploit recurring patterns that occur throughout different
branches of mathematics. This chapter provides the basic language needed to identify the common sources
of such distant phenomena. A category is, roughly speaking, the arena in which you can perform some
mathematical discipline.
Definition 2.1. A category is the datum consisting of a
ˆ class ObjpC q called the objects of the category,

ˆ for each pair X, Y P ObjpC q, a set HomC pX, Y q called the set of morphisms (from X to Y ),
ˆ for each X P ObjpC q a distinguished element idX P HomC pX, X q called the identity morphism,

ˆ for each triple X, Y, Z P ObjpC q, a map called composition

HomC pX, Y q  HomC pY, Z q Ñ HomC pX, Z q, pf, g q ÞÑ g  f,

such that the following conditions hold:


ˆ for all f P HomC pX, Y q, idY  f  f , f  idX  f ,
ˆ composition is associative, i.e., for any objects X, Y, Z, W , f P HomC pX, Y q, g P HomC pY, Z q, h P
HomC pZ, W q we have
h  pg  f q  p h  g q  f
.

Remark 2.2. We will also write HompX, Y q : HomC pX, Y q. Another common notation is C pX, Y q. We
also use EndpX q : EndC pX q : HomC pX, X q. Morphisms f P HomC pX, Y q are also denoted as X Ñ Y .
f

Example 2.3. We have the following examples of categories. The assertion that the indicated objects
morphisms form a category requires, in each case, an argument: saying that Top forms a category contains,
in particular, the fact that the composite of two continuous maps is again continuous.
objects morphisms HompX, Y q
Set all sets all maps from X to Y
Grp all groups all group homomorphisms from X to Y
Top all topological spaces all continuous maps from X to Y
Ban all Banach spaces (over C, say) all continuous C-linear maps
CRing all commutative rings all ring homomorphisms

9
10 CHAPTER 2. BASIC NOTIONS

Definition 2.4. A category D is called a subcategory if ObjpDq € ObjpC q and if for any X, Y P D,
HomD pX, Y q is a subset of of HomC pX, Y q that contains idX for all X P D and is stable under the
composition.
It is called a full subcategory, if HomD pX, Y q  HomC pX, Y q. We will write
D €C
to indicate that D is a full subcategory.
The formation of full subcategories is very common; it amounts to selecting an arbitrary subclass of
objects, while keeping the morphisms between them.
Example 2.5. By definition, we have the following (full) subcategories:
ˆ Ab € Grp is the category of abelian groups and all group homomorphisms, i.e., by definition a full
subcategory of Grp
ˆ Grp is a full subcategory of Mon, the category of monoids and monoid homomorphisms,
ˆ Ban¤1 is the category of all Banach spaces with contracting maps, i.e.,
HomBan¤1 pV, W q : tf P HomBanpV, W q, |f | ¤ 1u
(i.e., |f pv q| ¤ |v | for all v P V ). Note this indeed is a category, and it is a (non-full) subcategory of
Ban. We will see later (e.g., in Exercise 4.9) that the two categories Ban and Ban¤1 , while having the
same objects, are profoundly different. This highlights the importance of the morphisms. However,
in many situations the choice of morphisms (and more so, for identity morphisms and composites) is
left implicit.
ˆ Haus € Top is the category of Hausdorff spaces, again by definition a full subcategory.
Definition 2.6. A category is called small if ObjpC q is a set (as opposed to a class).
Example 2.7. The above examples are not small, e.g., since all sets form a proper class. Small categories
can be constructed by imposing some size condition. For example, fixing a set X, the subsets of X (and
all maps between them) forms a small category.
Remark 2.8. In order to emphasize that the morphisms between two fixed objects form a set some authors
also refer to a category as defined above as a locally small category. It is possible to drop this condition
as well, so allowing HomC pX, Y q to be a class. Such categories are then referred to as big categories.
A set-theoretically clean method of incorporating these different cases is by working with universes, in
which case one would choose two universes U € V . A small U -category C would then be such that ObjpC q P
U and all HomC pX, Y q P U . A locally small U -V -category C has ObjpC q P V and all HomC pX, Y q P U .
In this language, a big category would be just a small category with respect to the larger universe V .
As long as category theory is only used as a device to organize one’s thinking, such set-theoretic issues
can largely be ignored. The distinction between sets and classes of objects will, however, matter strongly
in the adjoint functor theorem.
Example 2.9. Any preordered set 1 pA, ¤q gives rise to a small category whose objects are the elements
of A, and where Hompa, bq  tu if a ¤ b and Hompa, bq  H otherwise. Conversely, any small category C
in which HomC pX, Y q has at most one element gives rise to a preordered set.
Definition 2.10. If C is a category, then the opposite category C op is the category whose objects are
ObjpC op q : ObjpC q, but for X, Y P ObjpC op q (i.e., X, Y P ObjpC q)
HomC op pX, Y q : HomC pY, X q.
The identity morphisms and composition are inherited from C.
1 Recall that a preordered set is defined by the following axioms: a ¤ a for all a P A; a ¤ b and b ¤ c imply a ¤ c.
2.2. FUNCTORS 11

This is a “stupid” definition in the sense that it just reverses the way we think of morphisms, and has
otherwise no deeper content: it can be performed for any category C. Given a category, a meaningful
description for C op is often the starting point for interesting insights. E.g., parts of linear algebra can
be viewed as a consequence of an equivalence of categories (see Definition 2.31) between the category of
finite-dimensional vector spaces and its opposite category

pVectfdk qop  Vectfdk , V ÞÑ V  : HompV, kq.


The Hahn-Banach theorem in functional analysis is a (small) piece of a description of Banop (Example 2.40).

2.2 Functors
The same way as differentiable maps are what makes differentiable manifolds talk to one another, or the
same way as Q-linear maps are what is needed to connect different Q-vector spaces, category theory
becomes useful mostly by connecting different categories. This is what functors do: they connect different
categories and thus are the notion to use in order to connect different areas of mathematics.
Definition 2.11. Let C, D be two categories. A functor from C to D, commonly denoted as F : C ÑD
is the following datum:
ˆ a map (of classes), F : ObjpC q Ñ ObjpDq,

ˆ for each pair of objects X, Y P ObjpC q, a map (of sets)


F : HomC pX, Y q Ñ HomD pF pX q, F pY qq.

To be a functor, the following conditions have to be satisfied:


ˆ F pidX q  idF pX q for each X P ObjpC q,
ˆ F pg  f q  F pg q  F pf q for each f P HomC pX, Y q, g P HomD pY, Z q.

Some authors call this a covariant functor and use the term contravariant functor for a map on the objects
as above, and maps
HomC pX, Y q Ñ HomD pF pY q, F pX q
subject to similar conditions as above. In the notation of Definition 2.10, a contravariant functor is just a
functor C op Ñ D.

Example 2.12. Consider the category C whose objects are Rn for n ¥ 0, and such that

HomC pRn , Rm q  tf : Rn Ñ Rm differentiable, f p0q  0u


with the obvious composition, using that composites of differentiable functions are again differentiable.
There is a tangent space functor

T :C Ñ VectR, Rn ÞÑ Rn, f ÞÑ T0f,


where T0 f (also sometimes denoted as D0 f ) is the total derivative. The functoriality of this just says

T0 pg  f q  T0 g  T0 f,

which is commonly known as the chain rule.


This example can be extended further by allowing not just Rn as objects, but arbitrary differentiable
manifolds, and by considering the tangent bundle, so that the condition f p0q  0 can be dropped.
12 CHAPTER 2. BASIC NOTIONS

Example 2.13. An important achievement in algebraic topology is the construction of a functor


π1 : Top Ñ Grp
between the category of pointed topological spaces (and continuous maps preserving the base point) and
the category of groups (and group homomorphisms). While detailing the construction of this functor is
beyond the scope of these notes, let us at least indicate what this functor buys us:
ˆ One computes, say, π1 pS 1  S 1 , q  Z  Z (the fundamental group of a torus), while
ˆ π1 pS 2 , q  0. (The hard work to be done by algebraic topologists lies in these computations.)
ˆ By Lemma 2.20 below, since Z  Z is not isomorphic to the trivial group 0, this implies that the torus
S 1  S 1 is not homeomorphic (i.e., isomorphic in Top) to the 2-sphere S 2 .
Example 2.14. Given any category C, and any object X P C, there are functors(!)
hX : C op Ñ Set, Y ÞÑ HomC pY, X q.
hX : C Ñ Set, Y ÞÑ HomC pX, Y q.
The importance of these two functors cannot be overstated; we will study their relevance more deeply
around the Yoneda lemma (§3.1) The former functor is called the representing functor attached to the
object X, the latter the corepresenting functor attached to X. The two together can be combined to a
functor
C op  C Ñ Set, pX, Y q ÞÑ HomC pX, Y q.
Here the product of two categories C and D is defined by ObjpC  Dq  ObjpC q  ObjpDq and
HomC D ppX, Y q, pX 1 , Y 1 qq  HomC pX, X 1 q  HomD pY, Y 1 q
with the obvious identity and composition law.
Definition 2.15. A functor F : C Ñ D is faithful , if all the maps (for X, Y P ObjpC q)
F : HomC pX, Y q Ñ HomD pF pX q, F pY qq
are injective. It is called fully faithful , if all these maps are bijective.
The above examples of categories may create the impression that a category is just some collection of
sets, with certain restraints on the morphisms allowed. In the language of the definition, this amounts to
having a (not necessarily fully) faithful functor
C Ñ Set.
A category C is called concretizable if there is such a functor. Many, but not all categories are of that kind.
The category HoTop of topological spaces up to homotopy is, by a non-trivial theorem of Freyd [Fre70],
not concretizable. Even if a category is concretizable, the choice of such a functor U is not necessarily
unique or natural: e.g., the two functors
U : Ban¤1 Ñ Set, V ÞÑ V,
B1 : Ban¤1 Ñ Set, V ÞÑ B1pV q : tv P V, |v| ¤ 1u
turn Ban¤1 into a concretizable category in two different ways. Thus, the role of an underlying set for
objects in many categories usually takes the back seat in category theory.
A trivial observation is this:
Lemma 2.16. If F : C Ñ D and G : D Ñ E are two functors between categories C, D and E, the
composite
GF :C ÑE
(defined on objects and morphisms in the obvious way) is again a functor.
2.3. SAMENESS 13

2.3 Sameness
Definition 2.17. A morphism f : X Ñ Y in a category C is called an isomorphism if there is another
morphism g : Y Ñ X (going in the other direction!, called an inverse) such that

f  g  idY , g  f  idX .
One shows(!) that such an inverse is unique if it exists. It is therefore also denoted f 1 .
Example 2.18. A map in Set is an isomorphism iff it is bijective.

Example 2.19. In the category TopGp of topological groups (with continuous group homomorphisms),
the logarithm
log : R¡0 Ñ R
is an isomorphism, since the exponential exp : R Ñ R¡0 is again a continuous group homomorphism and
the two composites are the respective identities.

Lemma 2.20. Given a functor F : C Ñ D and an isomorphism f : X Ñ Y , the morphism


F pf q : F pX q Ñ F pY q

is an isomorphism (in D).


We refer to this fact by saying that any functor preserves isomorphisms.

Proof. Indeed, F pf 1 q : F pY q Ñ F pX q satisfies

F pf 1 q  F pf q  F pf 1  f q  F pidX q  idF pX q

and similarly with the other composite. (Note this uses both conditions on being a functor.)

Conversely, though, it is not necessarily true that f is an isomorphism whenever F pf q is. Applied to
the forgetful functor
U : TopGp Ñ Set
this means that just checking log is bijective (so that U plogq is an isomorphism) is a priori not enough to
ensure that its set-theoretically existing inverse is actually continuous and a group homomorphism. See
Exercise 2.4 for further examples.
Definition 2.21. A functor F : C Ñ D is called conservative if the following holds: a morphism f in C
is an isomorphism if (and therefore iff) F pf q is an isomorphism.

For example, the forgetful functor


U : Grp Ñ Set
is conservative: if a group homomorphism f is a bijection (i.e., U pf q is an isomorphism), then the set-
theoretical inverse f 1 is automatically a group homomorphism and is an inverse in Grp. Conserva-
tive functors are quite wide-spread. We will encounter them more systematically around the Barr–Beck
monadicity theorem (§6).
Pausing briefly our discussion of sameness, we also introduce two weaker notions than isomorphism:
Definition 2.22. A morphism f : X ÑY in a category C is called a
ˆ monomorphism if for every two arrows t0 , t1 : T Ñ X with f  t0  f  t1 we have t0  t1. Equivalently,
f 
if HompT, X q Ñ HompT, Y q is injective for any T P C.
ˆ epimorphism if it is a monomorphism in the opposite category C op , or if for every two arrows t0 , t1 :
Y Ñ T such that t0  f  t1  f we have t0  t1 .
14 CHAPTER 2. BASIC NOTIONS

Clearly(!) every isomorphism is both a monomorphism and an epimorphism. The converse holds in the
category of Set, but does not hold in other categories such as CRing, see Exercise 2.8.
Working towards the notion of sameness in category theory, it is at first suggestive to consider the
following idea:
Definition 2.23. A functor F : C Ñ D is an isomorphism of categories if there is another functor
G : D Ñ C such that the two composites G  F  idC and F  G  idD are the respective identity functors,
i.e., for each object GpF pX qq  X, F pGpY qq  Y and likewise for each morphism.
Example 2.24. Let k € K be a finite Galois extension.2 Let G : GalpK {k q : tσ : K Ñ K, σ|k  idk u
be the group of field automorphisms of K that fix k elementwise.
The main theorem of Galois theory can be stated as a bijection
tk € L € K u Õ tH € Gu
between the intermediate fields and the subgroups of G. The maps are given by
L ÞÑ GalpK {Lq : tσ : K Ñ K, σ|L  idLup€ Gq
and conversely
H ÞÑ FixpH q : tx P K, σx  x @σ P H up€ K q.
That is we have identities:
L  FixpGalpK {Lqq, H
 GalpK {FixpH qq.
Looking slightly closer, one notices that to an inclusion L € L1 corresponds an inclusion (note the
direction changes) GalpK {L1 q € GalpK {Lq and conversely to H € H 1 p€ Gq corresponds pk €qFixpH 1 q €
FixpH qp€ K q.
We can therefore add this extra structure and consider the following categories
ˆ SubG : objects are the subgroups of G, with morphisms given by inclusions.
ˆ FieldsK
k : objects are subfields k € L € K and morphisms are inclusions L € L1p€ K q.
Note that these categories are (categories associated to) posets (Example 2.9), since there is at most one
morphism between any two objects. Thus, the bijection on the level of objects and the functoriality (i.e.,
preservation of inclusions) gives automatically rise to an isomorphism of categories
GalpK {q : FieldsK
k Õ Sub op
G : Fixpq.
It is possible to slightly enlarge the morphisms allowed by consider the category of transitive G-sets
(these are of the form G{H for some subgroup H) instead of SubG and on the other side allow not just
inclusions, but arbitrary field homomorphisms L Ñ L1 (whose restriction to k is the identity). In this case,
one still obtains an isomorphism of categories (which are no longer posets), see [Rie17, Example 1.3.15]
for a precise statement.
Keeping this example in mind, let us however point out that isomorphisms of categories are rare in
practice. What made it work for the example of Galois theory is that there are few (almost no in the first
case) isomorphisms. This is, however, not so in many other situations, like the following example.
Example 2.25. Let k be a field and Vectfd
k the category of finite-dimensional k-vector spaces and k-linear
maps. Consider the functors
pVectfdk qop Õ
F

G
Vectfd
k

defined on objects by F pV q  HompV, k q and GpV q  HompV, k q and on morphisms in the “obvious way”.
€
2 Recall a finite field extension k Ñ
K is called Galois if it is separable and normal. Equivalently, the number of automorphisms σ : K K
| 
with σ k idk equals dimk K. See, e.g., [Bower:Category] for a leisurely introduction to Galois theory with an eye towards its categorical
interpretation.
2.3. SAMENESS 15

As usual, the set HompV, k q is regarded as a k-vector space in its own right. (This is an example of a
so-called inner homomorphism, i.e., a case where the set of homomorphisms happens to be an object in
the category itself again.)
The composites are given by

V ÞÑ GpF pV qq  HompHompV, kq, kq.


Linear algebra tells us that, for finite-dimensional vector spaces V , the natural map

V Ñ HompHompV, kq, kq, v ÞÑ pf ÞÑ f pvqq


is an isomorphism, but the double dual is not the same vector space, so F and G do not constitute an
isomorphism of categories.

However, from linear algebra we also know that demanding that two vector spaces are the same is
actually too strong: for all purposes it is enough to ensure they are isomorphic. We want to relax the
above definition by just requiring that GpF pV qq be isomorphic to V . However, these isomorphisms should
not be chosen at will individually for each V , but should rather be in harmony with one another. In order
to express this latter idea we need to introduce another concept:

Definition 2.26. Let F, G : C Ñ D be two functors (going in the same direction). A natural transforma-
tion
α:F ñG
is the datum of a morphism αpX q : F pX q Ñ GpX q for all objects X P ObjpC q, such that for each morphism
f : X Ñ Y in C, the square
p q/
F pX q GpX q
α X

pq
F f pq
G f
 p q/ 
F pY q GpY q
α Y

commutes, i.e., αpY q  F pf q  Gpf q  αpX q.


The natural transformation α is called a natural isomorphism if the maps αpX q are isomorphisms for
all X P ObjpC q.

Example 2.27. Recall the category Ban¤1 of Banach spaces and contractive maps and the forgetful and
“ball of radius 1” functors:
U : Ban¤1 Ñ Set, V ÞÑ V,

B1 : Ban¤1 Ñ Set, V ÞÑ B1pV q : tv P V, |v| ¤ 1u


There is a natural transformation
B1 ñU
given by the inclusions B1 pV q € V (which trivially commute with any map f : V Ñ W ). Of course it is
not a natural isomorphism since the inclusions are never (except for V  0) bijections.
For each object V P Ban¤1 , we can also contemplate the map β pV q : V Ñ B1 pV q, v ÞÑ maxpv1,|v|q . This
does not give rise to a natural transformation

U ñ B1,
since for a linear contractive map f : V Ñ W , we will not in general have
β pf pv qq  f pβ pv qq.
16 CHAPTER 2. BASIC NOTIONS

Example 2.28. The contravariant power set functor


Ñ Set
P : Setop
is given on objects by A ÞÑ P pAq : tthe subsets of Au and for morphisms f : A Ñ B given by P pf q :
f 1 : V € B ÞÑ f 1 pV q € A.
Another functor is the representing functor
h2 : Homp, 2q : Setop Ñ Set, A ÞÑ HompA, 2q
where 2  t0, 1u is a two-element set. There is a natural isomorphism
Homp, 2q ñ P
given on objects by HompA, 2q Q f ÞÑ pf 1p0q € Aq P P pAq.
We introduce some language to conveniently talk about such examples: the above example then says
that the functor P is representable by 2.
Definition 2.29. A functor F : C op Ñ Set is called representable if there is a natural isomorphism
F  hX
for some object X P C. Dually, a functor F : C Ñ Set is called corepresentable if there is an isomorphism
F  hX . Such an object is called a (co)representing object.
Remark 2.30. ˆ Further elementary examples are discussed in Exercise 2.7.
ˆ Once we discuss the Yoneda lemma, we will see that given another object X 1 and an isomorphism
F  hX 1 there is an isomorphism X  X 1 (see Corollary 3.7). Moreover, if we demand the natural
compatibility condition with the given isomorphisms, such an isomorphism is unique.
ˆ The notion of representable functors arose in algebraic topology where one constructs so-called
Eilenberg-Maclane spaces H pZ, nq P Top. For example, H pZ, 1q  S 1 . One then shows that sin-
gular cohomology
Hn pX, Zq  HomHoTop pX, H pZ, nqq,
so that cohomology is a representable functor on the category of topological spaces up to homotopy.
See, e.g., [Hatcher:Algebraic].
Here comes the notion of sameness that is much more useful than the isomorphism of categories.
Definition 2.31. A pair of functors F : C Ñ D and G : D Ñ C, also pictured as
C ÕD
F

is called an equivalence of categories, if there are natural isomorphisms


idCñ G  F, idD ñ F  G.
Equivalences of categories will be denoted by . We say that F : C Ñ D is an equivalence if there is a
functor G satisfying the above conditions.
Remark 2.32. Contrast this with the notion of an isomorphism of categories, in which case we are de-
manding equalities
idC  G  F, idD  F  G.
Example 2.33. The functors in Example 2.25 constitute an equivalence of categories: the maps V Ñ
GpF pV qq and W Ñ F pGpW qq  HompHompW, k q, k q are functorial in V resp. W . Moreover, they are
isomorphisms for finite-dimensional vector spaces.
2.3. SAMENESS 17

There is a useful criterion to show that a given functor F : C Ñ D is part of an equivalence of categories.
To state it we introduce some more language:
Definition 2.34. A functor F : C Ñ D is essentially surjective if for each Y P D there is some X P C
and an isomorphism F pX q  Y .
Proposition 2.35. Let F : C Ñ D be a functor. The following are equivalent:
(1) F is part of an equivalence of categories (i.e., there is a functor G : D Ñ C such that the conditions
in Definition 2.31 are satisfied),
(2) F is fully faithful (Definition 2.15) and essentially surjective.
Proof. The direction (1) ñ (2) is left as an exercise. Conversely, assume F is essentially surjective and
fully faithful. Using the axiom of choice (for classes), we can choose for each Y P D some object, denoted
GpY q P C such that F pGpY qq  Y . To complete the definition of G, we specify it on morphisms such that
this (somewhat arbitrary choice) becomes functorial. Let f : X Ñ Y be a morphism in D. Consider the
composite
F pGpX qq  X Ñ Y  F pGpY qq.
f

Since F is fully faithful, there is exactly one morphism GpX q Ñ GpY q that is mapped to this composite
under F . Define Gpf q to be that map. In other words, the diagram

F pGpX qq
 /X

p p qq
F G f f
 
F pGpY qq
 /Y

commutes. One checks the conditions for G being a functor(!) . By the diagram above, we have a
(functorial) isomorphism F  G  idD . We conclude
F  pG  F q  pF  Gq  F  idD  F  F  idC .
One checks, using the full faithfulness of F , that this implies G  F  idC .
Example 2.36. Given a category C with a full subcategory C 1 € C such that the inclusion is essentially
surjective, then C 1  C.
Given a category C 1 , we can thus for example consider a category C with ObjpC q  ObjpC 1 q \ ObjpC 1 q
(two copies of objects of C 1 ), and
HomC pX, Y q  HomC 1 pX, Y q.
For X P C 1 , writing X1 for the object regarded in the first copy of C 1 , and X2 for the one in the second
copy, the identity idX in particular gives a morphism
ιXP HomC pX1, X2qp HomC 1 pX, X qq.
This map is an isomorphism(!) . Thus the functor C 1 Ñ C mapping X ÞÑ X1 and f ÞÑ f is fully faithful
and essentially surjective. It is therefore an equivalence of categories. In a sense, C consists of another
copy of C 1 , with just different names for the objects.
Example 2.37. Let k be a field and Matk the category whose objects are the natural numbers N 
t0, 1, . . . u and HomMatk pn, mq  knm with composition given by matrix multiplication. The obvious
functor
F : Matk Ñ Vectfd
k , n ÞÑ k
n

and on morphisms (for A P k nm ) F pAq : k n Ñ k m , x ÞÑ Ax is an equivalence of categories by the preceding


proposition. Note that defining an inverse functor requires choices k n  V for all V P Vectfd
k , i.e., the choice
of bases of all vector spaces.
18 CHAPTER 2. BASIC NOTIONS

Corollary 2.38. There is an equivalence of categories


 Vectfd , V ÞÑ V  : HompV, k q.
pVectfdk qop Ñ k

Proof. This follows from the preceding example, observing that


 Matk , npP Nq ÞÑ n, HomMat pn, mq  kmn Ñ  k nm  Hom
Matop
k
op
k
Mat pn, mq, k

where at the right we use the natural isomorphism k mn  k nm given by taking the transpose of a matrix.
(Alternatively, it is also possible to prove this using Proposition 2.35 directly.)
Definition 2.39. An equivalence of the form
C op D
is called a duality. (Some authors, however, do not use the term duality in a precise technical sense.)
Example 2.40. In functional analysis there is the notion of Smith spaces (also known as Waelbroeck
spaces).3 There is an equivalence of categories (see, e.g., [Scholze:Lectures] for a recent exposition)
Homp, Rq : Smithop  Ban : Homp, Rq.
The Hahn–Banach theorem can be read off from this equivalence: it is commonly stated by saying that
for an inclusion of Banach spaces and a map f , there is an extension g with the same norm:
f
V _ /
>R
g

W.
One checks (quickly) that inclusions of Banach spaces correspond to surjections of the corresponding
Smith spaces. In the context of Smith spaces, the corresponding statement is trivial: any map a : R Ñ A
corresponds to just an element in A and this can always be lifted along a surjection:

>B
b

R
a / A.

2.4 Exercises
Exercise 2.1. Let M be a monoid (e.g., a group). Show that M gives rise to a category, denoted BM with
a single object, denoted , and such that HomBM p, q  M with composition given by the multiplication
in the monoid M .
Unwind the definition of a functor BM Ñ Set and explain why such a functor is called a set with an
M -action (or M -set).
Exercise 2.2. A category in which every morphism is an isomorphism is called a groupoid . Explain why
that terminology has been adopted.
Let C be a groupoid and f : X Ñ Y be an (iso-)morphism. Show that f gives rise to a group
isomorphism
EndC pX q Ñ EndC pY q.
Consider the groupoid C consisting of all finite-dimensional vector-spaces (over a fixed field k), where
we only allow isomorphisms as morphisms. Let V P C and f : k n Ñ V an isomorphism. What is the
relation of the above to the representation of linear maps V Ñ V in terms of a basis?
€V
 ”c¡0 cK with the induced compactly generated topology on V .
3A Smith space is a complete locally convex topological R-vector space V that admits a compact absolutely convex subset K such that
V
2.4. EXERCISES 19

Exercise 2.3. Recall that the center of a monoid M is defined as

Z pM q  t g P M |gh  hg @h P M u.
(1) Is the assignment
Mon Ñ AbMon, G ÞÑ Z pGq
part of a functor (taking values in the category of abelian monoids and monoid homomorphisms)?
(2) Let M Set be the category of M -sets (Exercise 2.1). Construct a bijection

Z pM q  HomM M op Set pM, M q.

Exercise 2.4. Which of the following functors are faithful, which are fully faithful, which are conservative?
Functors called U are the obvious forgetful functors.
(1) U : Top Ñ Set
(2) U : CptHaus Ñ Set (compact Hausdorff spaces with continuous maps)
(3) U : ModQ Ñ ModZ . Here ModR denotes the category of R-modules, for a ring R, with morphisms
being R-linear maps. Thus ModZ  Ab is the category of abeliang groups, and ModQ is the category
of Q-vector spaces.
(4) U : Ban¤1Ñ Ban
(5) U : Ban Ñ VectC
(6)  bZ Q : ModZ Ñ ModQ .
Note: To decide (2) and (5), you need to use a fact from point-set topology, respectively functional
analysis.

Exercise 2.5. Let FinSet be the category of finite sets, where we only consider bijections as morphisms.
Define a functor Sym : FinSet Ñ Set by sending a finite set X to its set of permutations. Defne another
functor Ord : FinSet Ñ Set by sending X to the set OrdpX q of total orderings on X, and a bijection
f : X Ñ Y to the map
Ordpf q : OrdpX q Ñ OrdpY q
that sends a total order ¤X on X to the following order ¤Y on Y :
y ¤Y y 1 ô f 1 py q ¤X f 1 py 1 q.

Show that for each finite set X, SympX q  OrdpX q, but that there is no isomorphism of functors Sym 
Ord. This is expressing the fact that any finite set can be totally ordered, but not functorially (or, as one
also says, not canonically).

Exercise 2.6. Complete the proof of Proposition 2.35.

Exercise 2.7. Show that the functors (U denotes the usual forgetful functors)

U : Ring Ñ Set

U : Ab Ñ Set
B¤1 : Ban¤1 Ñ Set
Op : Topop Ñ Set, X ÞÑ OppX q : tthe set of open subsets of X u, f ÞÑ f 1
are (co)representable.
20 CHAPTER 2. BASIC NOTIONS

Exercise 2.8. Show that a morphism in CRing is a monomorphism iff it is injective. Show that a morphism
in CRing is an epimorphism if it is surjective. The converse is false: show that Z Ñ Q is an epimorphism.
Note: the description of epimorphisms in CRing is subtle. A sample theorem is the following: sup-
pose f : A Ñ B is a local homomorphism between local (commutative) rings with A Noetherian. If
f is an epimorphism then B  C rS 1 s is a localization of an A-algebra C that is finitely generated
[Ferrand:Monomorphismes]. The expectation that an epimorphism is surjective can be partly sal-
vaged: surjective ring homomorphisms A Ñ B are precisely the finite (i.e., B is a finitely generated
A-module) epimorphisms [StacksProject].
Exercise 2.9. The following exercise shows that the condition that a naturality of a transformation is a
strong condition.
Consider the functor
f
F : Set Ñ Set, X Þ X  X, pX Ñf Y q ÞÑ pX  X fÑ
Ñ Y Yq
as well as the identity functor id : Set Ñ Set.
ˆ Show that the only natural transformations F ñ id are given by the projections on the two coordi-
nates, i.e., on objects by X  X Ñ X, px0 , x1 q ÞÑ x0 or x1 .
Hint: consider first what happens for X  t0, 1u.
ˆ Give an example of an “unnatural” transformation, i.e., a collection of maps F pX q Ñ X for all sets
X, that fails to be natural.
Exercise 2.10. Show that a fully faithful functor is conservative.
Chapter 3

Functor categories

Given two categories C and D, the totality of all functors C Ñ D carries the structure of a category in its
own right.
Definition 3.1. Let F, G, H : C Ñ D be three functors, and α : F ñ G, β : G ñ H natural transforma-
tions. The composite
βα:F ñH
is defined in the expected way, for objects X, Y P C and morphisms f : X ÑY:
pq
F pX q F pY q
F f
/

p q
α X p q
α Y
 pq 
pβ αqpX q GpX q GpY q
G f
/ pβ αqpX q
p q
β X p q
β Y
  p q/  
H pX q H pY q.
H f

Note this is in contrast of the composition of functors (which would, given a functor F : C Ñ D and
another functor to another category, F 1 : D Ñ E, give a functor F 1  F : C Ñ E.) It can be useful to
illustrate compositions of natural transformations like so:
F
α "
C
G  / D.
β
=

H

For a more comprehensive approach to visualizing category theory, see e.g., [Marsden:Category].
Definition and Lemma 3.2. Let C, D be two categories. We define the functor category
FunpC, Dq
(also denoted as DC ) to have as objects the functors C Ñ D and as morphisms the natural transformations
between such functors and composition being the one in Definition 3.1).
If C is a small category and D is small, then this is again a small category. If C is a small category and
D is locally small (i.e., HomD p, q are sets), then this is again locally small. (If no smallness condition
is imposed on C, then FunpC, Dq will be a big category, cf. Remark 2.8.)
Proof. Verifying the conditions of a category is routine. About the size issues note that the morphisms
± transformations) between two given objects (i.e., functors F and G) form a set, in fact a
(i.e., natural
subset of X PC HomD pF pX q, GpX qq (which is a set since each factor is one and the product is over a set
of objects).
If, in addition D is small, then ObjpFunpC, Dqq € HomSet pObjpC q, ObjpDqq is a set, i.e., the functor
category is small.

21
22 CHAPTER 3. FUNCTOR CATEGORIES

3.1 The Yoneda embedding


Definition 3.3. Let C be a small category. A presheaf on C is a functor C op Ñ Set. The category of
presheaves is the category
Cp : PShpC q : FunpC op , Setq.
The category of copresheaves is the category

CoPShpC q : FunpC, Setq.

Example 3.4. For a topological space X, consider the category OppX q of open subsets, ordered by in-
clusion. Then a presheaf on X (in the sense of any topology textbook) is a presheaf (in the above sense)
on OppX q. Concretely, a set F pU q for each U € X open, and for each inclusion U € V , a (so-called)
restriction map F pV q Ñ F pU q that is compatible with respect to further inclusions.
Fixing a “target” topological space T , a prototypical example is the representable presheaf

U ÞÑ HomToppU, T q.
For example, for T  R, this is just the presheaf that assigns to any U the continuous, real-valued functions
on U .
Morphisms F Ñ G of presheaves are collections of maps F pU q Ñ GpU q that are compatible with the
restriction maps.
Copresheaves are similar, except that there are maps F pU q Ñ F pV q for U € V . These maps are called
corestriction maps. Copresheaves are more rare than presheaves in practice. An example is the copresheaf
of compactly supported functions:

UÞ tf : U Ñ R, supppf q is compact u,
Ñ
with the corestriction maps (for U € V ) given by extending a function by zero.

Let C be any small category, X P C and F : C op Ñ Set a presheaf on C. There is a map (of sets)

F pX q Ñ HomCp phX , F q

that sends f P F pX q to the natural transformation hX Ñ F that is given on objects Y P C op by hX pY q 


HomC pY, X q Q α ÞÑ F pαqpf q P F pY q. (Note here F pαq : F pX q Ñ F pY q since F is contravariant. Note
also that given a morphism Y Ñ Z in C op , i.e., a morphism y : Z Ñ Y in C, the diagram

hX pY q  HomC pY, X q / F pY q

y  HomC y,X
 p q F y pq
 
hX pZ q  HomC pZ, X q / F pZ q

commutes since F is a functor(!) Thus we have indeed defined an element in HomCp phX , F q.)
Conversely, there is a map (of sets)

HomCp phX , F q Ñ F pX q

that sends a natural transformation g : hX Ñ F to g pidX q P F pX q (note the evaluation of g at X gives a


map hX pX q  HomC pX, X q Q idX Ñ g pidX q P F pX qq.

Lemma 3.5. The above two maps are inverse to each other, so we have an isomorphism.

The (completely formal) proof is relegated to Exercise 3.2.


3.1. THE YONEDA EMBEDDING 23

Lemma 3.6. Let C be any small category. The functor


C Ñ Cp : PShpC q : FunpC op, Setq, X ÞÑ hX : HomC p, X q
is fully faithful. It is called the Yoneda embedding. It establishes an equivalence between C and the full
subcategory of C p spanned by the representable functors.
Dually, there is a fully faithful functor
C op Ñ CoPShpC q, X ÞÑ hX .
Proof. The full faithfulness follows directly from Lemma 3.5:
HomC pX, Y q  hY pX q  HomCp phX , hY q.
The last statement is then immediate from Proposition 2.35, since the representable functors are, by
definition, the ones in the essential image of the Yoneda embedding.
The above lemma, known as the Yoneda lemma is completely formal, yet very powerful. We will see
later on (§8.3) that the formation
C ÞÑ Cp
is, in a certain precise sense, comparable to taking the completion of a metric space. A related aspect
is that, unlike an arbitrary category C, the category Cp is large enough to do all reasonable operations,
as we will see in Lemma 4.34. This process of enlarging the category can be useful to perform certain
constructions, as is sketched in the more advanced Exercise 3.3. A more elementary example how functor
categories can be useful occurs in Exercise 3.1.
Some immediate application:
Corollary 3.7. Let C be a category and X, Y P C two objects. There is a bijection
HomC pX, Y q  HomCp phX , hY q
and under this bijection isomorphisms (of objects in C) correspond to isomorphisms (of functors). In
particular, if X  Y iff hX  hY (isomorphism of functors).
In particular, let F : C op Ñ Set be a representable functor. If X and Y P C are two representing objects
for F , they are isomorphic.
Example 3.8. Consider a polynomial in two variables, with coefficients ai,j P Z:
¸
f px, y q  ai,j xi y j P Zrx, ys.
Such a polynomial (and, exactly the same way, a polynomial in more variables, or several polynomials in
several variables) gives rise to a functor
CRing Ñ Set, R ÞÑ tpr, sq P R  R, f pr, sq  0pP Rqu.
In other words, a commutative ring gets mapped to the set of solutions of the original equation, but solutions
are now taken in R (as opposed to Z). This is indeed functorial (with respect to ring homomorphisms
φ : R Ñ S). In fact, this functor is just the corepresenting copresheaf for the ring X : Zrx, y s{f :
hX : R ÞÑ hX pRq  HomCRing pX, Rq.
The Yoneda lemma, applied to the category CRingop gives a fully faithful functor
CRingop € FunpCRing, Setq, X ÞÑ hX .
Thus, questions about the solutions of polynomial equations (or, similarly, systems of polynomial equa-
tions), which can be phrased in terms of morphisms in CRing, can be just as well studied in the larger
category at the right hand side. The additional benefit is that the right hand side contains more objects,
notably schemes. This construction is the first step in the functor of points approach to algebraic geometry.
24 CHAPTER 3. FUNCTOR CATEGORIES

3.2 Exercises
Exercise 3.1. Let Poly € CRing be the full subcategory consisting of the polynomial rings Zrt1 , . . . , tn s.
Show that the Yoneda embedding restricts to an equivalence of categories
CRing Ñ Fun1 pPolyop , Setq.
At the right, Fun1 denotes the full subcategory of FunpPolyop , Setq consisting of functors preserve finite
products (i.e., regarded as a contravariant functor coproducts in Poly are mapped to products in Set).
Exercise 3.2. Prove Lemma 3.5. Also show that the isomorphism is functorial in F and in X, in the
sense that there is an isomorphism of functors
ev : C op  C
p Ñ Set, pX, F q ÞÑ F pX q
and
C op  C
p Ñ
y op id pop  Cp
C Ñ
HomCp
Set.
Exercise 3.3. In the interplay of algebraic and analytic geometry, there is a functor
SchftC Ñ An
between the category of finite type schemes over Spec C and analytic spaces. See, for example, [Neeman:Algebrai
ˆ Describe this functor in terms of its restriction to affine schemes.
 pCRingftCqop Ñ An in terms of its restriction to PolyC.
ˆ Describe the functor AffSchft
C

Exercise 3.4. Let C be a small category and D be a category. Let F, G P FunpC, Dq. Show that a natural
isomorphism (Definition 2.26) α : F ñ G is the same thing as an isomorphism F  G in the category
FunpC, Dq.
Exercise 3.5. ˆ Let P : Setop Ñ Set be the power set functor. Describe EndSy et pP q explicitly.

ˆ Redo Exercise 2.9 (in a single line).


Exercise 3.6. Let G be a monoid. Let U : G  Set Ñ Set be the forgetful functor from the category of
G-sets. Show this functor is corepresentable. Construct a bijection
G  EndFunpGSet,Setq pU q.
This identification is a(n easy) piece of Tannaka duality. Broadly speaking it answers the question how a
monoid (or group) can be recovered from the category of representations.
Exercise 3.7. Let GLn : CRing Ñ Set be the functor which sends each commutative ring R to the set of
invertible n  n matrices with entries in R. Show that GLn is corepresentable by a ring G.
A Hopf algebra (over Z) is a commutative ring R together with ring homomorphisms ∆ : R Ñ RbZ R and
ε : R Ñ Z, and a Z-linear map λ : R Ñ R, which are called, respectively, comultiplication and counit and
antipode map, such that the following equalities hold: pidb∆q∆  p∆bidq∆, mpidbεq∆  id  mpεbidq∆
and mpid b λq∆  ιε  mpλ b idq∆. Here m : R b R Ñ R and ι : Z Ñ R are the multiplication and unit
of R.
Show that the group structure on GLn pRq induces a Hopf algebra structure on G. Describe the comul-
tiplication explicitly.
Exercise 3.8. Let G be a monoid. Explain the following identification and inclusion (see Exercise 2.1 for
the definition of BG):
G  HomBG p, q  HomGSet pG, Gq € HomSet pG, Gq
If G is a group, show that this implies an inclusion
G € AutSet pG, Gq
of the group G in the symmetric group on G, i.e., Cayley’s theorem.
Chapter 4

Limits and colimits

A classical lemma in topology says that a pair of continuous functions taking values in some topological
space X
f : p8, 0s Ñ X, f : r0, 8q Ñ X
such that f p0q  f p0q gives rise to a unique function

f : p8, 8q Ñ X
whose restrictions are f and f . In the same vein, given say a field k and two commutative k-algebras A
and B, a ring homomorphism
f : A bk B Ñ C
into another commutative ring C is the same as a pair of ring homomorphisms

a : A Ñ C, b : B ÑC
whose composition with the maps k Ñ A and k Ñ B agrees. In both cases, we see that a map out of a
given object (p8, 8q, resp. A bk B) into any other object in the category in question consists of maps
out of certain other objects that are compatible. Both notions are pushouts, which in turn is a special
case of the concept of a colimit. These, and the corresponding dual notion, limits, are introduced in this
chapter.

4.1 Initial and terminal objects


Definition 4.1. An object X in a category C is called an initial object if, for every object Y P C, the
Hom-set HomC pX, Y q is a singleton, i.e., has exactly one element.
A terminal object in C is, by definition, an initial object in C op , i.e., for each Y P C,

HomC op pX, Y q  HomC pY, X q  tu.

It is customary, in view of the examples below, to denote initial objects by 0 P C and terminal objects
by 1 P C.

Example 4.2. We have the following examples:


category initial object terminal object
Set H tu
Grp, Mon, Ab, Vectk 0 (the trivial group, monoid, vector space) 0
Ring, CRing Z 0
Most of these are immediately verified. As an example, we check that the initial object of Ring is Z.
Indeed, any ring homomorphism f : Z Ñ R sends (by definition) 0 ÞÑ 0R , 1 ÞÑ 1R . By additivity, therefore
n ÞÑ n  1R for n ¥ 0 and n ÞÑ pn  1R q.

25
26 CHAPTER 4. LIMITS AND COLIMITS

Lemma 4.3. Initial and terminal objects are unique up to unique isomorphism. That is: if X and Y

PC
are both initial (or both terminal) objects, then there is a unique isomorphism X Ñ Y .
Proof. Since X and Y are initial, there are unique maps f and g as in the following diagram:
f
X / Y
idY
g
idX  f
X / Y.
Since X (resp. Y ) is initial both parts commute, i.e., g  f  idX and f  g  idY . We conclude that X is
uniquely isomorphic to Y . For terminal objects, apply the argument to C op .
While initial (and terminal) objects are unique (up to unique isomorphism) if they exist, there is no
a priori reason for them to exist in a category. As a “stupid” example, the full subcategory Set¥2 of all
sets that have at least 2 elements has neither an initial nor a terminal object(!) . A more meaningful
counterexample is the category of fields (Exercise 4.1).

4.2 Diagrams and cones


Definition 4.4. Let C be a category and J a small category. A diagram of type J (or of shape J) in C
is a functor
D : J Ñ C.
For somewhat historic reasons, one tends to denote the objects of the indexing category J by i, j and
write Di instead of Dpiq etc.
Example 4.5. Here are some basic examples. In the source categories, the only non-identity morphisms
are for the indicated inequalities.
J diagrams of type J
t0u objects in J
t0 1u D0 Ñ D1 , i.e., morphisms in C
t0 1 2u D0 Ñ D1 Ñ D2, i.e., composable morphisms in C
t0u \ t1u pD0, D1q, i.e., pairs of objects in C
t0 Ñ 1u Ñ D , i.e., two objects with two parallel morphisms between them
g
D0 1
f

Definition 4.6. Given a category J, the left cone J ˜ is defined as the category whose objects are
ObjpJ ˜ q  tu \ ObjpJ q,
i.e., we add a new object. Moreover, this object is turned into an initial object:
HomJ ˜ p, q  HomJ ˜ p, j q : tu
for each j P J. The morphisms in J itself are untouched, i.e., HomJ ˜ pi, j q : HomJ pi, j q for i, j P J.
Finally, HomJ ˜ pj, q : H. The identity and composition laws are the obvious ones, noting that we have
no choice how to compose morphisms out of  (there is only one such morphism), nor into  (there are no
such morphisms).
Definition 4.7. Let D : J Ñ C be a diagram (if we speak of diagrams by definition this includes the
assumption that J is a small category). The category of cones of D, denoted ConepDq is defined as the
(non-full) subcategory of the category of functors
FunpJ ˜ , C q
consisting of those objects (i.e., functors), whose restriction to J € J ˜ is the given diagram D and of those
morphisms (i.e., natural transformations), whose restriction to J is the identity of D.
4.3. LIMITS 27

Thus, the additional information present in a cone D̃ : J ˜ Ñ C is an extra object X P C, namely


X  D̃pq. For each j P J, this object comes with maps fj : X Ñ Dj such that for each morphism
α : i Ñ j in J, the diagram
X
fi fj

~ Dα
Di / Dj
commutes. A morphism between such a cone, and another similar one (with X 1 , fi1 etc.) is a map X Ñ X1
such that the diagrams
X / X1
fi

~ fi1
Di
commute for all i P J.
Example 4.8. We further demystify this with some concrete examples:
J D : J Ñ C ObjpConepDqq
t0u D0 P C X Ñ D0 (i.e., an object X and a morphism to the given D0 )
t0 1u D0 Ñ D1 X , i.e., an object X, two maps f0 , f1 such
f0 f1
~
D0 / D1
that the diagram commutes
t0u \ t1u pD0, D1q X P C, f0 : X Ñ D0 , f1 : X Ñ D1 , i.e., an object X, two
maps f0 , f1 with no condition on them.
t0 Ñ 1u ÑD Ña D0 Ñf D1, i.e., an object X, a morphism a such that
g g
D0 1 X
f
f  a  g  a.
The morphisms in ConepDq are the expected ones. For example, for D0 Ñ D1 a morphism between two
g

f
cones
HomConepDq pX Ña D0 Ñf D1, Y Ñb D0 Ñf D1q
g g

is a map x : X ÑY such that the diagram involving x, a and b commutes.

4.3 Limits
Definition 4.9. Let D : J Ñ C be a functor. A cone over D, i.e., an object in ConepDq is called a limit
of D if it is a terminal object of ConepDq.

As a special case of Lemma 4.3 we have:


Corollary 4.10. Let D : J Ñ C be given. If a limit of D exists, it is unique up to unique isomorphism.
Remark 4.11. In view of the unicity one also speaks of the limit and denotes it by lim D. It is also
customary to indicate the functor D by drawing its image in C. For example,

limpD0 Ñ D q : limpD : J Ñ C q,
g

f
1

where D is the functor t0 Ñ 1u Ñ C mapping to the previously displayed objects and morphisms in C.
Example 4.12. We revisit the examples above:
28 CHAPTER 4. LIMITS AND COLIMITS

For J  t0u Ñ C, a limit is a terminal object in the category whose objects are maps X Ñ D0 and
D

whose morphisms are the obvious commutative triangles. This category contains, in particular, the identity
morphism D0 Ñ0 D0 . This object is terminal: given any X Ñ
idD f0
D0 , there is a unique dotted map making
the triangle commute:
f0
X / D0 .
f0
idD0
D0
Thus a limit for J is just the given object D0 (together with the only possible map as part of the cone,
namely the identity). We observe that 0 is the initial object of J, so this somewhat boring result is a
special case of a more general phenomenon considered in Exercise 4.3.
This exercise shows that the limit of a diagram D0 Ñ D1 (of shape 0 1) in any category is just the
object D0 together with the obvious maps, namely the identity idD0 and the given map to D1 .
Definition 4.13. A limit of a diagram D : J  t0u \ t1u Ñ C is called a binary product or just product.
If it exists, it is also denoted as D0  D1 (given that such a diagram is nothing but a pair of objects D0
and D1 P C).
Concretely, a product of such a diagram is an object X equipped with two maps X Ñ D0 , X Ñ D1 such
that for any other object Y coming with two maps Y Ñ D0 , Y Ñ D1 there is a unique map Y Ñ X making
the obvious diagrams commute. To say more about this, we need to look at some specific categories:
Example 4.14. For C  Set, the product is just the usual product of sets: D0  D1  tpd0 , d1 q|di P Di u:
it comes with two projections pi : D0  D1 Ñ Di , and given any other set Y with two maps fi : Y Ñ Di ,
there is a unique map
f : Y Ñ D0  D1 , y ÞÑ pf0 py q, f1 py qq
such that pi  f  fi .
For C  Top, the product D0  D1 is the set-theoretical product, equipped with the product topology.
Indeed, this topology on D0  D1 is such that the two projections D0  D1 Ñ Di are continuous, and such
that for any two continuous maps fi : Y Ñ Di (from any topological space Y ), the resulting map f as
above is again continuous. The (easy) proof of this fact is in any topology textbook.
Example 4.15. In the same vein, for C  Vectk , the product is the usual product of vector spaces. We
will understand the observation that the product in these two categories is “just” the product in Set
equipped with some extra structure more fully once we see that the forgetful functor Vectk Ñ Set does
not come alone, but has a so-called left adjoint (see Example 5.3) which automatically forces the forgetful
functor to preserve products (see Lemma 5.7).
Example 4.16. In the category of fields Fieldsp€ CRingq, there is no product K  L if the two fields have
different characteristic, since there are no maps between fields of different characteristic. One can also
show (easily) that there is no product even of the form K  K if K admits a non-identity automorphism.
By contrast, the category Ring (or also CRing) does have products, given by the set-theoretic product
together with the component-wise addition and multiplication.
Product of vector spaces exist for more than two factors. They are special cases of the following:
Definition 4.17. Let I be a set, regarded as a category in which we only have identity morphisms (this
± called a discrete category). A limit of a functor D : I Ñ C is called a product. It is also denoted as
is
iPI Di , using that such a functor D is just a collection of objects Di P C (for each i P I).

Note that an empty product (the case I  H) is just an initial object. All we said so far about
Set, Mon, ModR , Top, CRing, Ring (existence and description of binary products) extends to arbitrary
products (indexed by sets) without any change.
4.3. LIMITS 29
±
It is useful to picture these notions: a product is an object i Di with maps pi such that for any other
object T mapping to all the Di there is a unique dotted map making everything commutative, like so:
± D!
i Di o T
pi
pj
|  v " ~
Di t Dj Dk .( . .

Definition 4.18. A limit of a diagram t0 Ñ 1u Ñ C is called an equalizer .


Example 4.19. Again, in a general category, equalizers need not exist. They do exist in Set, where an
equalizer of a diagram D0
g
Ñ
f
D1 is given by(!)

td P D0, f pd0q  gpd0qu.


Equalizers also exist in Mon, Grp, ModR (modules over a ring R), Top (where they are in each case the
set-theoretic product equipped with the usual monoid structure, ... , topology).

The following little lemma will be used later in the construction of adjoint functors (Theorem 5.19).
Lemma 4.20. Suppose we have an equalizer

 eqpX Ñg Y q
f
E

in a category (i.e., assume the equalizer exists). Then the natural map E Ñ X is a monomorphism.
Proof. We have
HompT, E q  tt P HompT, X q, f t  gtu € HompT, X q.

Definition 4.21. A limit of shape


/

is called a fiber product. A commutative diagram

T /A

 
B / C
is called cartesian if the natural map T Ñ A C B : limpA Ñ C Ð B q is an isomorphism.
Example 4.22. In Set, the fiber product of a diagram A Ñ C Ð B is the set tpa, bq P A  B, f paq  g pbqu.
f g

If a category C has fiber products, then a map f : X Ñ Y is a monomorphism iff the natural map ∆ is
an isomorphism. This follows directly(!) from the definition of monomorphisms and the universal property
of the fiber product.
X

$
X Y X / X
f
 f 
X / Y.
30 CHAPTER 4. LIMITS AND COLIMITS

Equivalently, f is a monomorphism iff the diagram


X X
f
f 
X / Y
is cartesian.

4.4 Colimits
Definition 4.23. A colimit of a diagram D : J Ñ C is, by definition, a limit of the resulting diagram
Dop : J op Ñ C op .
A coproduct is a colimit of a²diagram D : J Ñ C where J is a discrete category (has only identity
morphisms). It is then denoted j PJ Dj .
A coequalizer is a colimit of a diagram D : t0 Ñ
1u Ñ C.
A pushout is the dual notion for a pullback, i.e., a colimit of a diagram of shape
/


.
Thus, a colimit is just a special case of a limit (and vice versa). However, since for many specific
categories C, one does not have a handy description of C op , it is in practice quite useful to understand
this concept independently from limits, so we now unwind these notions.
Let J be a discrete small category and²D : J Ñ C a functor. I.e., just a collection of objects Dj , for
each j P J (which is a set). A coproduct j Dj is then a product in the opposite category C op . Thus, it is
²
an object i Di with maps pi such that for any other object T mapping from all the Di there is a unique
dotted map making everything commutative, like so:
² D!
D 46/ > TO
< i O ib h
pi
pj

Di Dj Dk ...
Again, coproducts and other colimits need not exist. If a colimit for a given diagram D : J Ñ C does
exist, it is unique up to unique isomorphism.
Example 4.24. ² In Set, arbitrary (small) coproducts exist. ² They are given by the disjoiunt union (whence
the notation i ). The disjoint union of topological spaces Xi (in which U is open iff U X Xi is open in
Xi for each i) is the coproduct of topological spaces.
In Mon and Grp, coproducts exist as well. The adjoint functor theorem (see Theorem 5.19 and its
corollaries) will construct coproducts in Grp for free. That said, let us only indicate that the coproduct
in Grp is given by the so-called free product (which really is not a product): given two groups G, H the
elements in G \ H are words with letters from both groups except the identity elements, modulo the
relations xx1  H for any two adjacent copies of x P G Y H and its inverse.
In Ab and Vectk , and more generally ModR (modules over a ring R), coproducts are given by direct
sums º
Vi  tpvi q|vi P Vi , only finitely many vi  0u.
P
i I
In CRing, coproducts exist as well. The coproduct R \ S is commonly known as the tensor product
R bZ S. Indeed, by definition of the tensor product HompR b S, T q  HompR, T q  HompS, T q for any
commutative ring. More generally, the coproduct in CRingk (commutative k-algebras) is given by  bk .
4.5. FUNCTORIALITY 31

Infinite coproducts exist as well, and are referred to as infinite tensor products in the literature (see
e.g., [Bourbaki:Algebra]). See also Exercise 4.7.

4.5 Functoriality
In the discussion of (co)limits, we have so far fixed a given diagram
D:J Ñ C.
We will now lift this restriction and discuss how (co)limits behave when D varies. Therefore, in this
section, we fix a small category J and a (not necessarily small) category C.
Definition 4.25. The diagonal functor
∆:C Ñ FunpJ, C q
sends an object XP C to the functor pJ Qqj ÞÑ X and any morphism j Ñ j 1 in J is mapped to idX .
Given D P FunpJ, C q, a cone on D is then nothing else but an object X P C and a map of diagrams
∆pX q Ñ D.
Lemma 4.26. Suppose that C has all J-shaped limits. Then the choice of a limit lim D for each diagram
D : J Ñ C assembles to a functor
lim : FunpJ, C q Ñ C.
Proof. In order to specify this functor, we need to define it on objects, which we already did, and on
morphisms. Let us be given a morphism between diagrams, i.e., a natural transformation α : D Ñ D1 (of
functors J Ñ C). (We write D Ñ D1 as opposed to D ñ D1 just to streamline the notation.) The limits
lim D and lim D1 give rise to the vertical maps in the following diagram
∆plim Dq / ∆plim D1 q
ι ι1
 
D α
/ D1 .

The composite α  ι is a cone on the diagram D1 . As lim D1 is a terminal cone (being a limit), there is
a unique map of diagrams as depicted making the diagram commutative. We define this map to be the
image (under lim) of our map α.
By the unicity of such maps, it is clear that lim preserves composition and identity, so it indeed gives
a functor.
Example 4.27. Consider the category J  t1 Ñ 0 Ð 2u. Recall that a limit of a diagram D : J Ñ Top
is the pullback of a pair of continuous maps
X1 X0 X2 / X1
f1
 f2 
X2 / X0
(a choice of a pullback is the subspace of the product tpx1 , x2 q P X1  X2 , f1 px1 q  f2 px2 qu, equipped with
the subspace topology of the product topology). In this case the lemma says that given a collection of
continous maps Xi Ñ Xi1 (i  0, 1, 2) where X11 Ñ X01 Ð X21 is another similar diagram such that the
obvious squares commute), there is a unique continuous map
X1 X0 X2 Ñ X11 X 1 X21 0

that is compatible with the given maps Xi Ñ X 1 . i


32 CHAPTER 4. LIMITS AND COLIMITS

4.6 Preservation of limits


Definition 4.28. Let J be a small category. We say that a functor F : C Ñ D preserves limits of shape
J if for any diagram K : J Ñ C and any limit cone over K, the image of this cone is a limit cone for the
composition F  K : J Ñ D. We write this slightly colloquially as
F plim Kj q  lim F pKj q.
We say F preserves limits if this holds for all small categories J.
Recall that any two limit cones of K are (uniquely) isomorphic (both being terminal objects in Cone K, Lemma 4
Since any functor preserves isomorphisms (Lemma 2.20), it is therefore enough to check the above condition
for some (as opposed to all) limit cone over K.
Example 4.29. The forgetful functor Vectk Ñ Set preserves limits. By Proposition 4.32 below it suffices
to check this for equalizers and products. Indeed, the equalizer of a diagram

V ÑW
f

is the subspace tv P V |f pv q  g pv qu (with the obvious inclusion into V ), and this is also the equalizer of
the underlying diagram of sets. Similarly, the underlying set of a product of vector spaces is the product
of the underlying sets.
Lemma 4.30. Let C be a category and X P C arbitrary. Then the corepresenting functor
hX : C Ñ Set, Y ÞÑ HomC pX, Y q
preserves limits. Written colloquially:
HomC pX, lim Yi q  lim HomC pX, Yi q.
Likewise, the representing functor
hX : C op Ñ Set
preserves limits. Again, written colloquially (and using that limits in C op are colimits in C):
HomC pcolim Yi , X q  lim HomC pYi , X q.
Proof. Let D : I Ñ C be a diagram whose limit lim D exists. A morphism X Ñ lim D is a collection of
compatible morphisms fi : X Ñ Dpiq for each i P I that are compatible. This is the same as an element
in lim HomC pX, Di q.
The dual statement follows since the representing functor hX,C : C op Ñ Set is the same as the corepre-
senting functor hX
C op : C
op
Ñ Set for X, regarded as an object in the opposite category.
Corollary 4.31. Representable functors C op Ñ Set (Definition 2.29) and corepresentable functors C Ñ
Set preserve limits.
We will establish a converse statement for this in the context of the adjoint functor theorem.

4.7 Basic existence results


The following criterion constructs arbitrary limits from special ones. In particular it is a means to show
the existence of arbitrary limits.
Proposition 4.32. Let D : J Ñ C be a diagram. Consider the diagram
¹ ¹
Dk Ñ
f
Dj ,
P
k J
g
α:i Ñj
where the component corresponding to a morphism α : i Ñ j is
4.7. BASIC EXISTENCE RESULTS 33
±
ˆ pj : Ñ Dj for the first map, and
P Dk
k J
±
ˆ Dα  pj : kPJ Dk Ñ Di Ñ Dj for the second map.
D α

We suppose that all these products exist. If, moreover, the equalizer E of the above diagram exists, then
this equalizer is a limit of D.
±
Proof. For X P C, HomC pX, E q identifies with morphisms h : X Ñ k Dk such that f  h  g  h.
Moreover, h is tantamount to a familiy of morphisms hk : X Ñ Dk . The equality f h  gh is then
equivalent to pf hqα  pghqα for each α : i Ñ j, so that pj h  Dpαqpi h and then hj  Dα hi . All in all, this
is a familiy of morphisms hk : X Ñ Dk such that hj  Dα hi for all α. This is precisely the datum of a
cone over D. This shows that E is a limit for D.

Definition 4.33. A category is called complete (resp. cocomplete) if all diagrams D : J Ñ C (with
arbitrary small categories J) admit a limit (resp. colimit).

The proposition thus shows that a category is (co-)complete if (and obviously also only if) it has (co-
)equalizers and (co-)products. See also Exercise 4.7 for a statement further reducing (co-)products to finite
(co-)products and cofiltered limits (resp. filtered colimits).
The categories Set, Mon, Grp, Ab, ModR , Top, Ring and CRing are all complete and cocomplete. The
fact that both completeness and cocompleteness hold parallely is not a coincidence: we will show – as a
consequence of the adjoint functor theorem) – that, under a mild additional set-theoretic condition (known
as accessibility) a category is complete iff it is cocomplete.
The existence of (co)limits is passed on to the category of functors as follows:
Lemma 4.34. Let J, C be small categories and D be a category. Suppose that D has all limits (resp. col-
imits) of shape J. Then the functor category FunpC, Dq also has all limits (resp. colimits) of shape J.
Moreover, these (co)limits are computed objectwise, i.e., for each X P C the evaluation-at-X-functor

evX : FunpC, Dq Ñ D, F ÞÑ F pX q
preserves (co)limits. Written more colloquially, the following natural maps are isomorphisms:

plim Fj qpX q Ñ limpFj pX qq, colimpFj pX qq Ñ pcolim Fj qpX q.


Proof. It suffices to do limits, since colimits are limits in Dop and FunpC, Dop q  FunpC op , Dq.
We colloquially write Fj (j P J) for the datum of a functor F : J Ñ FunpC, Dq. In order to construct
a limit for F , we need to specify an object E in FunpC, Dq. For each object X P C, the composite

F pX q : J Ñ FunpC, Dq Ñ D, j ÞÑ Fj ÞÑ Fj pX q,
ev
X

(i.e., evX is the evaluation at the object X). has a limit by assumption on D. Choose such a limit and
define E pX qpP Dq to be that chosen limit. The limit is functorial in X by Lemma 4.26, so any map X Ñ X 1
in C gives rise to a unique map E pX q Ñ E pX 1 q that is compatible with the given maps Fj pX q Ñ Fj pX 1 q
for all j P J. (More formally, a morphism X Ñ X 1 yields a natural transformation F pX q Ñ F pX 1 q of
diagrams J Ñ D. Then apply Lemma 4.26). By unicity, E is then necessarily a functor.
One checks(!) by unwinding the definitions that E is indeed a limit.

p : PShpC q : FunpC op , Setq has all (co)limits.


Corollary 4.35. For a small category C, the category C

According to Exercise 4.16, the Yoneda embedding

C Ñ Cp
preserves all limits, but does not usually preserve colimits.
34 CHAPTER 4. LIMITS AND COLIMITS

4.8 Filtered colimits and compact objects


Filtered categories and the concomitant filtered colimits and cofiltered limits are pervasive throughout
mathematics. They are the basis of finiteness conditions on objects in an abstract category. For example,
linear algebra has the condition that an R-module is finitely presented, field theory the condition that
a field extension is finitely generated, or topology has the condition that a topological space is compact.
While many expositions of these concepts spell these conditions out “explicitly”, we will see that they are
in fact special cases of the same category-theoretic notion.
Definition 4.36. A category C is finite if it has finitely many objects and morphisms.
Definition and Lemma 4.37. A category C is called filtered if every finite diagram D : J Ñ C (i.e.,

Ñ
J is finite) has a cocone. This is equivalent to the following three conditions (these amount to the cases
J  H, J  t0, 1u and J  t0 1u).
ˆ C  H,
P C, there is an object Z P C together with morphisms X Ñ Z Ð Y .
ˆ for any two objects X, Y

ˆ for any two morphisms X Ñ Y in C, there is an object Z and a morphism h : Y Ñ Z such that
f

g
hf  hg:
X Ñ Y Ñ Z.
f h
g

Remark 4.38. ˆ Note the datum of h in the last condition resembles the situation with a coequalizer.
However, the condition here is weaker: the cocone is not required to be initial.
ˆ If C happens to be (the category associated to) a poset, then the third condition is vacuous since
necessarily f  g. A (category associated to a) poset P is also called directed if it is filtered.
Equivalently P  H and for any x, y P P there needs to be a z P P with x ¤ z, y ¤ z.
Definition 4.39. A diagram D : I Ñ C in a category C is a filtered diagram (resp. directed diagram) if I
is filtered (resp. if I is a directed poset). A filtered colimit is the colimit of a filtered diagram D : I Ñ C.
To emphasize the fact that I is directed, many authors denote directed colimits by

ÝÑ D
lim or also as Ýlim
Ñ Xi
and refer to such colimits as inductive limits. We will avoid this terminology to avoid confusion of such
special colimits with limits.
As usual, the condition on the opposite categories or diagrams is denoted with a “co”: a cofiltered
diagram D : I Ñ C is one where I is a cofiltered category, i.e., I op is filtered etc.
A codirected limit is, in older literature, also known as a projective limit, and denoted

ÐÝ D
lim or also as Ð Ý Xi
lim
Example 4.40. ˆ The natural numbers N are a directed poset. Diagrams N Ñ C can be depicted as
X0 Ñ X1 Ñ X 2 Ñ . . . .
This is an example of a directed diagram.
Dually, diagrams Nop Ñ C can be depicted as
. . . X2 Ñ X1 Ñ X 0 .
This is a codirected diagram.
ˆ More generally, any preordered set pA, ¤q in which any finite subset (including the empty set) has an
upper bound, gives a directed poset.
4.8. FILTERED COLIMITS AND COMPACT OBJECTS 35

ˆ The category Idem is the category with one object , and one non-identity morphism e : Ñ
satisfying
e  e  e.
This category is an example of a filtered, but non-directed category.

Lemma 4.41. Let D : J Ñ Set be a filtered diagram. Then the colimit of D exists, and it is given by
º
Di { ,
i J P
where  is the equivalence relation xipP Diq  xj pP Dj q if and only if there is some k P J and maps
i Ñ k Ð j such that Dpαqpxi q  Dpβ qpxj qpP Dk q.
α β

Informally, two elements in the disjoint union of the sets Di are identified if and only if they agree
“eventually” in some Dk for “large enough” k.

Proof. We first check that  is an equivalence relation. It is clearly reflexive and symmetric. For transi-
tivity, let x1 P Di1 , x2 P Di2 , x3 P Di3 such that x1  x2 , x2  x3 . Thus there are objects i4 and i5 and
maps as indicated in the diagram

i1 i2 i3 x1 <x_2  <x3


    ~ ~
i12 i23 x12 <x23


    ~
i, x.

As J is filtered, the finite diagram consisting of i1 , i2 , i3 , i12 , i23 has a cocone, denoted i. The image of x12
and x23 in Di²agree since they both are the image of x2 . This shows x1  x3 .
Let C : Di {  as in the claim. We have natural maps si : Di Ñ C which we denote by x ÞÑ rxs.
These clearly exhibit C as a cocone. Suppose given another cocone pti : Di Ñ M q on our diagram D.
Clearly there is at most one map t : C Ñ M such that t  si  ti , since the Di map (jointly) surjective to
C. To check the existence of such a map, define

Ñ M, tprxsq : tipxq.
t:C

One checks immediately this is well-defined by definition of  and satisfies t  si  ti .

Recall from Lemma 4.30 that corepresentable functors hX  HomC pX, q preserve limits (in C).
Whether or not corepresentable functors preserve colimits depends very much on the category C, on
the object X, and on the type of colimits allowed. We now discuss the most important class of colimits
that corepresentable functors may preserve. A variant of this appears in Exercise 4.14.
Definition 4.42. Let C be a category that has all filtered colimits. An object X P C is called compact or
finitely presentable if the functor hX : HomC pX, q preserves filtered colimits. I.e., for any filtered diagram
D : I Ñ C, the natural map

colim HomC pX, Di q Ñ HomC pX, colim Di q

is a bijection.

The colimit at the left is a colimit in Set, whereas the one in the right is in C. The surjectivity of the
map means that given a map (in C)
f : X Ñ colim Di
36 CHAPTER 4. LIMITS AND COLIMITS

there is some j P J and a map f 1 such that the following diagram commutes:
: Dj
f1

f 
X / colim Di .
Thus X is “small enough” so that any map out of X factors over a finite piece of the colimit. The following
examples corroborate the idea that compactness is really a finiteness condition.
Example 4.43. ˆ A set X P Set is compact iff its cardinality is finite. First of all, a singleton
² tu is
compact since Homptu, Di q  Di . More generally, the compactness of any finite set X  finite tu
then follows either from direct inspection(!) or, alternatively from Corollary 4.47 below.
Conversely, let X be a compact object in Set. We observe
¤
X  U.
€
U X finite

”
This union is in fact a filtered colimit (even directed): for any finite family of finite subsets Ui € X
(i runs through a finite index set), the union i Ui is again a finite subset of X). Using the bijection
colim HomSet pX, U q  HomSet pX, colim U q  HomSet pX, X q Q idX ,
and the description of filtered colimits in Lemma 4.41, we see that there is some finite subset U € X
and a map f : X Ñ U such that its composition with the inclusion U € X equals idX . This forces
U  X and in particular that X is finite.
ˆ Let X be a topological space. Then X is compact in the sense of topology (i.e., every open covering
of X has a finite subcover) iff X is compact in the poset OpenpX q consisting of the open subsets of
X, ordered by inclusion.
To see this, note first that to a set Ui , i P I of open subsets we can assign a filtered diagram
K : tfinite subsets of I u Ñ OpenpX q,
” ”
which sends any finite subset J € I to iPJ Ui . This diagram is filtered and its colimit is iPI Ui (!) .
”
Now if X P OpenpX q is a compact object, and X  iPI Ui is an open covering, then idX”is a map
X Ñ colim K, where K is as above. By compactness it factors over some K pJ q, i.e., over iPJ Ui for
a finite J. Thus X is compact in the sense of topology.
Conversely, assume X is compact in the sense of topology and let U : I Ñ OpenpX q, i ÞÑ Ui be any
filtered diagram. We have to show
HomOpenpX q pX, colim U q  colimi HomOpenpX q pX, Ui q.
”
The left hand side is empty iff colim U  iPI Ui ˆ X, otherwise it is a singleton. In the former
case, all the Ui ˆ X, so that the Hom-sets in the right hand colimit are all empty, hence so is their
” In the latter case there is, by compactness of X, a finite subset J € ObjpI q such that
colimit.
X  iPJ U” i . Since the diagram U is filtered, there is some cocone c of J (in the filtered category I).
Then Uc  iPJ Ui  X, and we are done.
ˆ As a bit of a terminological mismatch, let us point out that an object X P Top is compact (as in
Definition 4.42) iff it is a discrete topological space associated to a finite set (Exercise 4.11).
ˆ The one-dimensional Banach space C P Ban¤1 is not compact. Using l1  ²iPN C  colimp²ni1 Cq
gives a counter-example to the compactness condition. First observe
HomBan¤1 pC, V q  B1 pV q.
4.9. COMMUTING (CO)LIMITS WITH (CO)LIMITS 37

Then note that ¸


colim B1 pCn q  tpxn q, xn P C, |xn| ¤ 1, almost all xn  0u
°
is strictly contained in B1 pl1 q  tpxn q, xn P C, |xn | ¤ 1u.
A relaxed compactness condition, known as ω1 -compactness, does hold though. We will come back
to this in the discussion of the adjoint functor theorem for locally presentable categories.

4.9 Commuting (co)limits with (co)limits


In analysis, there is Fubini’s theorem stating that (under appropriate assumptions on the function) for a
function
f : R  R Ñ R,
the integral satisfies » » »
f px, y qdpx, y q  f px, y qdx dy.

R R R R

In category theory, Fubini’s theorem takes the following formulation:


Lemma 4.44. Let I and J be small categories and F : I  J Ñ C be a diagram. We write limjPJ F pi, j q
for the limit of the composite
iid
J Ñ I J ÑC
F

etc. Suppose that all limits in the following expression exist:

lim lim F pi, j q


i j

Then this is a limit for F .


In particular, if also all limits in the expression limj limi F pi, j q exist, then this is isomorphic to
limi limj F pi, j q, i.e., one can swap the order of performing limits in two variables.
Dually, the same statement holds with colimits instead of limits throughout.

Proof. This can be shown by reducing to the case C  Set via the Yoneda lemma (Lemma 3.6) and direct
inspection in that case, such as done in [Rie17, Theorem 3.8.1].
We will be able to prove this more conveniently after introduce a little more terminology by the following
steps, which are relevant in their own right:
ˆ the limit functor is a partial right adjoint to the diagonal functor ∆ : C Ñ FunpI, C q (Lemma 5.10),
ˆ trivially, the diagram involving the diagonal functors

/ FunpI, C q

C

∆ ∆
 ( 
FunpJ, C q ∆ / FunpI  J, C q
commute,
ˆ therefore, their (partial) right adjoints commute up to isomorphism (Lemma 5.11).

While the above proof is not a one-line-proof, it is still “trivial” in the sense that it does not use any
assumptions on I, J and F (other than the statement to make sense in the first place). A sharper question
is the compatibility of colimits with limits (or, dually, limits with colimits). Let us be given a diagram

F :P  J Ñ C.
38 CHAPTER 4. LIMITS AND COLIMITS

Assuming that all limits and colimits in the following line exist, we have a canonical map
κ : colimj lim F pp, j q Ñ lim colimj F pp, j q.
p p

It is the unique map fitting into the diagram


F pp, j q o limp F pp, j q / colimj limp F pp, j q
αj κ
  u
colimj F pp, j q o limp colimj F pp, j q
The left vertical map is part of the colimit being a cocone. The middle vertical map αj then arises by
functoriality of the limit. Then, κ exists because of the universal property of the upper right colimit.
For example, let P  J  t0, 1u be discrete categories and suppose all the limits and colimits exist.
The map is then
κ : pA0  B0 q \ pA1  B1 q Ñ pA0 \ A1 q  pB0 \ B1 q.
For C  Set, this map is not an isomorphism. For C  Ab, it is an isomorphism since in this case the
finite coproducts are also products, cf. Exercise 4.8, and coproducts commute with each other.
The following statement gives a broad range of cases when the map is an isomorphism.
Proposition 4.45. Let F : P  J Ñ Set be a functor where P is finite and J is filtered. Then the above
canonical arrow κ is an isomorphism.
Proof. Recall we are to prove that the map
κ : colimj lim F pp, j q Ñ lim colimj F pp, j q
p p

discussed above is an isomorphism, i.e., a bijection.


For surjectivity of κ, let x P limp colimj F pp, j q. The components xp P colimJ F pp, q come from some
xp,j P F pp, j q. Using the finiteness of P and the filteredness of J, we can assume that j is independent
of p. The xp,j are not yet (in general) an element in colimj limp F pp, j q since, for α : p Ñ p1 in P , the
image of xp,j in F pp1 , j q need not equal xp1 ,j . However, they do agree in colimJ F pp1 , q, hence there is
some morphism β : j Ñ j 1 in J such that these two elements agree in Fp1 ,j 1 . We can apply this argument
to each morphism of P (of which there are finitely many by assumption!), and get a j Ñ j 2 such that the
xp,j 2 forms an element xj 2 P limp F p, j 2 q. The image of xj 2 in colimP limJ F maps to our given element
x P limJ colimP F . Thus κ is surjective.
We show the injectivity of κ: let y, z P colimJ limP D have the same image under κ. We have some
j P J abd yj , zj P limP F p, j q mapping to y and z. Their images yp,j , zp,j P F pp, j q may not be equal, but
they do have the same image in colimJ F pp, q. Hence there is some j Ñ j 1 such that yp,j and zp,j map
to the same element in F pp, j 1 q. We repeat this for each p and get j Ñ j 2 such that yp,j 2  zp,j 2 for all p.
Hence yj 2  zj 2 P limP F p, j 2 q so that y  z.
Remark 4.46. We refer to this result by saying that in Set, finite limits commute with filtered colimits.
We emphasize that this contains three important specifications: that the category in question be Set, the
limit is finite, and the colimit is filtered.
ˆ An immediate extension to other categories than Set is given in Exercise 4.13. We will extend this
result to a broad range of categories called locally presentable categories such as Grp, ModR , Ban¤1 .
ˆ For C  Set, some restriction on the type of (co)limits considered is necessary, as the above discussion
shows. Another related exchange statement is that so-called sifted colimits commute with finite
products in Set. Sifted colimits, i.e., colimits of diagrams D : J Ñ C where J is a sifted category are
more general than filtered colimits. An example of a sifted, but non-filtered category is the reflexive
coequalizer category
f
/
1` / 0
g
σ
4.10. FINAL FUNCTORS 39

(two objects, three non-identity morphisms and f σ  g σ  id0.) See, e.g., [AdamekRosickyVitale:What
for an exposition of sifted categories and sifted colimits.
We now show that finite colimits of compact objects are again compact.
Corollary 4.47. Let C be a category with all colimits. Let D : J Ñ C be a finite diagram (i.e., J is a
finite category, Definition 4.36) such that Dpj q is a compact object for each object j in J. Then colim D
is a compact object.
Proof. Let T : I Ñ C be a filtered diagram. We have the following commutative diagram, in which the
isomorphisms hold as indicated. Thus the top horizontal map is an isomorphism, so that colimj Dj is
compact:
colimi Hompcolimj Dj , Ti q / Hompcolim Dj , colim Ti q

,Lemma 4.30

,Lemma 4.30 limj HompDj , colim Ti q
O
,Definition 4.42

colimi limj HompDj , Ti q,Proposition 4.45/ limj colimi HompDj , Ti q.

Example 4.48. Continuing our list of compact objects in various categories, let R be a ring. An object
M P ModR is compact iff it is finitely presented (in the usual sense of algebra, i.e., the cokernel of an
appropriate map Rn Ñ Rm with n, m 8). The proof proceeds along similar lines as above: R P ModR
is compact since
HomModR pR, q  U
is the forgetful functor ModR Ñ Set, which does preserve filtered colimits(!) . We invoke Corollary 4.47
to see that finitely presented modules are compact.
Conversely, suppose M is compact. We have
M  colimN €M finitely generated N.
The indexing category consisting of finitely generated submodules of M is filtered since the sum N N 1 € M
is finitely generated if N and N 1 are. Thus, idM factors over a finitely generated submodule N , making M
a direct summand of N . Thus M is finitely generated.
Then, for a finitely generated module M  Rn {E, where E € Rn is the submodule of relations. Again
we have E  colimF €E finitely generated and we obtain(!) M  colimF Rn {F . Again idM factors over some
finitely presented module Rn {F , and hence M is itself finitely presented.

4.10 Final functors


A typical argument in elementary analysis is to consider only subsequences pank qkPN instead of an originally
given sequence pan qnPN . In category theory, the corresponding concept is called (co)final functors. These
facilitate the computation of (co)limits: given a diagram
D:J ÑC
the (co)limit lim D or colim D can often be computed by replacing J by a smaller, hopefully simpler
subcategory I € J. Instead of just using full subcategories, it is useful to go “all-in”, by considering
arbitrary functors I Ñ J. Given a functor D : J Ñ C, there is a natural map
lim D Ñ limpD  K q.
Indeed, lim D maps (compatibly) to all Dj , and therefore in particular to all DK piq .
40 CHAPTER 4. LIMITS AND COLIMITS

Definition 4.49. A functor K : I Ñ J between small categories I and J is called initial if for each functor
D : J Ñ C (with C being arbitrary), the natural map
lim D Ñ lim D  K
is an isomorphism.
Dually, K is called final if K op : I op Ñ J op is initial. Equivalently, for each functor D : J Ñ C, the
natural map
colim D  K Ñ colim D
is an isomorphism.
In order to exhibit a criterion that allows to check whether some given K is final, we need to introduce
some more terminology.
Definition 4.50. Let F : C Ñ D be a functor and X P D. The comma category
F {X
is the category whose objects are pairs pY, f q consisting of an object Y P C and a morphism (in D)
f : F pY q Ñ X. We define HomX {F ppY, f q, pY 1 , f 1 qq to be the set of morphisms y : Y Ñ Y 1 in C such that
the diagram
pq
F pY q F pY 1 q
F y
/

f1 f
" |
X
commutes. (The composition is the obvious one, coming from composing morphisms in C.)
Example 4.51. A dual variant of this is the comma category X {F whose objects are pairs pY, f q with
f : F pY q Ñ X (as opposed to X Ñ F pY q).
A special case is F  idC . The categories X {idC (resp. idC {X) are commonly denoted X {C (resp. C {X)
and called the under-category (resp. over-category) of X in C.
Concrete examples include the following:
ˆ Given a commutative ring k, the category k {CRing is the category of k-algebras and k-algebra homo-
morphisms.
ˆ In algebraic geometry, the category Sch{S, for a scheme S is the category of S-schemes.
ˆ The category tu{Top is the category of pointed topological spaces and base-point preserving maps.
Definition 4.52. For a small category C, the set of path components, denoted π0 C is defined as
ObjpC q{ ,
where  is the equivalence relation generated by the relation 0 : X 0 Y iff there is a morphism X ÑY.
Concretely, X  Y if there is a finite zig-zag of morphisms in C:
: T0 Ð T1 Ñ T2 Ð T3 . . . Tn  Y.
X
A category is called connected if X  Y for any two objects, i.e., π0 C is either empty or a singleton.
Example 4.53. ˆ If C has an initial or, alternatively, a final object, then π0 C  tu.
ˆ The category Fields has π0 pFieldsq  tp prime u \ t0u, since there a zig-zag of morphisms between
two fields precisely iff their characteristic is the same.
Proposition 4.54. Let K : I Ñ J be a functor. The following are equivalent:
4.10. FINAL FUNCTORS 41

(1) for each object j P J, the comma category K {j is non-empty and connected, i.e., π0pK {j q  tu,
(2) K : I Ñ J is initial.
Example 4.55. This statement recovers Exercise 4.3: if J has an initial object e, then the inclusion
K : te u € J
ÑC
is an initial functor, i.e., for any diagram D : J
lim D  Dpeq.
Indeed, for each j P J, the under-category K {j has as objects maps e Ñ j. There is precisely one such
object, in particular the category is non-empty and connected.
Proof. (of Proposition 4.54) (1) ñ (2): Let D : J Ñ C be a functor. Restricting a cone over D to a cone
over D  K defines a functor
ConepDq Ñ ConepD  K q.
We will show this is an isomorphism of categories, so that in particular one has a terminal object iff the
other has one (i.e., lim D exists iff lim DK exists, and in that event they are the same).
Let us be given a cone X for the diagram D  K. In order to construct X Ñ Dpj q for each j, we choose
some i P I and a map K piq Ñ j (which is possible since K {j is non-empty). We define a map X Ñ Dpj q
u

as the composite
X Ñ DK piq DÑpuq Dpiq.
For another choice pi1 , u1 q as in the diagram below, we the composite
pu q 1
X Ñ DK pi1q DÑ Dpiq
agrees with the previous map. By induction it suffices to consider two-step zig-zags as in the diagram:
i ù K piq ù DK
; E
piq .
u u
  
iO 1 u2 ! u2
#
K pO i2 q /
=j X / DK
; O
pi2q / Dj
;

u1 u1
i1  #
K pi1 q Y / DK pi1 q

(Note that in the right diagram, the left half commutes since X is a cone over F K.) One checks this is
indeed an inverse function for the objects in Cone D and ConepD  K q (!) . This bijection on the level of
objects also extends to morphisms: given a map X Ñ Y fitting into a commutative diagram including the
dotted arrows above, it yields a morphism of cones over D by composition.
For the proof of the converse (2) ñ (1), we refer to [Riehl:Categorical].
Example 4.56. The category ∆ has as objects the sets rns : t0, 1, . . . , nu, and morphisms are given by
non-decreasing maps:
Hom∆ prns, rmsq  tf : t0, 1, . . . , nu Ñ t0, 1, . . . , mu, f piq ¤ f pj q for all i ¤ j pP rnsqu.
For example, there are two maps r0s Ñ r1s (mapping to 0 and 1, respectively), and one map r1s Ñ r0s.
We can thus consider the (non-full) subcategory
ι : tr1s Ñ r0su Ñ ∆.
This functor is initial.(!) Therefore limits of diagrams
∆ Ñ C,
42 CHAPTER 4. LIMITS AND COLIMITS

can be computed by considering the (much smaller!) diagram consisting only of the two objects r0s and
r1s instead.
A sample application of this situation is as follows: let X be a topological space, and
§
U : Ui ÑX
P
i I

the coproduct of a set of open subsets Ui € X mapping to X. Consider the functor


¹
R : ∆op Ñ Top{X, rns ÞÑ U,
t0,1,...,nu
the product indexed by the set rns  t0, 1, . . . , nu in the category Top{X of topological spaces over X. (The
product in this category is the fiber product over X in the category Top.) For example,± Rpr0sq± U and
Rpr1sq  U X U . On morphisms, R sends a map α : rns Ñ rms to the map Rpαq : t0,...,mu U Ñ t0,...,nu U
± ±
whose component for i P rns is the composition t0,...,mu U Ñ αpiq U  U . For example, there are two
maps
Bi : r0s Ñ r1s, 0 ÞÑ i,
and RpBi q : Rpr1sq  U X U Ñ Rpr0sq  U is the projection onto the two coordinates. There is one map
s : r1s Ñ r0s and Rpsq : U Ñ U X U is the diagonal map.
Suppose given a presheaf on the category Top, for example a representable presheaf F  hT 
HomTop p, T q : Topop Ñ Set. Then

Rop : ∆ Ñ pTop{X qop Ñ Topop Ñ


F
Set.
The limit of such a composite is

lim F pU q ÑÐ F pU X Uq ÑÐ F pU  X U X U q . . . .

Since the inclusion tr1s Ñ r0su Ñ ∆ is initial, the limit of this infinite diagram can be computed as the
Ñ F pU 
limit of
F pU q X U q.
This simplification is implicit in the definition of a sheaf , where one demands that the natural map
F pX q Ñ limpF pU q Ñ F pU  X U qq
OpenpX q such
” a sheaf on a topological space X is a ±
Ñ
is an isomorphism. (More precisely, presheaf F on±
that for any open covering V  iPI Vi of an open subset, F pV q is a limit of iPI F pVi q i,j F pVi X Vj q,
where the two maps are restriction along Vi X Vj € Vi and € Vj , respectively.)

4.11 Exercises
Exercise 4.1. Let Fields € CRing be the full subcategory of the category of commutative rings whose
objects are fields. Show this category has neither initial nor terminal objects.
Exercise 4.2. (1) Show that Fields has all filtered colimits. What are the compact objects in this cate-
gory?
(2) Fix a field k and consider Fieldsk{ , the category of field extensions of k. Recall that a field extension
k € K is called finite iff dimk K 8. Express this as a compactness condition.
(3) Express the condition of being an algebraic extension k € K in terms of appropriate filtered colimits
and an appropriate compactness condition. (Solving this requires some basic field theory.)
Exercise 4.3. Let J be a category with an initial object 0. Let D : J Ñ C be any diagram. Show that
D0 is a limit for D.
4.11. EXERCISES 43

Exercise 4.4. Let C be a category such that all equalizers and finite products exist. Show that all fiber
products exist in C. Hint: express a fiber product A B C in terms of an appropriate equalizers involving
appropriate products.

Exercise 4.5. Let C be a category and X P C an object. The over-category C{X is the category whose
objects are maps T Ñ X in C and whose morphisms are commutative triangles as expected. Dually, the
under-category CX { has as objects maps X Ñ T .
State and prove a necessary and sufficient condition for C{X (dually CX { ) to have products (resp.
coproducts).
Describe concretely coproducts in the category Top : Toptu{ of pointed topological spaces.

Exercise 4.6. Show that Zrts bZ Zrus  Zrt, us is not the coproduct of Zrts and Zrus in the category
Ring of non-commutative (but associative and unital) rings.
Hint: contemplate the corepresenting functor hZrts (Example 2.14). What can you say a priori about
X \Y
h for two objects X, Y in any category?
Note: the category of rings does have all small colimits, but coproducts are less simple to describe; they
involve taking free associative rings.

Exercise 4.7. Let C be a category that has all filtered colimits and all finite coproducts. Show C has
arbitrary (small) coproducts.
Conclude that CRing has arbitrary (small) coproducts.

Exercise 4.8. An object X P C is called a zero object if it is both initial and terminal. Assume that C
ˆ has a zero object and
ˆ has finite coproducts and finite products
ˆ the natural map X \ Y Ñ X Y (from the coproduct to the product) of two arbitrary objects
X, Y P C is an isomorphism.
(1) Show that HomC pX, Y q is naturally an abelian monoid.
(2) C is called additive if it satisfies the above three conditions and if the abelian monoid HomC pX, Y q is
actually an abelian group.
Which of the categories Set, Mon, Ab, Vectk , Ban and Ban¤1 are additive?

Exercise 4.9. Let pVi qiPI be a (set-indexed) family of Banach spaces. Show that a coproduct in Ban¤1 is
given by º ¸
Vi  tv  pvi q|vi P Vi , |v |1 : |vi| 8u
(and the |  |1-norm). Show that a product in Ban¤1 is given by
¹
Vi  tv  pvi q|vi P Vi , |v |8 : sup |vi | 8u
² ±
(and the |  |8 -norm). In particular, l1  iPN C and l8  iPN C.
Also show that products and coproducts in Ban only exist if all but finitely many of the Vi are 0. (One
may reduce to the case Vi  C for all i first.)

Exercise 4.10. Let G be a group and BG Ñ Vectk a functor, i.e., a vector space V with a G-action.
Compute the limit and the colimit of this functor explicitly.

Exercise 4.11. Show that X P Top is compact in the sense of Definition 4.42 iff it is finite and discrete.
Hint: for the nontrivial direction, consider the canonical injection X Ñ X \N  colimn X \t0, 1, . . . , n
1u and put a (non-trivial) topology on the spaces X \ t0, 1, . . . , n  1u such that the colimit carries the
coarse topology.
44 CHAPTER 4. LIMITS AND COLIMITS

Exercise 4.12. ˆ Show that the categories CptHaus € Top of compact Hausdorff spaces, respectively
all topological spaces, have all small limits and that the inclusion preserves them. (This requires using
some non-trivial theorem from point-set topology.)
ˆ Discuss the pushout of the diagram (with the natural maps)

r1, 1szt0u / r1, 1s



r1, 1s
in the category of Hausdorff spaces (and continuous maps) and in the category Top.
Exercise 4.13. Let C Ñ Set be a conservative functor that preserves filtered colimits and finite limits.
Show that filtered colimits commute with finite limits, i.e., show that the conclusion of Proposition 4.45
holds for C.
Give explicit examples of categories C satisfying these conditions.
Exercise 4.14. Let C be a category. An object P P C is called compact projective if
HomC pP, q : C Ñ Set
preserves filtered colimits and reflexive coequalizers. (Equivalently, using terminology that we have not
yet introduced, it preserves sifted colimits. See, e.g., [AdamekRosickyVitale:What].)
Show that an object P P ModR is compact projective iff it is a finitely generated projective module
(i.e., there is a surjection Rn Ñ P which splits).
Exercise 4.15. We say that a functor F : C Ñ D detects limits (or reflects limits) if for any diagram
K : J Ñ C and any cone K̃ : J ˜ Ñ C the following holds: if the composite F  K̃ : J ˜ Ñ D is a limit
cone of F  K, then K̃ is a limit cone for K. (Compare this to preservation of limits as in Definition 4.28.)
Show that F detects limits in the following two situations:
ˆ C has all limits, F preserves these and F is conservative,
ˆ F is fully faithful.
Give examples of functors where this argument can be applied.
Exercise 4.16. We say that a functor creates limits if it preserves (Definition 4.28) and detects (Exer-
cise 4.15) them.
Show that the Yoneda embedding
y:CÑC p
creates all limits.
Give an example of a category C where y does not preserve coproducts.
Exercise 4.17. Show that Set is not equivalent to Setop .
Exercise 4.18. A category C is called sifted if it is non-empty and the diagonal functor
∆:C Ñ C  C, X ÞÑ pX, X q
is final. Show that every filtered category is sifted.
Note: The category ∆op and its full subcategory

tr0s Ñ
Ð
r1suop
are sifted, but not filtered. (A bare-hands proof of this assertion is tedious.) Colimits indexed by this
latter category are known as reflexive coequalizers.
4.11. EXERCISES 45

Exercise 4.19. Let R be a commutative ring and M an R-module. Let S € R be a submonoid with
respect to the multiplication (also known as a multiplicatively closed nonempty subset). In this context
there is the notion of localization of R-modules [StacksProject].
(1) Show that the localization M rS 1 s is a filtered colimit of an appropriate diagram
Ñ ModR
D:J
that has the property that Dpj q  M for each object j P D. (Stated slightly colloquially: what are
the transition maps so that M rS 1 s  colimpM Ñ M Ñ M . . . ?)
? ?

(2) Show that localization preserve finite intersections: for M1 , . . . , Mn € M , we have


£ £
p MiqrS 1s  pMirS 1sq.
i i

(3) Show by an example that the localization functor M ÞÑ M rS 1s does not preserve infinite products.
Exercise 4.20. Let
A / B / C
 
  
A1 / B1 / C1
be a commutative diagram in some category. Prove:
(1) If both squares  and  are cartesian, then so is the total square (consisting of A, C, A1 and C 1 ).
(2) If the total square and  are cartesian then so is .
Exercise 4.21. Describe the coequalizer of a diagram of sets,

R 1 X,
f
Ñ f

in terms of the following relation  on X:


x  x1 ô DrpP Rq, x  f prq, x1  f 1 prq.
Exercise 4.22. An abelian group A is called a torsion group if for each a P A there is some n P N, n ¡ 0
such that na  0. For an abelian group A, show that the following are equivalent:
(1) A is a torsion group,
(2) A is a filtered colimit of finite abelian groups.
Exercise 4.23. Let
A1 / A
f1 f
 
B1 /B

be a cartesian diagram in a category C. Prove: if f is a monomorphism, then f 1 is also a monomorphism.


Does the converse hold?
Exercise 4.24. Let A, B and C be abelian groups and f : A Ñ B, g : B Ñ C two group homomorphisms
such that g  f  0. In this situation we say that

0ÑAÑB Ñg C Ñ 0
f

is called a short exact sequence of abelian groups, if (by definition), g is surjective, ker g  im f and f is
injective.
46 CHAPTER 4. LIMITS AND COLIMITS

Show that f and g fit into a short exact sequence iff the square
f
A / B
g
 
0 / C
is both cartesian and cocartesian, i.e., cartesian in the opposite category pAbqop .

Exercise 4.25. Let I be the christmas-tree-category: its objects are the christmas tree balls located at the
endpoints of the branches, and there are morphisms as depicted (and also composites of these morphisms,
not depicted):

 

 
/ o

 

 
/ o

 

Solve one of the following problems:


ˆ Let
K:I ÑC
be a diagram taking values in a merry category. Compute its limit and its colimit!
Hint: find appropriate final (resp. cofinal) full subcategories of I.
ˆ Bring self-made christmas cookies to the exercise session!

Exercise 4.26. Let ∆ be as in Example 4.56 and let ∆n : ∆op Ñ Set be the functor represented by rns.
Show that for any m, n  0 the functor

∆n  ∆m : ∆op Ñ Set; rks ÞÑ Hom∆prks, rnsq  Hom∆prks, rmsq


is not representable. Let C be the category of partially ordered sets with non decreasing maps as morphisms.
Prove that the functor F : C op Ñ Set; X ÞÑ HompX, rnsq  HompX, rmsq is representable. Use this to
describe ∆n  ∆m .

Exercise 4.27. A category C is called pointed if it has a zero object (Exercise 4.8), denoted 0 P C. A zero
morphism is a morphism f : X Ñ Y that factors over some zero object (equivalently, by Lemma 4.3, over
any zero object). A zero morphism is also denoted by 0. In a pointed category C, a kernel (resp. cokernel )
is a limit (resp. colimit) of a diagram
X Ñ Y.
f

It is denoted by ker f (resp. coker f ).


4.11. EXERCISES 47

(1) Show that the category Grp of groups is pointed.


(2) Show that the kernel, in the sense defined above, of a group homomorphism f : G Ñ H agrees with
tg P G, f pgq  eH u (and the natural inclusion into G).
(3) Show that the cokernel, in the sense defined above, coker f is the H {NH pf pGqq (together with the
canonical map H Ñ H {NH pf pGqq. Here NH pf pGqq denotes the normalizer of the subgroup f pGq € H.
48 CHAPTER 4. LIMITS AND COLIMITS
Chapter 5

Adjunctions

It was already mentioned that functors are what connects different categories. Many times, we don’t like
one way tickets, but want to come back at some point. Given a functor
F :C Ñ D,
(how) can we go back from D to C? In complete generality, we cannot expect this. In special cases, namely
if F is (part of) an equivalence of categories, we do have an inverse functor. Adjunctions are in between
the void and the perfect: we will have two functors F : C Ñ D and G : D Ñ C that are closely related,
but (in general) stopping short of being an equivalence.
The situation is comparable to the situation with (continuous, linear) maps between Hilbert spaces:
given such a map (a.k.a. operator) f : H Ñ H 1 , an adjoint operator is a map g : H 1 Ñ H such that
xf pxq, yy  xx, gpyqy.
In category theory, functions get replaced by functors and the inner product between vectors gets replaced
by Hom-sets between objects.
We will see in §5.1 that adjunctions are all over the place. We will understand that having an adjoint
functor for F tells us a lot about the functor. Notably, we will establish a close bond between (co)limits
and adjoints.
Given the interest in establishing adjoint functors, we will prove an easy adjoint functor theorem (The-
orem 5.19), which constructs, for example, the Stone-Čech compactification functor
β : Top Ñ CptHaus.
We will then single out and study a particular class of adjunctions, so-called monadic adjunctions.

5.1 Definitions and examples


Definition 5.1. Given a pair of functors
L:C Õ D : R,
an adjunction is an isomorphism of functors

Ψ : HomD pL, q ñ HomC p, Rq.
(Both are functors C op  D Ñ Set.) In this event, L is called the left adjoint, R the right adjoint. We
say that “L is a left adjoint”, if there is some functor R for which there is such an adjunction. Similarly
for saying that “R is a right adjoint”. The existence of an adjunction between two functors as above is
denoted by
L
&
L % R or R $ L or Cf K D.
R
In such a depiction, left adjoints will always be drawn on top of their right adjoints in these notes, but not
all authors follow such a convention.

49
50 CHAPTER 5. ADJUNCTIONS

Remark 5.2. By definition of an isomorphism of functors, this means that for each X P C, Y P D, we
have an isomorphism of sets (i.e., a bijection)
ΨX,Y : HomD pLX, Y q Ñ HomC pX, RY q.
This isomorphism is functorial (a.k.a. natural) in X and Y in that for each morphism f : X Ñ X 1 and
g : Y Ñ Y 1 the following diagram commutes:
ÞÑghLpf q
HomD pLX 1 , Y q HomD pLX, Y 1 q
h
/

ΨX 1 ,Y ΨX,Y 1
 ÞÑRpgqhf / 
HomC pX 1 , RY q HomC pX, RY 1 q.
h

Adjunctions are everywhere, too numerous to name even a fraction! First of all, every equivalence of

Õ
categories
F :C D : F 1
is an adjunction. Indeed, HomC p, q Ñ HomD pF pq, F pqq is a bijection (with inverse given by applying
F 1 ), so that we obtain a bijection, functorial in X and Y :
HomD pF pX q, Y q  HomC pF 1 pF pX qq, F 1 pY qq  HomC pX, F 1 pY qq.
(Note that, by definition of an equivalence, there is a functorial isomorphism id Ñ F 1  F .) As a partial

converse, given an adjunction, one can construct an equivalence on certain subcategories, see Exercise 5.1.
Example 5.3. We consider the forgetful functor
U : Ab Ñ Set.
We show it admits a left adjoint, known as the free abelian group functor,
Zrs : Set Ñ Ab.
If this exists, it must satisfy

HomAb pZrtus, Aq  HomSet ptu, Aq  A.


!

This is(!) satisfied if we set the free abelian group on a single generator to be Zrtus : Z. Furthermore,
for the free abelian group on any set S, we observe that
º
S  tu.
P
s S

Thus, the free abelian group on S needs to satisfy


º ¹ ¹
HomAb pZrS s, Aq  HomSet pS, Aq  HomSet p tu, Aq  HomSet ptu, Aq 
!
A.
P
s S P
s S s

We do get such an isomorphism if we set º


ZrS s  Z.
P
s S
More concretely, we can set
à
ZrS s : tf : S Ñ Z, f psq  0 for all but finitely many s P S u  Z
P
s S

regarded as an abelian group by pointwise addition. This is functorial in S, by sending a morphism


r : S Ñ T of sets to the map of abelian groups
¸
ZrS s Ñ ZrT s, pf : S Ñ Zq ÞÑ pT Ñ Z, t ÞÑ f psqq.
s,r sp qt
5.1. DEFINITIONS AND EXAMPLES 51

One checks(!) this is functorial and gives an adjunction


Z rs (
Set h K Ab.
U

In view of Lemma 5.7 and Exercise 5.4, we have actually no choice (up to an isomorphism of functors)
in defining this left adjoint.
The functor U does not preserve coproducts (Z ` Z, which is the coproduct in Ab, is not bijective to
Z \ Z, the coproduct in sets). Hence U does not admit a right adjoint by Lemma 5.7.
The discussion above goes through without any changes if we replace Z by any ring R, giving rise to a
the free-forgetful adjunction
R rs
t
ModR 6 Set
U

Example 5.4. For a set X, we can consider the power set P pX q, as a poset ordered by inclusion, and
thus as a category (Example 2.9). Given a map (of sets) f : X Ñ Y , we then have an order-preserving
map, hence a functor
f 1 : P pY q Ñ P pX q, V ÞÑ f 1 pV q.
This functor has a left adjoint, known as the existential quantifier :

Df : P pX q Ñ P pY q, U ÞÑ f pU q  ty P Y |Dx P f 1pyq, x P U u.
It also has a right adjoint, known as the all quantifier :

@f : P pX q Ñ P pY q : U ÞÑ ty P Y |@x P f 1pyq, x P U u.
Thus, we get a chain of adjunctions
Df % f 1 % @f .
For, say, the left adjunction we need to check

Df U € V ðñ U € f 1pV q.
“ñ”: for x P U , y : f pxq P Df U € V , so x P f 1 pV q. “ð”: for y P Df U , there is x ÞÑ y, x P U € f 1 pV q,
so y P V .

Example 5.5. There is a chain of adjunctions, where left adjoints are drawn on top of right adjoints: U
is the forgetful functor, D is the functor equipping a set with the discrete topology (any subset is open), C
puts the coarse topology on a set X (only H and X are open),

v D
Top h U / Set
C

Indeed, given a set X and a topological space T , we have

HomSet pX, U T q  HomTop pDX, T q,

i.e., any map of sets X Ñ U T is continuous with the discrete topology on X. The chain of adjoints can not
be prolonged: if C had a right adjoint, it would need to send coproducts to coproducts (by Lemma 5.7).
However, the coproduct in Top, C pS q \ C pS q does not have the coarse topology (it has 4 open subsets
±
instead). Similarly, if D had a left adjoint, it would preserve products, so that the product topology
on iPN t0, 1u would need to be discrete. This is however not the case. A remedy for this is offered by
Exercise 5.3.
52 CHAPTER 5. ADJUNCTIONS

Example 5.6. Let f : R Ñ S be a map of (not necessarily commutative, but associative and unital) rings.
As above, let ModS be the category of left S-modules with S-linear maps as morphisms. The forgetful
functor U (sending an S-module M to the same abelian group M , but now regarded as an R-module via
f ) has two adjoints:
S bR 
t
ModS j U / ModR
HomR S, p q
Here HomR pS, q is the set of homomorphisms of left R-modules, regarded as a left S-module via the right
action of S on itself.

5.2 Limits and adjoints


The concepts of limits and adjoints are closely related: right adjoints preserve limits (dually left adjoints
preserve colimits), and limit functors are right adjoints (dually, colimits are left adjoints).
Lemma 5.7. Let L : C Ñ E be a left adjoint. Then L preserves colimits in the sense that for any diagram
D : J Ñ C whose colimit exists (in C), then Lpcolim Dq is a colimit of L  D. In brief:
Lpcolim Dq  colimpL  Dq.
Stated slightly more colloquially,
Lpcolim Di q  colim LpDi q.
Dually, right adjoints preserve (existing) limits.
Proof. Let us be given a cocone for L  D, i.e., an object T P E that fits into a commutative diagram like
so, here i, j, k P J and α : i Ñ j stands for a map in D:

Lpcolim Df i qj
D! /42 T
8 O < O
p q
p q
L pi
L pj

LpDi q
p q LpDj q LpDk q
/ ...
L α

We need to show there exists a unique dotted map so that the diagram still commutes.
We now apply the adjunction isomorphism, crucially (!) also using that this isomorphism is functorial
to see that such a diagram as above is equivalent to
D! p q
colim
; O D
d ii 35/ R
< O
T
pi
pj

Di / Dj Dk ...
α

In this diagram a dotted map exists uniquely as stated. Again by adjunction, this is equivalent to the
existence and unicity of the dotted map in the previous diagram. This shows that Lpcolim Di q is a colimit
for L  D.
Example 5.8. For a map f : X Ñ Y of sets, the preimage functor f 1 : P pY q Ñ P pX q between the
power sets preserves unions and intersections. Indeed, these are colimits and limits, respectively (!) , so
the claim follows from f 1 having a left and a right adjoint.
Example 5.9. As in Example 5.6, let f : R Ñ S be a ring homomorphism. The functor S bR  preserves
all colimits. In particular, it preserves cokernels, i.e., coequalizers of the form

pM Ñ0 N q.
f
5.3. THE TRIANGLE IDENTITIES 53

Dually, HomR pS, q preserves limits and, in particular, kernels. Indeed, they are left (resp. right) adjoint
to the forgetful functor U .
Lemma 5.10. Let J be a small category and C be a category with all J-shaped limits (resp. J-shaped
colimits). Then the limit (res. colimit) functor constructed in Lemma 4.26 is a right (resp. left) adjoint of
the diagonal functor ∆ : C Ñ FunpJ, C q (Definition 4.25).
Proof. For X P C and a diagram D : J Ñ C, a bijection
HomFunpJ,C q p∆pX q, Dq Ñ HomC pX, lim Dq
is obtained by noticing that a map ∆pX q Ñ D is nothing but a cone on D, with tipping point X. This is
the same as a map X Ñ lim D. One checks(!) that this bijection is functorial in X and D.
Lemma 5.11. Let
C Ñ
F
DÑE
G

be two composable functors. Suppose F and G have a right adjoint F R : D ÑC and GR : E Ñ D,


respectively. Then F R  GR is a right adjoint of G  F .
Proof. This follows from composing the bijections
HomC p, pF R  GR qpqq  HomD pF pq, GR pqq  HomE ppG  F qpq, q.

Example 5.12. Dually, the same also applies for the composite of left adjoints. For example, let R Ñ
S Ñ T be two ring homomorphisms. The composite of the forgetful functors ModT Ñ ModS Ñ ModR is
again the forgetful functor. Thus, passing to left adjoints, we obtain functorial isomorphisms:
T bS S bR b  T bR .
Now we can (conveniently) prove the categorical Fubini theorem, stated in Lemma 4.44.
Proof. We want to show that for F : I  J Ñ C, the object X : limi limj F pi, j q is, provided that
all these limits exist, a limit of F . We use the Yoneda embedding y : C Ñ C, p which creates (i.e.,
preserves and detects) limits (Exercise 4.16). Thus X is a limit for F iff y pX q is a limit for y  F and
y pX q  limi limj y pF pi, j qq. We can therefore replace our functor F by I  J Ñ C Ñ C.
y p p
The category C
has all (small) limits (Corollary 4.35), so we may assume C has all limits.
As outlined in the proof sketch of Lemma 4.44, the diagram involving the diagonal functors
/ FunpI, C q

C

∆ ∆
 ( 
FunpJ, C q / FunpI  J, ∆q

obviously commutes. Thus, the respective limit functors, also commute.

5.3 The triangle identities


Instead of the definition given above, adjunctions can also be approached in a different (but ultimately
equivalent) way, as follows.

ÕD:R
Definition 5.13. Given an adjunction
L:C
we call a morphism f : X Ñ RpY q (in C) and a morphism g : LpX q Ñ Y transposes if they correspond to
each other under the bijection
ΨX,Y : HomC pLpX q, Y q  HomD pX, RpY qq.
54 CHAPTER 5. ADJUNCTIONS

ÕD:R
Lemma 5.14. Let
L:C
be two functors.
Then there is an adjunction between L and R (i.e., a functorial isomorphism Ψ as in Definition 5.1
above) if and only if there is a pair of natural transformations

η : idC ñ RL and ϵ : LR ñ idD


satisfying the so-called triangle identities
Lη ηR
L +3 LRL R +3 RLR
id id
ϵL Rϵ
 
L, R.

The transformation η is then called the unit and ϵ is called the counit of the adjunction.

Proof. “ñ”: for an object X P C, ηX : X Ñ RLX is defined to be the transpose of idLpX q : LpX q Ñ LpX q,
and ϵY : LRY Ñ Y the transpose of idRY . The statement that η is natural amounts to the commutativity
of the left hand square below, which is (using the functoriality of Ψ!), equivalent to the commutativity of
the right hand square, which is obvious:
ηX idLX
X / RLX LX / LX
f RLf Lf Lf
 ηX 1   idLX 1 
X1 / RLX 1 LX 1 / LX 1 .
The left triangle identity is equivalent to the commutativity of the left square below, which again by
adjunction is equivalent to the commutativity of the right square below, which is obvious:
idLX ηX
LX / LX X / RLX
LηX idLX ηX idRLX
 ϵLX   idRLX 
LRLX / LX RLX / RLX.
“ð”: Given ϵ and η, we define two maps
R pf q
HomD pLX, Y q Ñ HomC pX, RY q, pf : LX Ñ Y q ÞÑ pX Ñ RLX Ñ RY q,
η X

and conversely

HomC pX, RY q Ñ HomD pLX, Y q, pg : X Ñ RY q ÞÑ pLX Ñ LRY Ñ Y q.


Lg ϵ Y

Using the triangle identities, one checks(!) that these two maps are indeed mutual inverses.

5.4 Constructing adjoint functors via the solution set condition


We know that right adjoints preserve limits (Lemma 5.7). Adjoint functor theorems are theorems asserting
that – under appropriate further hypotheses on the involved categories – limit-preserving functors are
right adjoint. In this section, we develop the most basic adjoint functor theorem, using Freyd’s solution
set condition.
As a special case, consider the unique functor

P :C Ñ tu
5.4. CONSTRUCTING ADJOINT FUNCTORS VIA THE SOLUTION SET CONDITION 55

sending all objects (and morphisms) in some category C to  (and id ). A left adjoint L of this functor, if
it exists, is an object X : Lpq P C such that for all Y P C:

HomC pX, Y q  Homtu p, ppY qq  Homtu p, q  tid u.

In other words, X needs to be an initial object. The statement to come can therefore be regarded as
asserting the existence of a left adjoint to some (very) special functors.
Definition 5.15. A set tXi uiPI of objects in a category C is called weakly initial if for each Y P C there
is some i P I and a map Xi Ñ Y .

The point in this definition is that we have a set of such objects. If we were to allow a class at this
point, the definition would be vacuous: in this case we could take the class of all objects in C, and the
identity morphisms.
Proposition 5.16. Let C be a category that is complete, i.e., has all small limits. Then C has an initial
object iff it satisfies the following condition, known as the solution set condition: there is a weakly initial
set tXi uiPI .

Proof. If C has an initial object 1, then the solution set condition is satisfied by definition of an initial
object.
Conversely, assume we± have a weakly initial set tXi uiPI . Since C has all small (i.e., set-indexed) limits,
±
we can consider W :  iPI Xi . For each Y P C there is at least one morphism W Ñ Y , namely
W  Xi Ñ Xi Ñ Y . We can further consider
¹
E : eqpW Ñ W q Ñ W,
i

P
f EndC W p q
where the projection to the copy corresponding to f are the maps idW and f , respectively. We claim that
E is an initial object. For each Y P C there is a map E Ñ W Ñ Y .
Suppose there are two maps f, g : E Ñ Y . We will show f  g which shows that E is initial. Consider
the diagram:
U : eq pf, gqι f,g
/ E / Y
O
s i

E
i / W
iιs / W.
/
idW

By the above property of W , there is some morphism s : W Ñ U as indicated. We have two endomorphisms
of W , the composite i  ι  s, and idW . By construction of E, pi  ι  sqi  idW  i  i  idE . Being an
equalizer map, i is a monomorphism (Lemma 4.20), so that

ι  s  i  idE ,

i.e., the part in the diagram containing thge curved “” arrow and ιsi commutes. Thus ι has a right inverse.
Again, ι being an equalizer is a monomorphism. Having a right inverse means it is an isomorphism so that
f  g.

We intend to upgrade this statement to the existence of more general left adjoints. Before stating that
adjoint functor theorem we show that it is enough to establish the value of a would-be left adjoint L on
individual objects.
Lemma 5.17. Let R : D Ñ C be a functor such that for each X P C the functor
D Ñ Set, Z ÞÑ HomC pX, RpZ qq (5.18)
56 CHAPTER 5. ADJUNCTIONS

is corepresentable by some object LpX q. (I.e., there is a bijection, functorial in Z, HomD pLpX q, Z q 
HomC pX, RpZ qq.) Then there is a unique functor

L:C ÑD
which is given on objects by X ÞÑ LpX q and such that the family of isomorphisms in (5.18) is also functorial
in X.

Proof. This lemma is very similar to Lemma 4.26 and can be proven as outlined in Exercise 5.11. Alter-
natively, one may use the Yoneda lemma in the guise of the equivalence

y:D
 FunpD, Setqcorepr ,
Ñ
where at the right we have the full subcategory of the functor category consisting of corepresentable
functors (Lemma 3.6). Then define L to be the composite
ÞÑHomC pc,Rpqq y 1
C
c
ÝÑ FunpD, Setqcorepr Ñ D.
One checks this is a left adjoint to R.

Theorem 5.19. (Adjoint functor theorem via the solution set condition) Let R : D ÑC be a functor
that preserves limits. We assume:
(1) D is complete, i.e., has all limits.
(2) For each c P C, the comma category (Example 4.51) c{R has a weakly initial set of objects.
Then R has a left adjoint (i.e., is a right adjoint).

Remark 5.20. Condition (2) amounts to the following solution set condition: for each c P C there is a
(small) set I and a family of maps fi : c Ñ Rpdi q such that any arrow h : c Ñ Rpdq can be written as a
composite for some i and some map t : di Ñ d

Rpdi q
fi
c /
h
p q
R ti
! 
Rpdq.

Roughly speaking, this means that the class of maps out of c into Rpdq, which is potentially a class of
morphisms, is actually “controlled” by a set of such morphisms.

Proof. We break the proof into three steps:


(1) R admits a left adjoint iff the comma category c{R has an initial object for each c P C.
(2) As D is complete and R preserves limits, the comma category c{R is complete.
(3) Hence, by Proposition 5.16, c{R has an initial object.

Lemma 5.21. A functor R : D Ñ C admits a left adjoint iff the comma category c{R has an initial object
for each c P C.

Proof. “ð”: By Lemma 5.17, we have to show that for each c P C functor

HomC pc, Rpqq : D Ñ Set


is corepresentable. Picking an initial object pd, f : c Ñ Rpdqq in the comma category, we construct a
functorial bijection
HomD pc, Rpd1 qq Õ Hom
1:1
D pd, d1q.
5.4. CONSTRUCTING ADJOINT FUNCTORS VIA THE SOLUTION SET CONDITION 57

The two maps are constructed by glancing at the following diagram.

c / Rpdq
pq
R δ
! 
Rpd1 q.

A map δ : d Ñ d1 is sent to the diagonal composite. Conversely, a map c Ñ Rpd1 q is an object in the
comma category, so there is a (unique) map δ making this diagram commute. The resulting maps are
indeed inverse by the unicity.
“ñ” is left as an exercise.

Lemma 5.22. Suppose R : D Ñ C is a limit-preserving functor and D is complete. Then the comma
category c{R is complete for each c P C.

Proof. Let K : I Ñ c{R be a diagram, written as pdi , fi : c Ñ Rpdi qq. We can pick a limit d  lim di .
From the fi , we get a map c Ñ lim Rpdi q, which yields a map c Ñ Rpdq since R preserves limits, i.e.,

Rplim di q Ñ lim Rpdi q. One checks that this object is indeed a limit for K.

Corollary 5.23. The forgetful functor


U : Grp Ñ Set
has a left adjoint, the free group functor .

Proof. We know that Grp has all limits and that U preserves them. Indeed, it suffices to check this for
products and equalizers (Proposition 4.32), both of which are readily checked(!) . We now check the
solution set condition: fix X P Set. Consider a map (of sets) f : X Ñ U G. Let S € G be the subgroup
of G generated by the elements f pxq, x P X. Then every element of S is a finite product of the form
pf px1qq1 . . . pf pxnqq1. Thus the cardinality of S is bounded (by ℵ0  7X). In the class of groups S arising
in this way (for all groups G and all maps f ), pick one element of each isomorphism class. Since the
cardinality of the groups arising in this way is bounded, there is a set of such isomorphism classes. The
collection of all maps X Ñ U pS q, with S in this set, forms a set, and is a solution set.

We will now construct the tensor product

M bR N P Ab
of a right R-module M and a left R-module N . Recall that the desired universal property of such a tensor
product is that

HomAb pM bR N, T q  tf : M  N Ñ T, additive in each variable separately, f pm  r, nq  f pm, r  nqu.

The maps at the right hand side are called balanced maps.
Corollary 5.24. Let R be a ring, M a right R-module and N a left R-module. Then the functor

F : Ab Ñ Set, T ÞÑ tf : M  N Ñ T, balancedu

is corepresentable.

Proof. The functor preserves limits, which is again quickly checked for products and equalizers and then
one uses Proposition 4.32. Taking our cue from the proof of Corollary 5.23, we consider a balanced map
f : M  N Ñ T and consider the subgroup T 1 € T generated by the elements f pm, nq for all m P M ,
n P N . Its cardinality is again bounded (by ℵ0 7M 7N ). So, up to isomorphism there is only a set of such
subgroups T 1 . We obtain a solution set for our functor since f factors as a balanced map (i.e., an element
in F pT 1 q) followed by the inclusion T 1 € T .
58 CHAPTER 5. ADJUNCTIONS

Corollary 5.25. There is a functor

 bZ  : Ab  Ab Ñ Ab
such that for each M P Ab, there are adjunctions
M bZ  : Ab Ñ Ab : HompM, q,

 bZ M : Ab Ñ Ab : HompM, q.
Proof. We choose a corepresenting object, denoted M bZ N , of the above functor. This can be made into
a functor as in Lemma 5.17. The stated adjunctions then hold by design: e.g.

HompM bZ N, K q  tbalanced maps f : M  N Ñ K u  HompN, HompM, K qq.


The triple of functors  bZ , Homp, q, Homp, q is an example of a two-variable adjunction in
the following sense:
Definition 5.26. Given three categories, A, B and C, a two-variable adjunction is a triple of functors

F :AB Ñ C, G : Aop  C Ñ B, H : B op  C Ñ A
together with functorial bijections (for a P A, b P B and c P C)

HomC pF pa, bq, cq  HomB pb, Gpa, cqq  HomA pa, H pb, cqq.

Example 5.27. Let A  B  C  Set, and let F : Set  Set Ñ Set be the product. This functor is part
of a two-variable adjunction with

G : Setop  Set Ñ Set, pa, cq ÞÑ Hompa, cq,

H : Setop  Set Ñ Set, pb, cq ÞÑ Hompb, cq.


Indeed, the above bijections, sometimes referred to as currying, are then natural bijections
HomSet pa  b, cq  HomSet pa, Hompb, cqq
f ÞÑ pα ÞÑ pβ ÞÑ f pα, β qqq
ppα, β q ÞÑ gpaqpbqq Ð[ g,
and similarly with Hompa, cq.

We give a final application of the adjoint functor theorem.


Corollary 5.28. The forgetful functor

U : CptHaus Ñ Top

admits a left adjoint, commonly denoted by β and called the Stone-Čech compactification.

Proof. To check that a fully faithful functor C € D, such as CptHaus € Top, preserves limits, it is
enough to see that a product and equalizer in the category D, of a diagram that only takes values in the
subcategory C, is an object of C. In the present situation Tychonoff ’s theorem asserts this for products.
Equalizers of compact Hausdorff spaces are closed subspaces of compact Hausdorff spaces, and therefore
again compact Hausdorff.
In order to check the solution set condition we make the following claim: given a compact Hausdorff
space K and a subset T € K which is dense (i.e., T  K; throughout closures are taken in K), we have

7K ¤ 227 T
.
5.5. THE ADJOINT FUNCTOR THEOREM FOR PRESENTABLE CATEGORIES 59

We prove this claim by constructing an injective map:


L:KÑ P pP pT qq, k ÞÑ tV € T, k P V u
into the double power set. We show L is injective: given k  k 1 we can find (since K is Hausdorff) open
neighborhoods U Q k, U 1 Q k 1 such that U X U 1  H. Then U X T X U 1 € U X U 1  H (since both are
open), so that k 1 R U X T , i.e., U X T R Lpk 1 q. On the other hand
k PU XT
for otherwise there would be an open neighborhood k P W € K with W X U X T  H, but this contradicts
that T is dense in K.
7S
Let S P Top. The sets of cardinality ¤ 22 up to isomorphism is a set. Moreover, the choices of all
topologies on these sets forms a set. Finally, all continuous maps from S to these topological spaces forms
a set. We claim this is a solution set. Indeed, given a map f : S Ñ K (K P CptHaus), we may replace K
7T 7S
by f pS q, which is again in CptHaus and assume T : f pS q is dense in K. Then 7K ¤ 22 ¤ 22 and f
factors in the claimed way.

5.5 The adjoint functor theorem for presentable categories


In this section, we briefly discuss – without proof – the adjoint functor theorem for a wide class of categories
called presentable categories. This theorem is due to Adamek and Rosicky [AdamekRosicky:Locally].
They call these categories locally presentable, but we will follow the terminology of [Lurie:HTT].°
Throughout, let κ be a regular cardinal , i.e., κ is infinite and cannot be° expressed as κ  i α κi with
κi κ and α κ. For example ℵ0 , ℵ1 , . . . are regular cardinals, but ℵω  i ω ℵi is not regular.
Definition 5.29. ˆ A category J is called κ-small if it has fewer than κ morphisms.
ˆ A category C is called κ-filtered if every diagram K : J Ñ C with J being κ-small admits a cocone
in C.
ˆ Suppose C has all κ-filtered colimits. An object c P C is called κ-compact (or κ-presentable) if
HomC pc, q : C Ñ Set
preserves κ-filtered colimits.
Example 5.30. (1) An ℵ0 -small category is a finite category (Definition 4.36), and thus ℵ0 -compact
objects are just the compact objects encountered before.
(2) Suppose κ κ1 and J, C and c as in the definition. Then we have the following implications:
J is κ-small ñ J is κ1 -small,
C is κ-filtered ð C is κ1 -filtered,
c is κ-compact ñ c is κ1 -compact.

(3) An object X P Set is κ-compact iff its cardinality is less than κ.


(4) An object X P Top is κ-compact iff it has the discrete topology and has cardinality κ. This can be
shown similarly to Exercise 4.11.
(5) The category Ban¤1 has all colimits, so we can consider κ-compactness. The one-dimensional ² space
C P Ban¤1 is not (ℵ0 -)compact, but instead ℵ1 -compact. The key point is that l1  nPN C 
colimpC Ñ C2 Ñ . . . q is not an ℵ1 -filtered colimit,
² so that the computation in Example 4.43 does not
apply. However, an uncountable coproduct rPR Vr is a ℵ1 -filtered colimit (namely the filtered colimit
indexed by the countable subsets I € R), and
º º ¸
HomBan¤1 pC, Vr q  B1 p Vr q  t v  pvr q, vr P Vr , only countably many vr  0, |vr | ¤ 1u.
P
r R
60 CHAPTER 5. ADJUNCTIONS

Given such a pvr q, there is a countable subset I € R such that v P ²rPI Vr p€ ²rPR Vr q, and therefore
v factors over º
CÑ Vr .
P
r I

This argument can be used to show that C is ℵ1 -compact. More generally, any countably-dimensional
Banach space is ℵ1 -compact.
Definition 5.31. A category C is called κ-presentable if it has all (small) colimits and has a set(!) A €
ObjpC q consisting of κ-presentable objects such that every object is a κ-filtered colimit of objects in A.
C is called presentable if it is κ-presentable for some regular cardinal κ.
Example 5.32. ˆ The categories Set, Ab, Mon, ModR are all ℵ0 -presentable. Indeed, we can take A
to be the set of finite sets of the form t1, . . . , nu (n P N), respectively. Similarly, for ModR , say, there
is a set of modules of the form
cokerpRn Ñ Rm q,
f

for n, m P N and arbitrary maps f .


p is ℵ0 -presentable for any category C.
ˆ The category of presheaves C
ˆ The category Ban¤1 is not ℵ0 -presentable but it is ℵ1 -presentable. An indication why this might hold
is offered by Example 5.30, a full proof is in [AdamekRosicky:Locally].
ˆ By (4), the category Top is not presentable.

The following theorem, due to Adamek and Rosicky can be deduced (in a non-trivial manner) from the
adjoint functor theorem via the solution set condition.
Theorem 5.33. (Adjoint functor theorem for presentable categories) Let F : C Ñ D be a functor between
presentable categories. Then
ˆ F is a right adjoint iff it preserves limits and κ-filtered colimits for some regular cardinal κ.
ˆ F is a left adjoint iff it preserves colimits.

Example 5.34. This is a highly convenient adjoint functor theorem, it immediately produces the left
adjoints of the functors
U : Grp ÑSet
U : ModS ÑModS .
To pathological categories such as Top, it does however not apply, so the left adjoint to
U : CptHaus Ñ Top
is not ensured by this theorem, since Top is not presentable.

5.6 Exercises
Exercise 5.1. (Turning adjunctions into equivalences) Let F : C Õ
D : G be an adjunction. Let C 1 € C
be the full subcategory consisting of the objects X P C such that the unit map X Ñ GpF pX qq is an
isomorphism. Define D1 € D similarly. Show that F and G restrict to an equivalence of categories
F |C 1 : C 1 Õ D1 : G|D1 .

Exercise 5.2. Let F : C Õ D : G be an adjunction. Show that the following are equivalent:
(1) F is fully faithful,
(2) the unit map X Ñ GpF pX qq is an isomorphism for each X P C.
5.6. EXERCISES 61

Exercise 5.3. A topological space X is connected if in any disjoint decomposition


X  V1 \ V2
” either V1  H or V2  H. A topological space X is locally connected if it admits an open
of open subsets,
cover X  iPI Ui by connected spaces Ui .
ˆ Show that X is locally connected iff there is a diagram
D:J Ñ Top
with X  colim D where the Dj are connected spaces.
ˆ Show that the discrete topology functor D takes values in the full subcategory of [Link] € Top of
locally connected spaces.
ˆ Show that the functor D : Set Ñ [Link] admits a left adjoint π0 , given by taking the set of
connected components of a space.
±
ˆ Show that the space iPN t0, 1u (each factor has the discrete topology, and the whole space has the
product topology) is not locally connected. (Note: this space is a so-called profinite topological space,
these are rarely locally connected.)
We end up with a quadruple of adjunctions
π0
r D "
[Link].k U / Set
C

Exercise 5.4. (The universal property of the category of sets) Let C be a category admitting all small
colimits. Let Fun1 pSet, C q be the full subcategory of FunpSet, C q consisting of the functors F : Set Ñ C
that preserve all colimits. Show that the composite
ÞÑF ptuq
Fun1 pSet, C q € FunpSet, C q ÝÑ
F
C
is an equivalence.
This statement is referred to as saying that Set is the free cocompletion of tu (the category with a
single object and morphism). More generally, we will discuss in §8.3 that the Yoneda embedding (for a
small category C)
C€C p
exhibits as the free cocompletion of C.
Exercise 5.5. Let R be a commutative ring and M an R-module. Let S € R be a submonoid with respect
to the multiplication (also known as a multiplicatively closed nonempty subset).
Using solely the results from Exercise 4.19(1) and generalities about colimits, prove that:
(1) The localization of a flat R-module is flat. In particular, RrS 1 s is a flat R-module.
(2) M rS 1 s bR N  pM bR N qrS 1s.
Exercise 5.6. Give an example of a ring homomorphism R Ñ S where the functors S bR  (resp. HomR pS, q)
don’t preserve products (resp. coproducts), and give an example where they do.
Exercise 5.7. For a category C, the arrow category ArpC q is defined as Funpt0 Ñ 1u, C q. I.e., objects in
ArpC q are just morphisms in C (referred to here as arrows for distinction), and morphisms between arrows
are commutative squares.
Let ∆ : C Ñ ArpC q be the diagonal functor, i.e. X ÞÑ pX Ñ X q P ArpC q. Assume that C has
id

pullbacks, pushouts and a zero object, i.e., an object that is at the same time a final object and an initial
object. (For example, C  Ab).
62 CHAPTER 5. ADJUNCTIONS

Show1 that there is a chain of seven adjoints:


? %? %? %∆%? %? %?.
Hint: the rightmost and leftmost adjoints are given by sending an arrow Y Ñ Y 1 to the kernel , i.e., the
pullback 0 Y 1 Y and the cokernel , i.e., the pushout Y \Y 1 0.
Exercise 5.8. Let R Ñ S be a ring homomorphism. Adapt the proof of Corollary 5.24 to show that the
forgetful functor
ModS Ñ ModR
admits a left adjoint, denoted as  bR S.
Note: the most general tensor product functor is

A ModB  B ModC bÑ  AModC .


B

Here A ModB denotes the category of A-B-bimodules, i.e., abelian groups on which A acts from the left
and B from the right and these two actions commute. The statement in Corollary 5.24 corresponds
to A  C  Z. The statement above is also a special case, using that any (associative) ring S is an
S-S-bimodule. This functor can again be constructed using the adjoint functor theorem.
Exercise 5.9. Compute pZ{nqbZ pZ{mq by solely applying general facts about adjoints to the adjunction
in Example 5.6 (which was verified in Exercise 5.8).
Exercise 5.10. (Unicity of adjoints) Let L % R be an adjunction. Suppose that there is another functor
L1 : C Ñ D such that L1 % R is also an adjunction. Show that there is a functorial isomorphism L  L1 .
Hint: one can construct a transformation L ñ L1 by taking two appropriate transposes of idC . Alter-
natively, one can argue by showing that there is a fully faithful functor
Φ : FunpC, Dq Ñ FunpC op  D, Setq, L ÞÑ ΦpLq : ppc, dq ÞÑ HomD pLpcq, dqq.
(Functors C op  D Ñ Set are called profunctors.) Then use that ΦpLq  ΦpL1 q, since both are isomorphic
to the profunctor HomC p, Rpqq.
Exercise 5.11. Prove Lemma 5.17.
Hint: in Lemma 4.26 we showed the functoriality of limits. The limit functor constructed in this way
is a right adjoint (namely to the diagonal functor ∆ : C Ñ FunpJ, C q). Dualize that proof and replace the
functor category by an arbitrary category.
Exercise 5.12. Let
Pconv pRn q € P pRn q
be the set of all convex subsets of Rn . Regard both sets as partially ordered by inclusion and therefore as
categories (Example 2.9). Use the adjoint functor theorem to construct the convex hull as the left adjoint
of the above inclusion.
Exercise 5.13. Equip Z and R with their usual total order ¤. Describe the right and the left adjoint
of the inclusion Z € R (regarded as a functor between the categories associated to these ordered sets,
cf. Example 2.9).
Exercise 5.14. Let F : C Ñ D be a functor. Show that F admits a right adjoint if and only if the functor
HomD pF pq, Y q : C op Ñ Set is representable for every Y P D.
Exercise 5.15. Let f : X Ñ Y be a map between sets. Use Example 5.4 to explain why the preimage
functor f 1 : P pY q Ñ P pX q; U ÞÑ f 1 pU q commutes with unions and intersections and the image functor
f : P pX q Ñ P pY q; U ÞÑ f pU q only commutes with unions but not with intersections.
1 This exercise is suggested by Ben Wieland, [Link]
5.6. EXERCISES 63

Exercise 5.16. Let D be a complete poset category and R : D Ñ C be a limit preserving functor into a
locally small category C. Show that R admits a left adjoint.

Exercise 5.17. Show that the inclusion


FinSet Ñ Set
(of the category of finite sets into the category of all sets) does not admit a left adjoint nor a right adjoint.
Exercise 5.18. Let C be a category with all (small) coproducts and F : C Ñ Set a functor. Prove:
(1) if F has a left adjoint, then it is representable.
(2) if C has coproducts the converse holds: if F is representable then it has a left adjoint.
(3) Show by an example that one cannot drop the condition that C has coproducts in the second implica-
tion.
Exercise 5.19. The triangle identities also arise in so-called symmetric monoidal categories. This exercise
explores them for the category ModR , where R is a commutative ring.
An R-module M is called dualizable iff there is another R-module M 1 and two maps (in ModR )

η:RÑM bR M 1, ϵ : M 1 bR M Ñ R
(η is called the unit map (or coevaluation), ϵ is called the counit map or evaluation) such that the following
composites are the respective identities:

M1 M 1 bR R id Ñ1 bη M 1 bR M bR M 1 ϵbÑ
M id 1
R bR M 1  M 1 ,
M

η bid id bϵ
M  R bR M Ñ M bR M 1 bR M Ñ M bR R  M.
M M

(At the end, we use the canonical isomorphisms M bR R  M .) Prove the following:
ˆ Suppose R  k is a field. Show that a k-vector space V is dualizable iff it is finite-dimensional. This
provides a basis-free characterization of finite-dimensionality.
ˆ If M is dualizable, one may choose M 1 to be M  : HomR pM, Rq in the above definition.
ˆ If M is dualizable, and pM̃ 1 , η̃, ϵ̃q is another datum as above, show that there is a unique isomorphism
M 1  M 2 that is compatible with the unit and counit maps.
ˆ (Voluntary) For a general commutative ring show that M is dualizable iff M is a finitely generated
projective R-module.
°
Hint: if M is dualizable, write η p1q  ni1 mi b m1i P M bR M 1 and use these elements to factor idM
as an appropriate map M Ñ Rn Ñ M . Deduce that M is finitely generated projective.
If M is dualizable and f : M Ñ M is an R-module map, we define the trace to be the following map
trpf q : R Ñ M
η
bR M 1 f bÑid
M 1
bR M 1  M 1 bR M Ñϵ R.
M
ˆ Prove that this is well-defined, i.e., independent of the choice of pM 1 , η, ϵq.
ˆ Let f : V Ñ V be an endomorphism of a finite-dimensional vector space. Let tr1 pf qbe the trace of f
as defined in linear algebra. Show trpf q is the map k Ñ k given by multiplication with tr1 pf q.
64 CHAPTER 5. ADJUNCTIONS
Chapter 6

Abelian categories

In comparison to the wilderness of arbitrary categories, abelian categories are particularly well-behaved.
They also form the technical backbone of a number of disciplines including commutative algebra, and
homological algebra. This chapter is a brief invitation to this topic.

6.1 Definitions and examples


Recall from Exercise 4.8 that a zero object, usually denoted 0, in a category C is an object that is at the
same time initial and terminal. If C has a zero object, it is also called a pointed category. A pointed
category is called semiadditive if it admits finite coproducts and finite products and if the natural map

X \Y ÑX Y
(from the coproduct to the product) of two arbitrary objects X, Y P C, is an isomorphism. In this case
either of the two isomorphic objects is also called a biproduct and is often denoted

X ` Y.
For a semiadditive category, the set HomC pX, Y q carries the structure of an abelian monoid:
ˆ The zero morphism 0 P HomC pX, Y q is the unique morphism X Ñ 0 Ñ Y , where 0 is a zero object.
(One checks (!) that for another zero object 01 P C, the composite X Ñ 01 Ñ Y agrees with the
previous one.)

ˆ The sum f g of two morphisms f, g P HomC pX, Y q is defined as the composite


f g 
X Ñ

X  X Ñ Y  Y Ð Y \ Y Ñ Y,

where ∆ is the diagonal, the map in the middle is the above isomorphism and ∇ is the so-called
codiagonal , i.e., the unique map whose restriction to both copies of Y is idY . Again, one checks (!)
that this is independent of the choice of the products and coproducts X  X etc.

ˆ One checks the unitality, associativity and commutativity of the addition. For example, the commu-
tativity f g  g f follows from the following commutative diagram

X
∆/
X X f g
/ Y Y o
 Y \Y ∇ / Y
σ σ σ
   
X ∆/
X X g f
/ Y Y o
 Y \Y ∇ / Y.

Here σ denotes the maps that switch the two components.

65
66 CHAPTER 6. ABELIAN CATEGORIES

ˆ The category Set : tu{Set of pointed sets has a zero object, namely tu Ñ tu. It
id
Example 6.1.
is not semiadditive since the coproduct X \ Y of two pointed sets is the pushout X \tu Y (with the
two maps being the pointings of X and Y ), while the product is the regular product in Set, X  Y ,
pointed in the natural way. The natural map X \tu Y Ñ X  Y is not an isomorphism.
ˆ The category AbMon of abelian monoids (and monoid homomorphisms) is semi-additive since the
set-theoretic product X  Y of two abelian monoids, equipped with the usual monoid structure, is
both a coproduct and a product.
ˆ The category Mon of monoids (and monoid homomorphisms) is again pointed by the trivial monoid
0, but not semi-additive: the natural map
N\NÑNN
(coproduct, resp. product in Mon) is not an isomorphism. To see this, it suffices by the Yoneda lemma
(Lemma 3.6) to see that mapping out of these objects gives non-isomorphic sets. Indeed
HomMon pN \ N, M q  M  M,
while
HomMon pN  N, M q  tpm1 , m2 q P M  M, m1m2  m2m1u.
ˆ Similarly, Grp is not semiadditive, but Ab and more generally ModR is semiadditive for any ring R.
ˆ For any small category C and any abelian category A, the functor category FunpC, Aq is again abelian.
Indeed, limits and colimits are computed pointwise.
Definition 6.2. A semiadditive category C is called additive if the abelian monoid HomC pX, Y q con-
structed above is in fact an abelian group.
Definition 6.3. An additive category C is called abelian if every morphism f : X Ñ Y in C has a kernel
and a cokernel (Exercise 4.27) and if the dotted natural map (which is the unique map making the square
commute) is an isomorphism:
f p
ker f
i / X /Y / coker f (6.4)
O


coker i / ker p

Example 6.5. ˆ The category AbMon is semiadditive, but not additive and therefore not abelian.
ˆ The category Grp of groups is not semiadditive. It does have kernels and cokernels, so the condition
in Definition 7.3 makes sense. However, this condition is not satisfied: for a group homomorphism
f : X Ñ Y , the kernel ker f  tx P X, f pxq  eY u is the usual kernel. The cokernel coker f 
Y {NY pf pX qq is the quotient of Y by the normalizer of the subgroup f pX q € Y (!) . In particular, if
f is injective, the above diagram simplifies to

te X u i /X f
/Y
O
p
/ Y {NY pX q

X / NY pX q
and the bottom map is an isomorphism iff X €Y is a normal subgroup.
ˆ The category Ab and more generally ModR is abelian.
ˆ The category of Hausdorff topological abelian groups is not abelian (Exercise 7.4).
6.2. ELEMENTARY PROPERTIES OF ABELIAN CATEGORIES 67

ˆ If a category C is abelian, then C op is also abelian. Indeed, the axioms in the definition of an abelian
category are symmetric. A non-trivial fact in harmonic analysis, Pontryagin duality, establishes an
equivalence
Hom p, S 1 q : Abop  CompAb
between Abop and the category of compact Hausdorff spaces, that are also abelian groups.
The following nontrivial theorem due to Freyd shows that the last examples are prototypical. To state
it, we need another definition:
Definition 6.6. A functor C Ñ D is left exact (resp. right exact, resp. exact) if it preserves finite limits
(resp. finite colimits, resp. finite limits and finite colimits).
Example 6.7. Any left adjoint is right exact, since it preserves all colimits. Dually, any right adjoint
is left exact. The property when, in addition, a given left adjoint is also left exact, leads to interesting
notions.
For example, for a commutative ring R and any R-module M , the functor
M bR  : ModR Ñ ModR
is right exact. The module M is called flat iff it is left exact (cf. Definition and Lemma 6.17 for some
discussion).
The functors
HomR pM, q : ModR Ñ ModR , respectively HomR p, M q : ModopR Ñ ModR
are left exact. The module M is called projective (resp. injective) if the functors are exact.
Theorem 6.8. (Freyd-Mitchell embedding theorem) If C is a small abelian category, there is a (possibly
non-commutative) ring R and a fully faithful, exact functor
C Ñ ModR .
6.2 Elementary properties of abelian categories
Abelian categories have very special properties. Here is a small selection of such facts:
Lemma 6.9. Let C be an abelian category. Then any morphism f : X ÑY has a factorization
f me
with m a monomorphism and e an epimorphism. An example of such a factorization is
m  ker coker f, e  coker ker f.
This factorization has the property that for another map f 1 as in the following commutative diagram, there
is a unique morphism k making the whole diagram commutative:

X
e / Z
m / Y
g k h
  
e1 m1
X1 / Z1 / Y 1.
Proof. The existence of such a factorization follows from the definition, cf. (7.4). To show the existence
and unicity of k, consider
ker f
u /X e /Z m /Y

g k h
  
e1 m1
X1 / Z1 / Y 1.
68 CHAPTER 6. ABELIAN CATEGORIES

We claim ker f  ker e. Indeed, we have


HomC pT, ker f q  tt : T Ñ X, f  tp m  pe  tqq  0u.
Since m is a monomorphism this is equivalent to e  t  0, i.e., we get HomC pT, ker eq, so the claim follows
from the Yoneda lemma.
We have 0  hf u  m1 e1 gu, so that e1 gu  0 (m1 monic) and e1 g factors over e  coker u (using that C
is abelian), as e1 g  ke for a unique map k as displayed. Then m1 ke  m1 e1 g  hme so that m1 k  hm,
finishing the proof.
Lemma 6.10. Let f : A Ñ B be a morphism in an abelian category. Then the following are equivalent:
(1) f is a pseudo-epimorphism, i.e., for any g : B Ñ C with gf  0 we have f  0,
(2) f is an epimorphism,
(3) f is a normal epimorphism, i.e., the cokernel of some map,
 coker ker f .
(4) f is the cokernel of its kernel, f
Proof. The implications (4) ñ (3) ñ (2) ñ (1) are trivial (and hold in any pointed category).
(1) ñ (2): If two maps g, h : B Ñ C satisfy gf  hf then pg  hqf  0 by Exercise 7.1, so that g  h  0
and thus g  h.
(2) ñ (3): we have a factorzation f  m  e with m  ker coker f and e  coker ker f . Since f is an
epimorphism f  idB  f is another such factorization. By the unicity of the factorization (Lemma 7.9),
we see that f is isomorphic to m, and thus an epimorphism as well.
(3) ñ (4): Suppose f is the cokernel of a map g, as displayed:

O ? BO

q: ker f
 f
h ?A l m
g

k: coker q


There are maps h and l (making everything commutative) as indicated since f g  0 and f q  0. We
have kg  kqh  0, so that there is also a map m with mf  k. To check ml  id and lm  id we
may precompose with the epimorphisms f and k, respectively, which then holds by the construction of the
maps.
Lemma 6.11. Let
f
A /B

g h
 
C
k /D
be a pullback diagram (i.e., the natural map A Ñ B D C is an isomorphism) in an abelian category with
h an epimorphism. Then
(1) the square is a pushout square (i.e., the natural map B \A C Ñ D is an isomorphism),
(2) g is an epimorphism.
Remark 6.12. The second point asserts that epimorphisms are stable under pullback in an abelian cate-
gory. Note that by (the dual of Exercise 4.23), epimorphisms are stable under pushouts in any category.


Proof. Before embarking on the proof proper, we observe the following:
 f
g ph,kq
(1) the square is commutative
 iff the composite A Ñ B ` C Ñ D is zero. Indeed, that composite is
just hf  kg. Here : A Ñ B ` C p B  C q etc.
f
g
6.3. EXERCISES 69

(2) the square is a pullback iff
f
g
 kerph, kq. Indeed, the latter kernel is just the pullback B D C:
HompT, kerph, k qq is the set of maps f : T Ñ B ` C such that the composites T Ñ B ` C p B \ C q Ñ
f

B Ñ D and T Ñ B ` C Ñ C Ñ D agree. This agrees with HompT, B D C q.


h f k

(3) Dually, the square is a pushout iff ph, k q  coker
f
, as one proves similarly (!) .
g 
We now prove the statement proper. By the second point, we have
f
g
 kerph, kq. The map h is
an epimorphism by assumption, so that ph, k q : B` C Ñ D is an epimorphism as well. By Lemma 7.10,
it is the cokernel of its kernel, i.e., ph, k q  coker
f
, so we do have a pushout.
g
In order to show g is an epimorphism it suffices to take a map x : C Ñ E as pictured with xg  0, and
show that x  0 (Lemma 7.10). If xg  0 we have a commutative diagram like so:
f
A / B
g h
 
C k /D 0

x y

'
E
By the universal property of the pushout, we get a unique map y with yh  0. Since h is an epimorphism
this gives y  0, so that x  yk  0.

6.3 Exercises
Exercise 6.1. Suppose C is semi-additive. Let X P C and Y Ñf Z be a morphism. Show that the maps
f 
HomC pX, Y q Ñ HomC pX, Z q,
f
HomC pZ, X q Ñ HomC pY, X q
are monoid homomorphisms.
Thus, if C is additive, these maps are homomorphisms of abelian groups. One refers to this situation
by saying that an additive category is enriched over abelian groups: its Hom-sets are in fact abelian groups
and the composition maps
HomC pY, Z q  HomC pX, Y q Ñ HomC pX, Z q
are bilinear.
Exercise 6.2. Prove:
(1) Any isomorphism (in any category) is an epimorphism and a monomorphism.
(2) The converse holds in an abelian category.
(3) Show that (2) also holds in Set, but not in CRing (consider Z Ñ Q).
Exercise 6.3. State formally (and prove) the following assertion: the factorization of a morphism f in an
abelian category into an epimorphism followed by a monomorphism is functorial.
Exercise 6.4. Let C be the category of Hausdorff topological abelian groups: its objects are topological
Hausdorff spaces X equipped with a continuous map : X  X Ñ X satisfying the usual conditions on
an abelian group); its morphisms are maps that are both continuous and group homomorphisms.
70 CHAPTER 6. ABELIAN CATEGORIES

(1) Show that the category is additive.


(2) Show that the kernel of a map f : X ÑY is the usual kernel, equipped with the subspace topology.
(3) Show that the cokernel of f : X ÑY is given by Y {f pX q, the quotient by the (topological) closure of
the image f pX q.
(4) Let G be a non-discrete topological group (such as G  R). Apply Exercise 7.2 to the map id : G1 Ñ G,
where G1 is G, but equipped with the discrete topology, in order to show that the category C is not
abelian.
Chapter 7

Monads

Monads are endofunctors


T :C ÑC
equipped with a multiplication and unit map, familiar from the case of monoids. A typical example is the
functor
T : Set Ñ Set, X ÞÑ RrX s,
sending a set to the (set underlying the) free R-module (for a fixed ring R) on the set X. In this case the
multiplication of R gives rise to a “multiplication” T  T Ñ T , and the unit 1 P R gives rise to the “unit”
id Ñ T . Just as every ring R carries with it its category of modules ModR , every monad comes along
with its category of algebras, AlgT . (The name algebras is standard, but for the above monad, AlgRrs is
exactly the category of R-modules.)
Monads are closely related to adjunctions, by virtue of the following dictionary (U stands for a forgetful
functor)
% ÞÑT :RL
L R
+
adjunctionsk ÞÑFree%U monads
f .
T F
As soon as these notions are in place, one immediately checks that the composition T ÞÑ Free % U ÞÑ
U  Free is the identity. (This is indicated by the inclusion sign at the lower arrow.) Conversely, it is not
always true that for an adjunction L % R, the Free % U -adjunction for the monad T : RL is the original
adjunction. Those adjunction where this is correct are called monadic adjunctions. Understanding that
condition and identifying criteria, known as monadicity theorems, when that happens are a crucial topic
in category theory. For example, this helps tell apart the adjunctions

D : Set Õ Top : U
from
β : Set Õ CptHaus : U.
Another classical application of monadicity for (opposite) categories arises in algebraic geometry by the
name of faithfully flat descent.

7.1 Definitions and examples


Definition 7.1. Let C be a category. A monad on C is a triple pT, η, µq consisting of an endofunctor

T :C Ñ C,
a natural transformation (called the unit of the monad)

η : idC ñ T,
71
72 CHAPTER 7. MONADS

and a natural transformation (called multiplication)


µ:T T ñT
(between functors from C to C), such that the following diagrams are commutative:

T  T  T T pµq /T T T
ηT
/ T T
µT µ Tη µ
   
T T µ
/T T T µ
/ T.

Example 7.2. Let R be a ring. We define a monad on the category of sets as follows: T : Set Ñ Set sends
a set X to the free R-module generated by X regarded as a set (i.e., we forget that it is an R-module),
i.e., à
T pX q  R.
P
x X

For x P X, we will consistently denote by ex  p. . . , 0, 1, 0, . . . q the basis vector with the 1 at the spot
corresponding to x. For a map f : X Ñ Y , T pX q Ñ T pY q is then the map sending ex to ef pxq (and R-
linearly extending; note though that T pf q is just a map of sets). This is a monad: the unit map X Ñ T pX q
sends x P X to ex To define the multiplication map, it is useful to notice that
T pX q  U FreepX q,

Õ Mod
where
Free : Set R :U
is the free-forgetful adjunction. Now, the map
T T pX q  U FreepU FreepX qq Ñ T pX q  U FreepX q
is defined to be the underlying map of sets associated to the map
FreepU FreepX qq Ñ FreepX q
of R-modules, which reads à
R Ñ FreepX q.
P
t U Free X p q
°
Let t  rx x be À an element of U FreepX q. Then the multiplication map sends et pP FreepU FreepX qq to
t P FreepX q  sPX R. This shows that the structure of the adjunction gives rise to the monad data.
We will revisit this for an abstract adjunction and verify the unitality and associativity condition for such
more general mondas below.
Lemma 7.3. Let L : C Õ D : R be an adjunction. Then the functor
T : R  L : C ÑC
is a monad, whose unit η : id ÑT is the unit of the adjunction and whose multiplication is (essentially)
given by the counit:
µ:T  T  RLRL RϵL
Ñ RL  T.
Proof. This is a consequence of the triangle identities. For example,
ηRL
RL / RLRL
RLη µ
 
RLRL
RϵL / RL,
7.1. DEFINITIONS AND EXAMPLES 73

so the commutativity of the lower left triangle is the triangle identity ϵL  Lη  idL (and applying R).
The associativity follows from naturality of the counit map as follows: since the counit ϵ is natural, we
get for any map f : X Ñ Y in D a commutative diagram
LRf
LRX / LRY
ϵX ϵY
 f 
X / Y.
Applying this to f  ϵY : LRY Ñ Y , this reads
LRpLRqY
LRϵY
/ LRY
ϵLRY ϵY
 ϵY 
LRY / Y.
Picking finally Y  LA for some A P C and also applying R, we obtain the desired commutative square
expressing the associativity condition:

RLRpLRqpLAq RLRpLAq
RLRϵLA
/ (7.4)
RϵLRLA RϵLA
 
RLRpLAq
RϵLA
/ RLA.

Example 7.5. Let R be a commutative ring. The adjunction


HomR p, Rq : Modop
R Õ Mod R : HomR p, Rq
gives rise to a monad on ModR , known as the bidualization monad :
ModR Ñ ModR , M ÞÑ M p: HomR pHomR pM, Rq, Rqq.
The unit map is the usual map
M Ñ M , m ÞÑ pf ÞÑ f pmqq.
Example 7.6. The power set functor
P : Set Ñ Set
defined by X ÞÑ P pX q, and f : X Ñ Y to the map P pX q Ñ P pY q, pX qU ÞÑ f pU qp€ Y q. This functor
is a monad, called the power set monad : the unit map is given by
ηX : X Ñ P pX q, x ÞÑ txu.
The multiplication map
µX : P pP pX qq Ñ P pX q
”
sends a subset of A € P pX q, i.e., a set Ua € X (indexed by the set A) of subsets of X, to P Ua . These
are indeed natural transformations, e.g., for f : X Ñ Y , this expresses
a A


¤ ¤
f pUa q  f Ua .
P
a A a A P
The conditions on a monad can be painfully verified by hand or alternatively by using the fact that there

Õ
is an adjunction
P pq : Set complete sup-lattices : U.
Here at the right we have the category of posets having suprema (i.e., colimits!), and suprema-preserving
(i.e., colimit-preserving) functors.
74 CHAPTER 7. MONADS

7.2 Algebras over a monad


Definition 7.7. Let T : C Ñ C be a monad. The category of T -algebras (a.k.a. the Eilenberg-Moore
category) AlgT is the following. Objects are pairs pA, αq with A P C and α : T pAq Ñ A a morphism in C
such that the two diagrams commute:

T pAq T pT pAqq pAq


ηA
A / Tα /T

α µA α
  
T pAq /
α
A A.

Morphisms in AlgT are morphisms f : A Ñ A1 such that the following square commutes:

T A1 .
Tf
TA /

α α1
 
A
f
/ A1

These conditions look familiar from the definition of an R-module M . Indeed, this is no coincidende:
Example 7.8. Let T : Set Ñ Set be the monad associated to the free-forgetful adjunction associated to
À the notion of a T -algebra. Let pA, αq be such an algebra, i.e., A P Set.
a ring R, as above. We unwind
Given the map α : T pAq  xPA R Ñ A we define the scalar multiplication by R as the map
R  A Ñ A, pr, xq ÞÑ αprex q,
where ex P T pAq is the basis vector for x P A. The diagram
x ÞÑe/ xÀ
A x A P R
α

A
then means 1R  x  x. The commutativity of

T pT pAqq / T pAq

µA α
 
T pAq / A.
α

is equivalent to the associtavity of the R-multiplication on A (!) . We also define the addition on A as
A  A Ñ A, px, y q ÞÑ αpex e y q.
It is a further routine check to verify the remaining conditions for being an R-module, such as distributivity
etc.
Definition and Lemma 7.9. Let T : C Ñ C be a monad. Then the forgetful functor
U : AlgT pC q Ñ C, pX, αq ÞÑ X
admits a left adjoint, denoted Free, and called the free T -algebra functor . It sends X P C to
pT X, µX : T pT X q Ñ T X q.
A T -algebra of this form is called a free T -algebra. The full subcategory of AlgT consisting of free T -algebras
is called the Kleisli category.
7.3. MONADIC ADJUNCTIONS 75

Proof. It is routine to check the functoriality of Free. To show it is an adjunction observe that a map

g : pT X, µX q Ñ pA, αq

yields by composition with the map ηX : X Ñ T X a map


X Ñ T X Ñ A.
η X g

Conversely, a map f : X Ñ A gives rise to a map


TX Ñ
Tf
T A Ñ A.
α

One checks that this map is a map of T -algebras. One further checks that these two constructions are
indeed inverse to each other: for example, given a map g as above, we need to check that α  T g  T ηX is
the original map g, which results from the commutativity of the following diagram.
T ηX Tg
TX / TTX / TA
µ α
 g 
TX / A.
The left triangle is the unitality condition for T and the right one is part of α being a morphism of
T -algebras.

7.3 Monadic adjunctions


So far, we have established a dictionary:
ˆ a monad T : C Ñ C gives rise to an adjunction
Free : C Õ Alg pC q : U.
T

ˆ an adjunction
L:C ÕD:R (7.10)
gives rise to a monad
T : RL : C Ñ C.
If we start with a monad T , then the monad associated to the free-forgetful adjunction gives back the same
monad. This follows directly from the definition of the free algebra functor.
In order to adress the converse question we use the following notion:
Definition and Lemma 7.11. Let L % R be an adjunction as in (6.10). Then R factors as

D ÑR̃ AlgT pC q Ñ
U
C,

where R̃pdq is Rpdq, equipped with the T -action given by

T pRpdqq  RLRpdq Ñ Rpdq.


Rϵd

The adjunction is called a monadic adjunction if the functor R̃ is an equivalence of categories.

Proof. One checks that the map Rϵd indeed does define a T -algebra structure on Rpdq, as in (6.4) (replace
LA there by d)(!) .
76 CHAPTER 7. MONADS

Example 7.12. ˆ Let R Ñ S be a ring homomorphism. The adjunction


S bR  : ModR Õ Mod S : F orget (7.13)
is a monadic adjunction. Indeed, the monad T : ModR Ñ ModR sends M ÞÑ S bR M (regarded as an
R-module). A T -algebra is then an R-module M with a R-linear map
T pM q  S bR M Ñ M.
By the tensor-Hom-adjunction this is the same as an R-linear map M Ñ HomR pS, M q, or, yet
equivalently, an R-bilinear map S  M Ñ M . This map can be used to define the S-action on M :
ps, mq ÞÑ s  m. This indeed defines an S-module structure, as follows from inspecting the definition
of a T -algebra.
ˆ We have already seen above that the adjunction
Rrs : Set Õ Mod R :U
is monadic.
ˆ By similar arguments, the adjunction
Free : Set Õ Grp : U
is also monadic, as we will see in Exercise 6.4.
ˆ The discrete-forgetful adjunction
D : Set Õ Top : U
(D puts the discrete topology on a set, U forgets the topology) is not monadic: the associated monad
T  U D is the identity functor on Set, so that the factorization in Definition and Lemma 6.11 reads

Top Ñ AlgT pSetq  Set Ñ Set.


Ũ U

In particular, Ũ fails to be an equivalence.


A more general, abstract necessary condition to be monadic is supplied by the following lemma. It again
shows that the above adjunction is not monadic: R is not conservative (there are continuous bijective maps
that fail to be homeomorphisms).
Lemma 7.14. For a monad T on a category C, the forgetful functor U : AlgT pC q Ñ C is conservative.
Proof. Given a T -algebra map f : A Ñ A1 that is an isomorphism in C, say with inverse g  U pf q1 : f 1,
we claim that g is naturally a T -algebra map. Indeed, consider the following diagram (in C):
α1
T A1 / A1
Tg g
 
TA
α / A
T f,  f, 
 
α1
T A1 / A1 .
The bottom square commutes since f is an algebra map. The two vertical composites are the identities
since T is functorial. Thus the outer square commutes. The two bottom vertical maps are isomorphisms.
Therefore the top square commutes. The unitality condition for g is checked similarly.
Corollary 7.15. If L % R is a monadic adjunction, then R is conservative.
Proof. Indeed, both the equivalence R̃ and the forgetful functor AlgT pC q Ñ C are conservative.
7.4. MONADICITY THEOREMS 77

7.4 Monadicity theorems


Monadicity theorems give sufficient (and, in some cases, necessary) conditions for an adjunction to be
monadic. The following theorem is known as the “crude” monadicity theorem, due to Beck in the 1960’s.
Recall from Remark 4.46 that a reflexive coequalizer is a colimit of shape
f
/
1` / 0
g
σ

(two objects, three non-identity morphisms and f  σ  g  σ  id0 .) This is the full subcategory of ∆
(Example 4.56) consisting of the objects r0s and r1s. Its non-full subcategory
f
/
1 / 0
g

is a cofinal subcategory. In particular a reflexive coequalizer can be computed as the coequalizer of the
diagram obtained by omitting the σ.
Theorem 7.16. (Crude monadicity theorem) Let L : C Õ D : R be an adjunction. Suppose
(1) D admits and R preserves reflexive coequalizers,
(2) R is conservative.
Then the adjunction is a monadic adjunction.

Before proving the theorem, we explore its reach by means of several examples. First, the theorem
shows (again) that the tensor-forgetful adjunction is monadic (cf. Example 6.12): the forgetful functor is
conservative and preserves all colimits by virtue of having a right adjoint, HomS pR, q, cf. Example 5.6.
Let R Ñ S be a ring homomorphism of commutative rings. Passing to the opposite categories in (6.13),
we obtain an adjunction
F orgetop : pModS qop Õ
pModR qop : pS bR qop.
Let us examine whether it is monadic (or, in common terminology, the adjunction (6.13) is comonadic).
For any R, Modop
R admits even all colimits, since ModR admits all limits.

Definition and Lemma 7.17. In the above situation, the following are equivalent. In this event, S is
called a flat R-algebra.
(1) S bR  preserves finite limits,
(2) S bR  preserves equalizers,
(3) S bR  preserves kernels, i.e., for any map f : M Ñ N of R-modules, we have
kerpS bR M ÝÑb S bR N q  S bR ker f.
idS f

(4) S bR  preserves injective maps, i.e., if f : M Ñ N is an injective map of R-modules, then idS b f :
S bR M Ñ S bR N is also injective.

Proof. Clearly (1) ñ (2). Conversely, being a left adjoint the functor always preserves coproducts, hence
finite products (ModR is additive). Then use Proposition 4.32.
We have (2) ô (3) since an equalizer of a diagram M Ñ N is also the equalizer of the diagram M Ñ N ,
f

g
f g

0
i.e., the kernel of f .
For (3) ô (4) note that in ModR , a map f is a monomorphism iff it is injective. Then ñ follows since
p3q
f is injective iff ker f  0 ñ kerpidS b f q  0 iff idS b f is injective. Conversely, any monomorphism is
the kernel of a map (in fact, the kernel of its cokernel) by (the dualized version of) Lemma 7.10.
78 CHAPTER 7. MONADS

Definition and Lemma 7.18. Let S be a flat R-algebra. Then, the following are equivalent. In this
event, S is called a faithfully flat R-algebra.
(1) S bR  is conservative,
(2) For M P ModR , we have S bR M  0 ñ M  0.
Proof. Indeed, M  0 iff 0 : M Ñ M is an isomorphism. Conversely, for f : M Ñ N , f is an isomorphism
iff ker f and coker f are zero. By flatness, tensoring preserves the kernel (and always preserves colimits
such as the cokernel). Thus S bR pker f q  kerpS b f q  0 implies ker f  0 etc.

À 7.19. ˆ For any commutative ring R, the map R Ñ Rrts is faithfully flat: Rrts bR M
Example 
n¥0 M (as an R-module). This functor preserves injections and is conservative.

ˆ The map Z Ñ Q is flat (either by inspection or alternatively using Exercise 5.5), but not faithfully
flat:
Q bZ Z{p  Q{p  0.

ˆ The unique ring homomorphism Rrts Ñ R satisfying t ÞÑ 0 is not flat: we have


t
0  kerpRrts Ñ Rrtsq,

and after applying R bRrts , we obtain the map


0
R Ñ R,

whose kernel is
R  kerpR Ñ Rq,
0

so that Rrts bR  does not preserve kernels.

Corollary 7.20. Suppose S is faithfully flat. Then the adjunction

F orgetop : pModS qop Õ pMod qR


op
: pS bR qop

is monadic.

Remark 7.21. The resulting equivalence

pModS qop  AlgT pModopR q,


is much used in algebraic geometry under the name of faithfully flat descent, see for example [StacksProject]
or [Deligne:Categories]. One also refers to it by stating it as an equivalence

ModS  CoAlgT pModR q,


where the definition of a comonad , and coalgebras over a comonad are obtained by reversing all arrows in
the definition of a monad and its algebras.

Remark 7.22. The condition that S is faithfully flat not quite necessary for the adjunction to be comonadic.
See [JanelidzeTholen:FacetsIII] for a necessary and sufficient condition.

We prepare for the proof of the crude monadicity theorem. For a ring R and an R-module M , the
natural map à ¸ ¸
R Ñ M, rm em ÞÑ rm  m
P
m M P
m M P
m M

is surjective. A massive generalization of this fact, and also a description of the relations in RrM s is
provided by the following lemma.
7.4. MONADICITY THEOREMS 79

Lemma 7.23. Let T : C Ñ C be a monad and pA, α : T A Ñ Aq P AlgT . Then the following is a reflexive
coequalizer diagram in AlgT :
p q
T pT pAqqi T pAq pA, αq.
T α
/ α /
/
µA
p q
T ηA

Here, T pX q denotes the free T -algebra (previously denoted FreepX q) on an object X P C. If we forget the
T -algebra structures on all objects, the diagram is a reflexive coequalizer diagram in C.
Proof. First off, T ηA is indeed a splitting by the unitality of the T -algebra pA, αq and the unitality condition
for the monad T . For a cocone B P AlgT as depicted, we want to exhibit a unique dotted T -algebra map
g in the following diagram:
p q
T pT pAqq pAq
T α
/ α /
/T A
µA
f
Tg g
 " 
T pB q
β
/ B.

We momentarily regard the right triangle as a diagram in C (as opposed to AlgT ). The map g : f  ηA
makes the right triangle commute. Moreover, this is the unique map with this property since α  ηA  idA .
This directly shows the final coequalizer claim in C. (Alternatively, this also follows from the argument in
Example 6.27 below.) For pA, αq to be a coequalizer in AlgT , we need to still argue as follows: since the
forgetful functor AlgT Ñ C is faithful (but not full!), it remains to see that g is indeed a T -algebra map,
i.e., the commutativity of the lower right square. We prove this using that f is a T -algebra map (*), the
monad axioms of T (**) and the naturality of η (***):

β  T g : β  T f  T ηA pq
 f  µA  T pηAq pq
 f pq
 f  T pαq  ηT A pq
 pf  ηAq  α : g  α.
Proof. (of Theorem 6.16) We have a factorization of R as

D ÑR̃ AlgT Ñ
U
C
and our goal is to show that R̃ is an equivalence. Our proof is in three steps:
(1) we construct a left adjoint L̃ to R̃,
(2) we show the unit map idAlgTÑ R̃  L̃ is a (functorial) isomorphism,
(3) we show that the counit map L̃  R̃ Ñ idD is a (functorial) isomorphism.
(1): if this left adjoint exists, it must satisfy
L  L̃  Free  L̃  T,
by Lemma 5.11. I.e., L̃pT pX qq needs to be (isomorphic to) LpX q. In addition, L̃ would need to preserve
colimits such as the coequalizer in Lemma 6.23. We therefore define, for any algebra pA, αq, L̃pAq to fit
into the following reflexive coequalizer diagram (in D):
p q
LpT pAqq LpAq L̃pA, αq.
L α
/ θ /
/ (7.24)
i ϵLA
LηA

(Here ϵLA is the evaluation of the counit ϵ : LR Ñ idD at LA P D). The coequalizer, L̃pA, αq, exists by
assumption on D. In order to check L̃ is a left adjoint to R̃, it suffices to exhibit a bijection
HomD pL̃pA, αq, B q  HomAlgT ppA, αq, R̃pB qq
pq
functorially in B P AlgT (Lemma 5.17). Indeed the left hand Hom is tf : LpAq Ñ B, f  Lpαq  f  ϵLpAq u.
The condition (*) is equivalent to the commutativity of the left hand diagram, which in its turn is equivalent
80 CHAPTER 7. MONADS

to the commutativity of the diagram at the right, which is obtained by passing to transposes (f t denotes
the transpose of t):
LT A  LRLA / /
Lα α
LA RLA A
ϵLA f ft
 f  Rf 
LA / B RLA / RB.

By definition of the counit map and the transpose, we have a commutative diagram
L ft p q/
LA LRB
f
ϵB
# 
B.

Thus, condition (*) is equivalent to f t  α  RpϵB qRpLpf t qq. Thus the above Hom-set is the same as a
map of algebras
f t : pA, αq Ñ R̃pB q  pRB, RϵB q.
(2): we apply R to (6.24). By assumption on R, this yields a coequalizer diagram
p q pq
RLpT pAqq RLpAq
RL α
/ R θ
/ RL̃A.
/ (7.25)
RϵLA

Note that RLT  T 2 . We also have the free resolution coequalizer (Lemma 6.23), which we at this point
regard as a coequalizer in C (as opposed to AlgT )
p q
T pT pAqq T pAq
RL α
/ α /
/ A.

µA RϵLA

Thus there is a (unique) isomorphism fitting into the following commutative diagram:

RLA Rθ /
RL̃pA, αq
α

% 
A.

Henceforth we will identify A with RL̃pA, αq using this isomorphism.


In order to complete our claim, we need to show that the T -algebra structures on RL̃pA, αq and on A
agree, i.e., RϵL̃pA,αq  α. Since α  Rθ, our claim follows from the following computation, where we use
the unitality condition of the T -algebra pA, αq (a), the definition of θ as a coequalizer in (6.24) (b), and
the naturality of ϵ (c) and, in (d), the unitality of the T -algebra RL̃pA, αq:
paq
θ  θ  Lα  LηA pbq θ  ϵLA  LηA pcq ϵL̃pA,αq  LRpθq  LηA pdq ϵL̃pA,αq.
(3): Applying the definition of L̃ in (6.24) to A  R̃pB q, we get the following reflexive coequalizer
diagram:
pB q L̃R̃pB q
LRϵB
/ θ /
LRLRB
g / LR
ϵLRB
LηRB τ
ϵB
% 
B.
The dotted map τ exists by the universal property of the colimit, noting that ϵB  LRϵB and ϵB  ϵLRB are
both transposes of RϵB , and therefore agree. The map LηRB is a splitting of the two maps by the triangle
7.4. MONADICITY THEOREMS 81

identities. By assumption on R, applying R, we still have a (reflexive) coequalizer diagram:

RLRpB q pB q
RLRϵB
/ Rθ / RL̃R̃
RLRLRB /
RϵLRB
RϵB

& 
RB.
The two parallel maps and RϵB also form a coequalizer by Lemma 6.23. Thus, Rτ is an isomorphism. By
assumption on R, τ is therefore an isomorphism as well.

The above “crude” monadicity is not quite necessary, but we have done almost all the work to get a
necessary (and sufficient) condition for an adjunction to be monadic.
Definition and Lemma 7.26. A split coequalizer diagram in a category C is a diagram of shape
f
/ e /
Aa / Bb C,
g
t s

with ef  eg and the “wrong way maps” satisfy es  idC , se  gt and f t  idB .
For such a diagram, C (together with the map e) indeed is a coequalizer of pf, g q. Any functor preserves
split coequalizer diagrams. (A colimit that is preserved by any functor is called an absolute colimit.)

Proof. Any map k : B Ñ K such that k  f  k  g factors over e:


k  kf t  kgt  kse.

Example 7.27. Revisiting Lemma 6.23, we note that for a monad T : C Ñ C, and a T -algebra, the
diagram is a split coequalizer diagram in C

T pT pAqqi T pAqg
µA
/ α /
/ A.

ηT A ηA

(Parallely the diagram is also a reflexive coequalizer diagram in AlgT , but not a split coequalizer diagram
in AlgT : the map ηT A is not a map of T -algebras.)

Theorem 7.28. (Precise monadicity theorem) An adjunction L % R is monadic if and only if


ˆ D admits and R preserves coequalizers of R-split pairs. By this we mean that for any pair of maps
X Ñ Y in D such that RX Ñ RY can be extended to a split coequalizer diagram (in C), then the
f

g
Rf

Rg
original diagram admits a colimit, and R preserves that colimit.
ˆ R is conservative.

This can be proven along the same lines as the crude monadicity theorem above.

Õ CptHaus : U
Corollary 7.29. The adjunction
β : Set
is monadic.

Proof. For the proof, we use that a topological space is the same as a set X and a map (the closure)
 : P X Ñ P X such that
H  H, S Y T  S Y T , S € S, S  S.
A continous map is a map such that f pS q € f pS q.
82 CHAPTER 7. MONADS

Let X, Y P CptHaus, f and g be continuous maps such that for the underlying sets, there is a split
coequalizer diagram:
f
/ e /
Xa / Yb W,
g
t s

We can apply the covariant power set functor (Example 6.6). Since split coequalizer diagrams are preserved
by any functor, the rows are still coequalizers. The maps f and g are continuous and, being maps between
compact Hausdorff spaces, necessarily closed maps. Thus, the left square commutes, so that there is a
unique map (of sets), ? as depicted at the right:
Pf
/ Pe /
PX / PY PW (7.30)
Pg
? ? ?
 Pf  
/ Pe /
PX / PY PW
Pg

Note that for T € W , T  epe1 T q. Using this, it is trivial to check that the four conditions on the closure
are satisfied. Thus, W is a topological space, and the map e is continuous. What is more, a subset T € W
is closed iff e1 pT q € Y is closed (since in the latter case T  epe1 pT qq is closed by the commutativity of
the right half in (6.30)). Thus, the topology on W is the quotient topology.
Since Y is compact, and e is surjective, W is also compact. Let w1  w2 P W be distinct points. We
have spw1 q  spw2 q P Y (since es  idW ), so there are open disjoint neighborhoods Ui Q spwi q in Y .
Their complements Zi : Y zUi are closed and cover Y . The map e is closed since the right part in (6.30)
commutes. Thus epZi q are closed, and cover W  epY q. Their complements W zepZi q are thus disjoint
open neighborhoods of wi , so that W is Hausdorff.
We finally check that the compact Hausdorff space W is indeed a coequalizer. Let h : Y Ñ Z be a
continuous map with hf  hg. Since W is a coequalizer in Set, h factors over e: h  h1 e. Since W carries
the quotient topology, h1 is continuous as soon as h is.

Remark 7.31. The above statement leads to the question of describing the monad associated to the
adjunction β % U more concretely. One can show (without much difficulty) that the monad is the so-
called ultrafilter monad 1
T : Set Ñ Set, X ÞÑ tultrafilters on X u.
Note that the following diagram commutes:

FinSet / CptHaus  AlgT


ι U
 
Set Set.
Note that ι is not part of an adjunction (Exercise 5.17). Nonetheless, one can associate a monad to
this inclusion, called the codensity monad , which happens to be the ultrafilter monad. This leads to a
characterization of compact Hausdorff spaces in completely categorical terms: one can show (again without
much difficulty) that it is the initial monadic adjunction over Set fitting into a diagram like so:

FinSet /C

ι R
 
Set Set.
See [Leinster:Codensity] for an exposition of these ideas.
1 An
ultrafilter on a set X is a collection of subsets V € X that is upwards closed and stable under intersection, and for any subset W € X
z
either W or X W (but not both) are in the collection.
7.5. EXERCISES 83

This understanding of CptHaus can also be used to prove Riesz’ representation theorem [Hartig:Riesz],
stating that for any compact Hausdorff space X, there is a (functorial!) isomorphism (of Banach spaces)
»
M pX q Ñ C pX q , µ ÞÑ pf ÞÑ f dµq
X

between the space of measures on X and the dual space of the space of continuous, real-valued functions
on X. The basic idea in this categorical proof is to observe that it is enough to prove this for projective
T -algebras (which are classically known as extremally disconnected spaces), i.e., retracts of algebras of the
form β pX q, for X P Set. For these, one checks the result by an immediate inspection.
Finally, extremally disconnected spaces play an outsize rôle in Clausen–Scholze’s foundational work on
condensed mathematics [Scholze:Lectures].

7.5 Exercises
Exercise 7.1. Let T : C Ñ C be a monad on a category. Show that the Kleisli category for T is equivalent
to the category D with ObjpDq  ObjpC q and with morphisms given by
HomD pX, Y q : HomC pX, T pY qq

and an appropriate composition.


Exercise 7.2. Let Set be the category of pointed sets, i.e., pairs pX, xq with a so-called base-point x P X
and maps preserving the base point. (More succinctly, the category can be defined as a comma category:
Set : tu{Set.)
(1) Show that the forgetful functor U : Set Ñ Set has a left adjoint L.
(2) Show that the adjunction L % U is monadic.
(3) Let T : U L be the monad associated to the adjunction. Show that the Kleisli category of T is
equivalent to the category Setpart of sets with partial maps, i.e.,
HomSetpart pX, Y q  tX 1 € X, f P HomSetpX 1, Y qu.
Exercise 7.3. Imitate the proof of Theorem 6.16 to show Theorem 6.28.

Exercise 7.4. Apply Theorem 6.28 to show that the free-forgetful adjunction
Free : Set Õ Grp : U
is monadic.
Hint: assume that G Ñ H is a parallel pair of arrows that is split in sets (as in Definition and
f

Lemma 6.26). Show that G  G Ñ H  H is also part of a U -split coequalizer diagram. Then mimic the
 f f

 g g
situation in (6.30), with the group operation G  G Ñ G instead of the closure operator.
84 CHAPTER 7. MONADS
Chapter 8

Kan extensions

Given a functor F : C Ñ C 1 and some category E, there is an obvious functor


F  : FunpC 1 , E q Ñ FunpC, E q, H ÞÑ H  F.
Kan extensions, more precisely left Kan extensions and right Kan extensions are a way to go backwards:
given a functor G : C Ñ E, they produce (under certain conditions) two functors
LanF pGq, RanF pGq : C 1 Ñ E.
We will depict this situation by
C
G /
>E
F
 LanF G,RanF G
C 1.
The precise condition how these functors LanF G and RanF G are related to G is given by an adjunction:
Definition 8.1. A left Kan extension of G along F , denoted by LanF pGq (dually, a right Kan extension,
RanF pGq) is a functor C 1 Ñ E, i.e., an object in FunpC 1 , E q, such that there is a functorial isomorphism
HomFunpC 1 ,E q pLanF pGq, q  HomFunpC,E q pG, F  q,
(respectively,
HomFunpC 1 ,E q p, RanF pGqq  HomFunpC,E q pF  , Gq.q
Example 8.2. Let f : Q Ñ R be a monotone function (i.e., f pxq ¤ f py q for x ¤ y). We regard f as a
functor, by regarding Q and R as posets (and therefore categories) via the usual relation ¤. Then the
supremum sups¤x,sPQ f psq exists for each x P R (using that R is complete, and since the f psq are bounded
by f ptq for some t P Q, t ¥ x), then the function
f : R Ñ R, x ÞÑ sup f psq
¤
s x

is a left Kan extension of f along the inclusion Q € R. (Dually, x ÞÑ inf s¥x f psq is a right Kan extension.)
Indeed, given a monotone function h : R Ñ R, HomFunpQ,Rq pf, h|Q q is a singleton iff f psq ¤ hpsq for each
s P Q, and is empty otherwise. The former is equivalent to
f pxq  sup f psq ¤ hpxq
¤
s x

for each x P R. Then, ñ follows by taking sup, and ð follows by taking x  s.


A middle-school application of this procedure is the construction of the exponential function, for a ¥ 1
f pxq : ax : R Ñ R, x ÞÑ ax ,
which can be defined as ax : sups¤x as , provided that powers with rational exponents are already defined.
(For this particular function f , right and left Kan extension happen to agree, which is unusual for general
Kan extensions.)

85
86 CHAPTER 8. KAN EXTENSIONS

This example indicates that (right or left) Kan extensions need not exist. We will prove (Proposi-
tion 8.15) that left Kan extensions (along a functor between small categories) do exist as soon as the
target category E is cocomplete. We will use Kan extensions to formulate (and prove) the universal
property of the category C p  PShpC q of presheaves: it is the free cocompletion (Theorem 8.20). This
cocompletion is also useful in order to construct free completions for more restrictive colimits, notably the
Ind-completion, which freely adds filtered colimits.
Another prominent application of Kan extensions are derived functors. For example, the functor
Fp bZ  : Ab Ñ ModFp
which is right exact, but not left exact admits a so-called left derived functor, which measures the deviation
of this functor to be left exact (and therefore exact). This left derived tensor product is the right Kan
extension in the following diagram:
b
ChpAbq pModF q
Fp
/ Ch
p

c c
 bLZ  
DpAbq pModF q.
Fp
/D
p

Here Ch denotes the category of chain complexes, and D the so-called derived category, which is the category
of chain complexes with quasi-isomorphisms inverted. See [Mac98, §X.4] for a glimpse or [KahnMaltsiniotis:Stru
for a full-fledged exposition in greater generality.
Remark 8.3. The name Kan extension may suggest the idea
LanF G  F  G.
This statement holds true if F is fully faithful (Corollary 8.19), but not necessarily otherwise: Kan exten-
sions along C Ñ tu are (co)limits, so that, in particular, the triangle does not commute, unless G is a
constant functor.
C G />E


F

LanF G colim G,RanF G lim G 
tu
Indeed, functors tu Ñ E are just objects in e and the functor F  : E Ñ FunpC, E q is simply the diagonal
functor previously denoted ∆, so the claim follows from Lemma 5.10.

8.1 (Co)ends
Our construction of right Kan extensions below will be based on ends (resp. coends for left Kan extensions).
These are special limits (resp. colimits) over the twisted arrow category, all of which we introduce in this
section.
Definition 8.4. Let C be a small category. Define the subdivision category C § to have as objects symbols
c§ and f § , for each object c P Objpcq and each morphism f : c Ñ c1 in C. (By definition, c§  pidc q§ .) By
definition, any morphism in this category is a composition of identity morphisms of these objects, together
with morphisms of the form
c§ Ñ f § , c1§ Ñ f § (8.5)
for each f : c Ñ c1 .
There is a natural functor
Ñ C op  C,
ι : C§
given on objects by c§ ÞÑ pc, cq, pf : c Ñ c1 q ÞÑ pc, c1 q and on morphisms in the expected way: c§ Ñ f § is
mapped to pidc , f q, and c1§ Ñ f § is mapped to pf, idc1 q.
8.1. (CO)ENDS 87

Definition 8.6. Let F : C op  C Ñ D be a functor. An end (resp. coend ) of F is a limit (resp. colimit)
of the composition
Ñι C op  C Ñ F
C§D.
³ ³c
An end is denoted by c F pc, cq, and a coend by F pc, cq.
³
Concretely, this means that the end c F pc, cq is an object d P D together with maps
rc : d Ñ F pc, cq, rf : d Ñ F pc, c1 q
(for each f : c Ñ c1 in C) such that the diagram

d1 / F pc, cq
;
rc F c,f p q
 * %
d
rf
/F
9
pc, c1q
rc1 p q
F f,c

# 
F pc1 , c1 q.

commutes. Moreover, for any other object d1 with the same properties, there is a unique map d1 Ñd
making the whole diagram commutative.
Equivalently, an end can be computed as an equalizer
» 
¹ ¹
F pc, cq  eq F pc, cq Ñ F pc, c1 q , (8.7)
c P
c C f :c Ñ c1
where for each morphism f : c Ñ c1 , the two maps are given by
± p q
F pc, cq Ñ F pc, cq
Ñ F pc, c1 q,
F c,f
ˆ c
± F pf,c1 q
ˆ c F pc, cq Ñ F pc1 , c1 q Ñ F pc, c1 q.
Remark 8.8. The above definition of C § is somewhat ad hoc. A slightly more conceptual approach is to
define the twisted arrow category TwpC q to be the category whose objects are the morphisms in C. For
two morphisms f : A Ñ A1 , g : B Ñ B 1 in C (i.e., objects in TwpC q, we define HomTwpC q pf, g q to be the
set of commutative squares
Ao h B (8.9)
f g
 
A1 k / B1.
(Note the arrow h goes in the “wrong” direction.) The functor ι above factors as a composite
C§ Ñ TwpC q Ñ C op  C,
the former functor being given by c§ ÞÑ idc, and morphisms in (8.5) are mapped to
c1 o f
c , co idc
c . (8.10)
id1c f idc f

 id1c  
/ c1
c1 c1
f
/ c

The second functor is given on objects by pf : c Ñ c1 q Ñ pc, c1 q.


One checks that the (co)limit of the composite

C§ Ñ TwpC q Ñ C op  C Ñ
F
D
88 CHAPTER 8. KAN EXTENSIONS

and the (co)limit of


TwpC q Ñ C op  C Ñ
F
D
are isomorphic, see e.g. [Richter:Categories]. Thus, (co)ends can be defined, somewhat less ad hoc, in
the latter way.

Example 8.11. Let A, B P FunpC, Dq be two functors, where C is small. Consider the functor
F : C op  C

Ñ
A B
Dop  D
HomD
Ñp,q Set, pc, c1q ÞÑ HomD pApcq, B pc1qq.
The end of this functor recovers the set of natural transformations between A and B:
» »
F pc, cq  HomD pApcq, B pcqq  HomFunpC,Dq pA, B q. (8.12)
c c

Indeed, a morphism α : A Ñ B is a collection of elements in αc P HomD pApcq, B pcqq  F pc, cq, subject to
the condition that the diagrams
p q/
Apcq Apc1 q
A f

αc αc 1
 p q/ 
B pcq B p c1 q
B f

commutes. This is precisely the content of the equalizer in (8.7).

In the sequel, we will often have to talk about cocontinuous functors, i.e., colimit-preserving functors,
so we introduce a notation:

Definition 8.13. Let I be a small category and C a cocomplete category. Then Func pI, C q is the full
subcategory of the functor category FunpI, C q consisting of functors preserving all (existing) colimits.

Let E be a category with all (small) coproducts. Recall that by Exercise 5.18 the representable functor
HomE pe, q : E Ñ Set admits a left adjoint, denoted  b e, given on objects by
º
s b e : e,
Ps
a coproduct indexed by the elements of the set s P Set. Being a left adjoint, this functor  b e preserves
colimits, and is thus an object in Func pSet, E q. By Exercise 5.4, for any cocomplete category E, there is
an equivalence
ÞÑF ptuq
Func pSet, E q € FunpSet, E q Ñ
F
E,
with an inverse functor given by e ÞÑ p b eq.
The following related statement can be viewed as a category-theoretic version of the formula
»
µpAq  χA pxqdµpxq,
X

for a measure space pX, µq and a measurable subset A € X. It expresses a decomposition of a functor F
into two independent pieces: the values F piq and the Hom-sets Homp, iq.

Lemma 8.14. Let I be a small category, and D be cocomplete. For a functor F : I op Ñ D, there is a
functorial isomorphism
»i
F  Homp, iq b F piq.
8.2. KAN EXTENSIONS VIA (CO)ENDS 89

Proof. We need to show that F pj q is (functorially) isomorphic to the colimit of the diagram


id D  I idHom
Ñι I op  I FÑ Ñ pj,q D  Set Ñ
Ib D.

A cocone over that diagram is an object d P D together with a collection of maps τi (for each i P I), such
that for each map i Ñ i1 the following diagram commutes:

Hompi1 , j q b F piq / Hom pi, j q b F piq


pq
F f τi
 τi1 
Hompi1 , j q b F pi1 q / d.

By definition of b as a left adjoint, the map τi is equivalent to a family of maps τi,g : F piq Ñ d for each
g P Hompi, j q, and then the condition amounts to requiring that these assemble to a morphism of functors
(in FunpI op , Setq)

HomI p, j q Ñ HomD pF pq, dq, pg : i Ñ j q ÞÑ pτi,g : F piq Ñ dq.

By the Yoneda lemma (Lemma 3.5), this is the same as the evaluation of the right hand functor at j, i.e.,
a morphism F pj q Ñ d, namely τj,idj . Thus, the initial cocone is F pj q, showing our claim.

8.2 Kan extensions via (co)ends

Proposition 8.15. Let E be a cocomplete category, and F : C Ñ C 1 be a functor between small categories.
Then the restriction functor

F  : FunpC 1 , E q Ñ FunpC, E q

admits a left adjoint. That is, all functors G : C ÑE have a left Kan extension along F . It can be
computed as the coend of the functor
»c
LanF pGq  HomC 1 pF pcq, q b Gpcq, (8.16)

i.e.,
»c
pLanF pGqqpc1q  HomC 1 pF pcq, c1 q b Gpcq.

Example 8.17. If F  idC , then F  is just the identity so that its left adjoint, LanF pq is also the
identity, i.e., LanF pGq  G. Thus, the statement here can be regarded as an extension of Lemma 8.14.
At another extreme, for F : C Ñ tu, we already know LanF G  colim G. For this reason, the coend
appearing in (8.16) is referred to as a weighted colimit, the idea being that the terms Gpcq appearing in
the colimit are taken into account with “weight” HompF pcq, c1 q.
90 CHAPTER 8. KAN EXTENSIONS

Proof. There are bijections (functorial in G P FunpC, E q and H P FunpC 1, E q):


»
HomFunpC ,E q pLanF G, H q 
1 HomE pLanF Gpc1 q, H pc1 qq
1
»c » c
 HomE HomC 1 pF pcq, c1 q b Gpcq, H pc1 q
»c1 »
 HomE pHomC 1 pF pcq, c1 q b Gpcq, H pc1 qq
»c1 »c
 HomSet pHomC 1 pF pcq, c1 q, HomE pGpcq, H pc1 qqq
c1
» »c
 HomSet pHomC 1 pF pcq, c1 q, HomE pGpcq, H pc1 qqq
»c c1

 HomE pGpcq, H pF pcqq
c
 HomFunpC,EqpG, H  F q
 HomFunpC,EqpG, F H q.
We have used (8.12), the above definition, the cocontinuity of HomE p, H pc1 qq, the definition of the b-
functor as a left adjoint. At the end, we have again used (8.12), and the definition of F  .
The isomorphism * is an instance of the Fubini theorem for ends, which is an extension of Lemma 4.44:
let us be given a functor
F : C op  C  C 1op  C 1 Ñ V
with V complete (for example, V  Set; it suffices to assume that all the ends appearing below exist).
Then, taking the end with respect to C gives a functor
» »
F : C 1op  C 1 Ñ V, pc11 , c12 q ÞÑ F pc, c, c11 , c12 q.
c c

The end of this functor is then isomorphic to the end of F , regarded as a functor pC  C 1 qop pC  C 1 q Ñ V .
In particular, by symmetry, we then have
» » » »
F pc, c, c1 , c1 q  F pc, c, c1 , c1 q.
c c1 c1 c

For a hands-on proof of this, see [Mac98, Proposition §IX.8].


At **, we have used (8.12) again: if we put X pc1 q : HomE pGpcq, H pc1 qq, then an element in the inner
coend is a compatible collection, for each F pcq Ñ c1 , of elements of X pc1 q. This is the same as an element
in X pF pcqq.
Remark 8.18. Another proof of the Fubini theorem for coends proceeds by observing that the process
of taking coends is a left adjoint, much the same way as colimits are left adjoints (Lemma 5.10): for a
cocomplete category E, there is an adjunction
»
c
: FunpC op  C, E q Õ E,
where the right adjoint is given by e ÞÑ ppc, c1 q ÞÑ HomC pc, c1 q b eq, see [Loregian:Coend]. Using this
insight, the Fubini theorem for coends can be conceptually proven as we did for colimits, cf. p. ??.
Corollary 8.19. In the situation of Proposition 8.15, suppose also that F is fully faithful. Then we have
pLanF Gq|C  G.
Proof. For c1 P C € C, we have by Lemma 8.14:
»c »c
1
LanF Gpc q  1
HomC 1 pF pcq, c q b Gpcq  HomC pc, c1 q b Gpcq  Gpc1 q.
8.3. THE FREE COCOMPLETION 91

8.3 The free cocompletion


The following statement is referred to by saying that the presheaf category C p : PShpC q is the free
cocompletion of a (small) category C. Another way to phrase the result is by saying that any functor
(taking values in a cocomplete category D) can be uniquely (up to unique isomorphism) extended to a
colimit-preserving functor defined on the presheaf category. This extension is the left Kan extension:

C
F /
?D
y
 Lany F
p
C

Theorem 8.20. Let C be a small category and y : C Ñ C p the Yoneda embedding into its category of
presheaves. For any cocomplete category D, the composite
y
Func pC,
p Dq € FunpC,
p Dq Ñ FunpC, Dq
is an equivalence of categories, with an inverse given by left Kan extensions.
Example 8.21. Let f : X ÑY be a continuous map of topological spaces, and consider the associated
functor
f 1 : OpenpY q Ñ OpenpX q.
Composition with this functor defines the so-called pushforward functor
f : PShpX q : PShpOpenpX qq Ñ PShpOpenpY qq.
Concretely, for a presheaf F on X, f F is the presheaf given by pf F qpU q  F pf 1pU qq. Consider the
following left Kan extension:
f 1
OpenpX q / OpenpY q
yX yY
 
PShpX q / PShpY q.
f : LanyX yY f 1
 p  q
The functor f  is called the pullback functor . According to the theorem, it is the unique colimit preserving
functor that is given on representable presheaves by
f  pHomp, U qq  Homp, f 1 pU qq.
One can further show that f  is a left adjoint of f (Exercise 8.3), which makes this functor into a crucial
functor in geometry and topology.
If C  tu, then Theorem 8.20 recovers Exercise 5.4. We will in fact prove Theorem 8.20 as a consequence
of Exercise 5.4 and some considerations on Kan extensions. Recall that for two small categories I and J
and a category C, we have a natural equivalence
FunpI J, C q  FunpI, FunpJ, C qq (8.22)
given by f Þ pi ÞÑ pj Ñ
Ñ Þ f pi, j qqq and conversely f ÞÑ ppi, j q ÞÑ f piqpj qq.
In other words, the process
of taking functor categories resembles being a right adjoint to taking products of categories. (We say
“resembles” here, since a regular adjunction involves functorial bijections of certain Hom-sets, whereas
the above involves an equivalence of certain categories. The above is an example of an adjunction in the
2-category of categories, in which the morphisms are not just sets, but categories in their own right.) The
following lemma is a noteworthy statement in that it allows to regard the functor category also as a certain
left adjoint:
92 CHAPTER 8. KAN EXTENSIONS

Lemma 8.23. Let I, C, D be categories, with I small and C and D cocomplete. Consider the functor
ι : I op  C Ñ FunpI, C q, pi, cq ÞÑ HomI pi, q b c.
Then there is an equivalence of categories

Func pFunpI, C q, Dq Õ  Fun


Lanι
ι cC
pI op  C, Dq  FuncpC, FunpI op, Dqq.
Here, in the middle the superscript cC indicates the full subcategory consisting of those functors that
preserve colimits in the variable C, i.e., those functors such that for each i P I, the functors F pi, q : C Ñ D
is cocontinuous.
Proof. By Proposition 8.15, Lanι exists and can be computed using coends. If H : I op  C Ñ D preserves
colimits in C, then Lanι H is cocontinuous since colimits commute with coends, which are colimits in their
own right (??). The functor ι preserves colimits in C, so that ι gives a functor as stated. Thus, we get
pair of functors ι and Lanι as in the statement.
For the claimed left hand equivalence, we show that the two compositions are isomorphic to the identity
functors: » i
pLanιH qpιpj, cqq  H pi, Hompj, iq b X q
»i
 Hompj, iq b H pi, X q
 H pj, X q.
We have used the description of the left Kan extension via coends, and the cocontinuity of H in the second
variable, as well as Lemma 8.14.
Conversely, let H̃ be in the left-hand category. Then, being cocontinuous, H̃ preserves coends, and
thus, again using Lemma 8.14:
»i »i
H̃ pX q  H̃ pHompi, q b X piqq  H̃ιpi, X piqq.

todo: check
The right hand equivalence arises by restricting the equivalence
FunpI op  C, Dq  FunpC, FunpI op , Dqq
to the indicated subcategories.
Proof. (of Theorem 8.20) In Lemma 8.23, we take C  Set and obtain, using Exercise 5.4
Func pI,
p Dq  Func pSet, FunpI, Dqq ÝÑ  FunpI, Dq.
F ÞÑF ptuq

8.4 The Ind-completion


The category PShpC q offers plenty of space for other cocompletions. We will indicate the Ind-completion as
an example of this situation. Proofs of the statements in this subsection appear, e.g., in [KashiwaraShapira:Cate
Definition 8.24. Let C be a small category. The Ind-completion IndpC q is defined to be the full subcat-
egory of PShpC q consisting of those presheaves F : C Ñ Set such that there is a filtered diagram
K:I ÑC
(i.e., I is a filtered category) and an isomorphism
F  colim ypK piqq.
8.4. THE IND-COMPLETION 93

Remark 8.25. ˆ The important point is to insist that K is filtered. Indeed, the formula
»i »i
F  HomI p, iq b F piq  y piq b F piq

(Lemma 8.14) shows that we can write any presheaf F as a colimit² (namely, the coend above, which is
a colimit involving of a diagram involving the terms y piqb F piq  PF piq y piq) of a diagram involving
only the representable presheaves y piq.
ˆ By definition, we can think of the objects in IndpC q as being formal filtered colimits:
F “ colim Ki ”.
This is formal in the sense that the category C need not have such a colimit (and even if it does, the
Yoneda embedding need not preserve it).
Remark 8.26. We compute the set of morphisms HomIndpC q pF, F 1 q. Suppose F  colim y pK piqq and
F 1  colim y pK 1 pi1 qq for K : I Ñ C and K 1 : I 1 Ñ C two filtered diagrams.
HompF, F 1 q  HomPShpC q pcolimi y pK piqq, colimi1 y pK 1 pi1 qqq
 lim HomPShpC q pypK piqq, colimi1 ypK 1pi1qqq
i
 limi
pcolimi1 ypK 1pi1qqq pK piqq
 lim
i
colimi1 py pK 1 pi1 qqq pK piqq
 lim colimi1 HomC pK 1 pi1 q, K piqq.
i

At *, we have used that colimits in functor categories are computed pointwise (Lemma 4.34). Thus, given
a presentation of F and F 1 as above, a morphism f : F Ñ F 1 is a collection of maps, for each i,
K piq Ñ K 1 pi1i q,
where i1i P I 1 is an index (depending on i).
± These maps are supposed to be compatible as i varies (in order
to be an element in limi , as opposed to i ).
Theorem 8.27. Let C be a small category.
(1) The category IndpC q has all filtered colimits.
(2) For any category D that has all filtered colimits, the composite
y
Funfilt pIndpC q, Dq € FunpIndpC q, Dq Ñ FunpC, Dq
is an equivalence. Here the left hand category is the full subcategory of the functor category consisting
of functors preserving filtered colimits. An inverse is given by left Kan extensions; it is also referred to
as the Ind-extension of a given functor F : C Ñ D.
(3) The Yoneda embedding y : C € PShpC q takes values in the full subcategory IndpC q € PShpC q. For
any c P C, y pcq is a compact object in IndpC q.
Proof. We only indicate some bits for (2): y pC q € IndpC q by definition. The inclusion

IndpC q € C
p
preserves filtered colimits (note that the inclusion C Ñ IndpC q need not preserve them; compare this with
Exercise 4.16). This follows from the second statement, applied to D  C. p Then, the functor
HomIndpC q py pcq, q  HomCp py pcq, q  pcq
preserves filtered colimits, since the right hand functor in fact preserves all colimits (Lemma 4.34).
94 CHAPTER 8. KAN EXTENSIONS

In order to understand the Ind-completion more concretely, the following statement is useful:
Corollary 8.28. Let F : C Ñ D be a functor, with D admitting all filtered colimits, and F : IndpC q Ñ D
the Ind-extension of F .
(1) F is fully faithful if F is fully faithful and if F pcq is a compact object (in D) for each c P C.
(2) F is an equivalence if, in addition, every object d P D can be presented as a filtered colimit d 
colim F pci q, for an appropriate filtered diagram I Ñ C.

Proof. (1) follows quickly from the computation of Hom-sets in IndpC q.


Example 8.29. We have
Set  IndpFinSetq, Vect  IndpVectf d q
(the category Vectf d denotes the full subcategory of finite-dimensional vector spaces). Indeed, finite-
dimensional vector spaces are compact objects in Vect (Example 4.48). In addition, each vector space V
is a filtered colimit of finite-dimensional ones:

V  colimW €V,dim W 8 W.

8.5 Exercises
Exercise 8.1. Let C be a category, X P C an object and f : X Ñ X an endomorphism. We regard the
pair pX, f q as a functor BN Ñ C (cf. Exercise 2.1) by sending  ÞÑ X and Homp, q  N Q n ÞÑ f n .
Show that the left, resp. right Kan extensions along the natural functor i : BN Ñ BZ are given by

Lani pX, f q  colimpX Ñf X Ñf . . . q,


Rani pX, f q  limp   Ñ X Ñf X q.
f

Exercise 8.2. Let C be a small category. What is the left Kan extension in this diagram:

C
y
/C
@
p
y
 Lany y ? 
p
C
Exercise 8.3. Let f : C Ñ C 1 be a functor between small categories. Consider the precomposition-with-
f -functor
f : C
x1 Ñ Cp
as well as the Kan extension
C1
f
C /


y: yC y 1 : yC 1

 
Lany y 1 f
p q / x1
p
C C.

Õ Cx1 : f 
Show that
Lany py 1 f q : C
p
are adjoint.
References

[Awo10] Steve Awodey. Category theory. Second. Vol. 52. Oxford Logic Guides. Oxford University Press, Oxford, 2010,
pp. xvi+311. isbn: 978-0-19-923718-0.
[Bor94] Francis Borceux. Handbook of categorical algebra. 1. Vol. 50. Encyclopedia of Mathematics and its Applications.
Basic category theory. Cambridge University Press, Cambridge, 1994, pp. xvi+345. isbn: 0-521-44178-1.
[Bra15] M. Brandenburg. Einführung in die Kategorientheorie: Mit ausführlichen Erklärungen und zahlreichen Beispielen.
Springer Berlin Heidelberg, 2015. isbn: 9783662470688.
[Fre70] Peter Freyd. “Homotopy is not concrete”. In: The Steenrod Algebra and its Applications (Proc. Conf. to Celebrate
N. E. Steenrod’s Sixtieth Birthday, Battelle Memorial Inst., Columbus, Ohio, 1970). Lecture Notes in Mathematics,
Vol. 168. Springer, Berlin, 1970, pp. 25–34.
[Lei14] Tom Leinster. Basic category theory. Vol. 143. Cambridge Studies in Advanced Mathematics. Cambridge University
Press, Cambridge, 2014, pp. viii+183. isbn: 978-1-107-04424-1. doi: 10.1017/CBO9781107360068. url: https:
//[Link]/10.1017/CBO9781107360068.
[Mac98] Saunders Mac Lane. Categories for the working mathematician. Second. Vol. 5. Graduate Texts in Mathematics.
New York: Springer-Verlag, 1998, pp. xii+314. isbn: 0-387-98403-8.
[Rie17] E. Riehl. Category Theory in Context. Aurora: Dover Modern Math Originals. Dover Publications, 2017. isbn:
9780486820804. url: [Link]

95
96 REFERENCES

You might also like