Lemma for showing that presheaves are colimits of representables

$$\newcommand{\PShv}{\text{PShv}}$$ $$\newcommand{\Fun}{\text{Fun}}$$ $$\newcommand{\C}{\mathcal{C}}$$ $$\newcommand{\Hom}{\text{Hom}}$$ $$\newcommand{\ra}{\rightarrow}$$ $$\newcommand{\op}{\text{op}}$$ $$\newcommand{\Set}{\mathsf{Set}}$$ Let $$\C$$ be a small category and let $$\PShv(\C) := \Fun(\C^\op, \Set)$$ be the category of presheaves. I would like to show that for two presheaves $$F, G$$ we have the natural isomorphism $$\Hom_{\PShv(\C)}(F, G) \cong \Hom_{\Fun((* \Rightarrow F)^\op , \PShv(\C))}(P, \Delta(G))$$ where $$(* \Rightarrow F)^\op$$ is the (opposite) comma category, $$P : (* \Rightarrow F)^\op \ra \PShv(\C)$$ is given by $$(x, y) \mapsto Y(x)$$ ($$Y: \C \ra \PShv(\C)$$ is the Yoneda embedding $$x \mapsto \Hom_\C(-, x)$$) and $$\Delta : \PShv(\C) \ra \Fun((* \Rightarrow F)^\op , \PShv(\C))$$ is the diagonal/constant functor (used in the adjoint definition/formulation of (co)limits).

The proof I am reading starts by taking a natural transformation $$\eta : F \Rightarrow G \in \Hom_{\PShv(\C)}(F, G)$$, and then defines the correspoding natural transformation $$\zeta \in \Hom_{\Fun((* \Rightarrow F)^\op , \PShv(\C))}(P, \Delta(G))$$ by $$\zeta_{(x, y)}(g) = G(g) (\eta_x(y)) \qquad (*)$$ for any object $$(x, y)$$ of $$(* \Rightarrow F)^\op$$ and any $$g \in \Hom_\C(x', x)$$. So here $$\zeta : P \Rightarrow \Delta(G)$$ and its component at $$(x, y)$$ is a map with domain and codomain $$\zeta_{(x, y)} : P(x, y) = Y(x) \ra \Delta(G)(x, y).$$ My first question is: how can $$\zeta_{(x, y)}$$ possibly take a map $$g \in \Hom_\C(x', x)$$ as its argument if the domain of $$\zeta_{(x, y)}$$ is $$P(x,y)=Y(x)=\Hom_\C(-, x) \in \PShv(\C)$$?

The proof then considers the RHS of the isomorphism that is to be proved, namely it states that any $$\zeta \in \Hom_{\Fun((* \Rightarrow F)^\op , \PShv(\C))}(P, \Delta(G))$$ must be of the form $$(*)$$ for a unique $$\eta \in \Hom_{\PShv(\C)}(F, G)$$ by definition of naturality, since $$\zeta$$ is itself a natural transformation. I'm trying to show this explicitly but I'm not quite sure how to.

I've started by writing out $$\zeta$$ as a natural transformation; we have $$\zeta : P \Rightarrow \Delta(G)$$ natural so for $$(x_1, y_1), (x_2, y_2) \in (* \Rightarrow F)^\op$$ and a morphism $$f: (x_1, y_1) \ra (x_2, y_2)$$ we have the naturality square (in equations): $$\Delta(G)(f) \circ \zeta_{(x_1, y_1)} = \zeta_{(x_2, y_2)} \circ P(f)$$ I'd be grateful if anybody could explain how to recover something of the form $$(*)$$ from what we have above. Thank you.

• You probably know this, but that comma category is typically referred to as the category of elements of $F$. – Derek Elkins May 13 at 22:50

For your first question, it's a matter of sloppiness : what should be written is $$(\zeta_{(x,y)})_{x'}(g)$$, they just removed the $$x'$$ for ease of notation. I won't do this in my answer though.

For you to find $$\eta$$ you need to unravel the Yoneda lemma (it's no wonder the result you're trying to prove is also sometimes called the Yoneda lemma). I will change your notations slightly, and write $$(x,f)$$ for a generic element of $$\int_CF= (*\implies F)^{op}$$, that is $$x\in C, f\in F(x)$$, so that I can use $$y$$ for other generic elements of $$C$$ (and $$g$$ for a generic element of $$F(y)$$)

Suppose you have a natural transformation $$\zeta : P\to \Delta (G)$$. So in particular for $$(x,f)\in\int_CF$$ you have a map $$\zeta_{(x,f)} : Y(x)\to G$$.

Now recall what the Yoneda lemma tells us precisely about the shape of an arrow $$\theta : Y(x)\to G$$. It tells us that $$\theta_z(f) = G(f^{op})(\theta_x(id_x))$$ : this is again by the "stupid" square :

