$\Newextarrow{\xRightarrow}{5,5}{0x21D2}$ $\newcommand\empty{}$

Proposition Let $U: \operatorname{\mathcal{D}}\rightarrow \operatorname{\mathcal{C}}$ be a functor between categories, and let $f: X \rightarrow Y$ and $g: Y \rightarrow Z$ be composable morphisms in $\operatorname{\mathcal{C}}$. Then:

  • If $U$ is a fibration in sets, then $(g \circ f)^{\ast } = f^{\ast } \circ g^{\ast }$ (as functions from $\operatorname{Ob}( \operatorname{\mathcal{D}}_{Z} )$ to $\operatorname{Ob}( \operatorname{\mathcal{D}}_{X} )$).

  • If $U$ is an opfibration in sets, then $(g \circ f)_{!} = g_{!} \circ f_{!}$ (as functions from $\operatorname{Ob}( \operatorname{\mathcal{D}}_{X} )$ to $\operatorname{Ob}(\operatorname{\mathcal{D}}_{Z} )$).

Proof. We will prove the first assertion; the second follows by a similar argument. Fix an object $\widetilde{Z} \in \operatorname{Ob}( \operatorname{\mathcal{D}}_{Z} )$. Then there exists a unique morphism $\widetilde{g}: g^{\ast }( \widetilde{Z} ) \rightarrow \widetilde{Z}$ in $\operatorname{\mathcal{D}}$ satisfying $U( \widetilde{g} ) = g$. Similarly, there exists a unique morphism $\widetilde{f}: (f^{\ast } \circ g^{\ast })(\widetilde{Z}) \rightarrow g^{\ast }( \widetilde{Z} )$ satisfying $U( \widetilde{f} ) = f$. The composite morphism $\widetilde{g} \circ \widetilde{f}$ then satisfies $U( \widetilde{g} \circ \widetilde{f} ) = g \circ f$, and therefore witnesses the equality $(g \circ f)^{\ast }( \widetilde{Z} ) = (f^{\ast } \circ g^{\ast })( \widetilde{Z} )$. $\square$