I have a question about weighted colimits. Let $D:E\rightarrow Set$ be a diagram,and $\phi:E^{op} \rightarrow Set$ a weight. $\phi*D \in Set$ is defined by this iso (i.e. a bijection),natural in $X$,
(1) $Set(\phi*D,X)\cong [E^{op},Set](\phi,Set{(D-,X)})$ , where $X$ is in Set.
Now,I would like to take for $D$ the homfunctor
$E(d,-)$ where $d$ is in $E$,and apply the Yoneda lemma to get
(2) $\phi(d)\cong \phi *E(d,-)$
But I cannot see how to substitute $E(d,-)$ for $D$ in (1),and how the r.h.s. of (1) reduces by the Yoneda lemma to get the equation (2). Can you please provide me with a detailed explanation?
I use the calculus of ends. First, observe that $$[\mathcal{E}^\mathrm{op}, \mathbf{Set}](F, G) \cong \int_{e : \mathcal{E}} \mathbf{Set}(F e, G e)$$ and in particular, $$[\mathcal{E}^\mathrm{op}, \mathbf{Set}](\Phi, \mathbf{Set}(D, X)) \cong \int_{e : \mathcal{E}} \mathbf{Set}(\Phi e, \mathbf{Set}(D e, X))$$ but $$\mathbf{Set}(\Phi e, \mathbf{Set}(D e, X)) \cong \mathbf{Set}(D e, \mathbf{Set}(\Phi e, X))$$ and $$\int_{e : \mathcal{E}} \mathbf{Set}(D e, \mathbf{Set}(\Phi e, X)) \cong [\mathcal{E}, \mathbf{Set}](D, \mathbf{Set}(\Phi, X))$$ hence: $$[\mathcal{E}^\mathrm{op}, \mathbf{Set}](\Phi, \mathbf{Set}(D, X)) \cong [\mathcal{E}, \mathbf{Set}](D, \mathbf{Set}(\Phi, X))$$ Now put $D = \mathcal{E}(d, -)$ and apply the usual Yoneda lemma.