$$\require{AMScd} \begin{CD} \hom(x,x) @>{\theta_x}>> G(x)\\ @V{\hom(f,x)}VV @VV{G(f^{op})}V\\ \hom(z,x) @>>{\theta_z}> G(z) \end{CD}$$

But then, with $$g:x'\to x$$, $$(\zeta_{(x,f)})_{x'}(g)= G(g^{op})((\zeta_{(x,f)})_x(id_x))$$

We have our "$$\zeta_{(x,f)}(g)$$" (removing the $$x'$$-index, as you did) and our $$G(g)$$ (I denoted it $$G(g^{op})$$ for clarity but of course it's the same).

Let's look at what $$(\zeta_{(x,f)})_x(id_x)$$ does. It is quite clearly an element of $$G(x)$$, and if you move $$f\in F(x)$$, it moves with it. Sounds to me like this is a nice way to define $$\eta$$ : define $$\eta_x : F(x)\to G(x)$$ by $$\eta_x(f) := (\zeta_{(x,f)})_x(id_x)$$.

By what came just before, $$(\zeta_{(x,f)})_{x'}(g)= G(g^{op})(\eta_x(f))$$, which is what we wanted. We now only have to show that $$\eta$$ is natural.

So suppose you have a map $$\alpha : x\to y$$, and you want to look at the square (I'm removing the $$^{op}$$'s, hopefully it's still clear)

$$\require{AMScd} \begin{CD} F(y) @>{\eta_y}>> G(y)\\ @V{F(\alpha)}VV @VV{G(\alpha)}V\\ F(x) @>>{\eta_x}> G(x) \end{CD}$$

Start with $$g\in F(y)$$, and look at $$f:= F(\alpha)(g) \in F(x)$$. Then $$\alpha : (x,f)\to (y,g)$$ is a morphism in $$\int_CF$$, by definition, therefore we have a commutative diagram

$$\require{AMScd} \begin{CD} Y(x) @>{\zeta_{(x,f)}}>> G\\ @V{P(\alpha)}VV @VV{id}V\\ Y(y) @>>{\zeta_{(y,g)}}> G \end{CD}$$ (I don't know how to do triangles)

But then, if you evaluate this in $$x$$ and then $$id_x$$ you get $$(\zeta_{(y,g)})_x(\alpha)=(\zeta_{(x,f)})_x(id_x) = \eta_x(f)$$.

And now recall again the explicit version of the Yoneda lemma, which tells us precisely that $$(\zeta_{(y,g)})_x(\alpha) = G(\alpha)((\zeta_{(y,g)})_y(id_y)) = G(\alpha)(\eta_y(g))$$ so that in the end, $$\eta_x(f) = G(\alpha)(\eta_y(g))$$. But now remember the definition of $$f$$ : $$\eta_x\circ F(\alpha)(g) = G(\alpha)\circ \eta_y(g)$$.

This holds for any $$g$$, so the diagram commutes, so $$\eta$$ is natural; and we have found our $$\eta$$.

It remains to show that this $$\eta$$ is unique; but this is easy, as $$\eta_x(f) = (\zeta_{(x,f)})_x(id_x)$$ by the formula applied for $$x'=x, g=id_x$$ (I'm just realizing now that of course evaluating in $$g=id$$ would have given us $$\eta$$ without having to look for it as I did above - but at least it's confirming what I did, and it shows that in these examples there aren't 100 ways to do it)

• Thank you very much for your detailed answer, this is very helpful! One quick question: when you say we have $\theta_z(f) = G(f^{op})(\theta_x(id_x))$ by the square (Yoneda's Lemma) why exactly is this? So Yoneda says $$\hom_{\text{PShv}(\mathcal{C})}(Y(x), G) \cong G(x)$$ which gives us the square you drew and I suppose I see why $\theta_z(f) = G (\cdots)$ because of Yoneda, but why do we have $G(f^{op})(\theta_x(\text{id}_x))$ specifically? Edit: Ah, I think it's because of the explicit map of the Yoneda embedding, namely $\theta \mapsto \theta_x(\text{id}_x)$. – mathphys May 14 at 13:56
• Recall the proof of the Yoneda lemma : the square commutes by naturality of $\theta$, and when you evaluate it on $id_x \in \hom (x,x)$ : going down then right gives $\theta_z(\hom(f,x)(id_x))$ which is, by definition $\theta_z(f)$ (recall what $\hom(-,x)$ is ). Going right then down gives $G(f^{op})(\theta_x(id_x))$, which is the desired equality – Max May 14 at 13:58
• Yes you beat me to it (I remembered after I asked haha). Thanks again for your help! – mathphys May 14 at 14:01
• Yes, and I think one moral to this story (one thing to remember) is that you need to remember which isomorphisms you use to identify two things. I insisted on that in an answer to a question "why can you identify things that are isomorphic ?" and the point is that you can if you know the isomorphism because then you have a recipe to translate every statement about one to a statement about the other : just add $f$'s and $f^{-1}$'s to make it well-typed. The Yoneda lemma is no exception to this – Max May 14 at 16:59