Definition 4.2.1. A category $\mathcal{C}$ consists of the following data:

1. A set of objects $\mathop{\mathrm{Ob}}\nolimits (\mathcal{C})$.

2. For each pair $x, y \in \mathop{\mathrm{Ob}}\nolimits (\mathcal{C})$ a set of morphisms $\mathop{Mor}\nolimits _\mathcal {C}(x, y)$.

3. For each triple $x, y, z\in \mathop{\mathrm{Ob}}\nolimits (\mathcal{C})$ a composition map $\mathop{Mor}\nolimits _\mathcal {C}(y, z) \times \mathop{Mor}\nolimits _\mathcal {C}(x, y) \to \mathop{Mor}\nolimits _\mathcal {C}(x, z)$, denoted $(\phi , \psi ) \mapsto \phi \circ \psi$.

These data are to satisfy the following rules:

1. For every element $x\in \mathop{\mathrm{Ob}}\nolimits (\mathcal{C})$ there exists a morphism $\text{id}_ x\in \mathop{Mor}\nolimits _\mathcal {C}(x, x)$ such that $\text{id}_ x \circ \phi = \phi$ and $\psi \circ \text{id}_ x = \psi$ whenever these compositions make sense.

2. Composition is associative, i.e., $(\phi \circ \psi ) \circ \chi = \phi \circ ( \psi \circ \chi )$ whenever these compositions make sense.

In your comment you can use Markdown and LaTeX style mathematics (enclose it like $\pi$). A preview option is available if you wish to see how it works out (just click on the eye in the toolbar).