1.2 Categories and Functors
Definition 1.2.1
A category $C$ consists of:
(i) a set $\mathrm{Ob}(C)$,
(ii) for any $X, Y \in \mathrm{Ob}(C)$, a set $\mathrm{Hom}_C(X, Y)$,
(iii) for any $X, Y, Z \in \mathrm{Ob}(C)$, a map:
called the composition and denoted by $(f, g) \mapsto g \circ f$,
these data satisfying:
(a) $\circ$ is associative, i.e., for $f \in \mathrm{Hom}_C(X, Y)$, $g \in \mathrm{Hom}_C(Y, Z)$ and $h \in \mathrm{Hom}_C(Z, W)$, we have $(h \circ g) \circ f = h \circ (g \circ f)$,
(b) for each $X \in \mathrm{Ob}(C)$, there exists $\mathrm{id}_X \in \mathrm{Hom}(X, X)$ such that $f \circ \mathrm{id}_X = f$ for all $f \in \mathrm{Hom}_C(X, Y)$ and $\mathrm{id}_X \circ g = g$ for all $g \in \mathrm{Hom}_C(Y, X)$.
Definition 1.2.5
Let $C$ be a category. We denote by $\mathrm{Mor}(C)$ the category whose objects are the morphisms in $C$ and whose morphisms are described as follows. Let $f : X \to Y$ and $g : X' \to Y'$ belong to $\mathrm{Mor}(C)$. Then
$$\mathrm{Hom}_{\mathrm{Mor}(C)}(f, g) = \{u : X' \to X,\ v : Y \to Y' \mid g \circ u = v \circ f\}.$$Definition 1.2.6
(i) An object $P \in C$ is called initial if for all $X \in C$, $\mathrm{Hom}_C(P, X) \simeq \{pt\}$. We often denote by $\emptyset_C$ an initial object in $C$.
(ii) We say that $P$ is terminal in $C$ if $P$ is initial in $C^{op}$, i.e., for all $X \in C$, $\mathrm{Hom}_C(X, P) \simeq \{pt\}$. We often denote by $pt_C$ a terminal object in $C$.
(iii) We say that $P$ is a zero object if it is both initial and terminal. Such a $P$ is often denoted by $0$.
Definition 1.2.10
(i) A functor $F : C \to C'$ consists of a map $F : \mathrm{Ob}(C) \to \mathrm{Ob}(C')$ and of maps $F : \mathrm{Hom}_C(X, Y) \to \mathrm{Hom}_{C'}(F(X), F(Y))$ for all $X, Y \in C$, such that
$$F(\mathrm{id}_X) = \mathrm{id}_{F(X)} \quad \text{for all } X \in C,$$$$F(g \circ f) = F(g) \circ F(f) \quad \text{for all } f : X \to Y,\ g : Y \to Z.$$A contravariant functor from $C$ to $C'$ is a functor from $C^{op}$ to $C'$.
(ii) For categories $C, C', C''$ and functors $F : C \to C'$, $G : C' \to C''$, their composition $G \circ F : C \to C''$ is the functor defined by $(G \circ F)(X) = G(F(X))$ for all $X \in C$ and $(G \circ F)(f) = G(F(f))$ for all morphisms $f$ in $C$.
Definition 1.2.11
Let $F : C \to C'$ be a functor.
(i) We say that $F$ is faithful (resp. full, fully faithful) if
$$\mathrm{Hom}_C(X, Y) \to \mathrm{Hom}_{C'}(F(X), F(Y))$$is injective (resp. surjective, bijective) for any $X, Y$ in $C$.
(ii) We say that $F$ is essentially surjective if for each $Y \in C'$ there exist $X \in C$ and an isomorphism $F(X) \xrightarrow{\sim} Y$.
(iii) We say that $F$ is conservative if a morphism $f$ in $C$ is an isomorphism as soon as $F(f)$ is an isomorphism in $C'$.
Definition 1.2.13
Consider a family $\{C_i\}_{i \in I}$ of categories indexed by a set $I$.
(i) We define the product category $\prod_{i \in I} C_i$ by setting:
$$\mathrm{Ob}\!\left(\prod_{i \in I} C_i\right) = \prod_{i \in I} \mathrm{Ob}(C_i),$$$$\mathrm{Hom}_{\prod_{i \in I} C_i}(\{X_i\}_{i}, \{Y_i\}_{i}) = \prod_{i \in I} \mathrm{Hom}_{C_i}(X_i, Y_i).$$(ii) We define the disjoint union category $\bigsqcup_{i \in I} C_i$ by setting:
$$\mathrm{Ob}\!\left(\bigsqcup_{i \in I} C_i\right) = \{(X, i) \mid i \in I,\ X \in \mathrm{Ob}(C_i)\},$$$$\mathrm{Hom}_{\bigsqcup_{i \in I} C_i}((X, i), (Y, j)) = \begin{cases} \mathrm{Hom}_{C_i}(X, Y) & \text{if } i = j, \\ \emptyset & \text{if } i \neq j. \end{cases}$$Definition 1.2.16
Let $F : C \to C'$ be a functor and let $A \in C'$.
(i) The category $C_A$ is given by
$$\mathrm{Ob}(C_A) = \{(X, s) \mid X \in C,\ s : F(X) \to A\},$$$$\mathrm{Hom}_{C_A}((X, s), (Y, t)) = \{f \in \mathrm{Hom}_C(X, Y) \mid s = t \circ F(f)\}.$$(ii) The category $C^A$ is given by
$$\mathrm{Ob}(C^A) = \{(X, s) \mid X \in C,\ s : A \to F(X)\},$$$$\mathrm{Hom}_{C^A}((X, s), (Y, t)) = \{f \in \mathrm{Hom}_C(X, Y) \mid t = F(f) \circ s\}.$$Definition 1.2.17
For a category $C$, denote by $\sim$ the equivalence relation on $\mathrm{Ob}(C)$ generated by the relation $X \sim Y$ if $\mathrm{Hom}_C(X, Y) \neq \emptyset$. We denote by $\pi_0(C)$ the set of equivalence classes of $\mathrm{Ob}(C)$.
Definition 1.2.18
Let $C$ be a category and let $X \in C$.
(i) An isomorphism class of a monomorphism with target $X$ is called a subobject of $X$.
(ii) An isomorphism class of an epimorphism with source $X$ is called a quotient of $X$.