# Quantum Field theory, solving delta / green function

I have read an equation as follow $$[-(k^2-m^2)g^{\mu\nu}+k^{\mu}k^{\nu}]D_{\nu\lambda}(k)=\delta^{\mu}_{\lambda}$$ The solution is given as: $$D_{\nu\lambda}(k)=\large{\frac{-g_{\nu\lambda}+k_{\nu}k_{\lambda}/m^2}{k^2-m^2}}$$ I can only verify the answer but do not know how to yield the result step by step... are there any standard procedures to yield the solution?

We can make use of the projection operators \begin{align} & P^{T}_{\mu \nu} = g_{\mu \nu} - \frac{k_{\mu}k_{\nu}}{k^{2}}, \\ & P^{L}_{\mu \nu} = \frac{k_{\mu}k_{\nu}}{k^{2}}, \end{align} where $$P^{T}_{\mu \nu}$$ and $$P^{L}_{\mu \nu}$$ are the transverse and longitudinal projectors. $$P^{T}_{\mu \nu}$$ and $$P^{L}_{\mu \nu}$$ are the projection operators onto vectors orthogonal and parallel to $$k^{\mu}$$, respectively. You can verify by yourself that they satisfy the properties of projectors.
We then write \begin{align} -(k^{2}-m) g^{\mu \nu} + k^{\mu}k^{\nu} = A \cdot P^{T,\mu \nu} + B \cdot P^{L,\mu \nu} \end{align} where we can find \begin{align} A = -(k^{2} - m^{2}),\ B = m^{2}. \end{align} Now, to find the inverse $$D_{\mu \nu}(k)$$ we simply invert the $$A$$ and $$B$$ and then lower the $$\mu$$ and $$\nu$$ in $$A \cdot P^{T,\mu \nu} + B \cdot P^{L,\mu \nu}$$, where we yield \begin{align} D_{\mu \nu}(k) & = \frac{1}{A} P^{T}_{\mu \nu} + \frac{1}{B} P^{L}_{\mu \nu} = \frac{1}{-(k^{2}-m^{2})}P^{T}_{\mu \nu} + \frac{1}{m^{2}} P^{L}_{\mu \nu} \\ & = \frac{1}{-(k^{2}-m^{2})}\left( g_{\mu \nu} - \frac{k_{\mu}k_{\nu}}{k^{2}} \right) + \frac{1}{m^{2}} \frac{k_{\mu}k_{\nu}}{k^{2}} \\ & = \frac{1}{k^{2}-m^{2}}\left( -g_{\mu \nu} + \frac{k_{\mu}k_{\nu}}{m^{2}} \right). \end{align} When solving this sort of equations it is always very helpful to use $$P^{T}_{\mu \nu}$$ and $$P^{L}_{\mu \nu}$$, since the inverting process is very simple. For more reference you can see "Quantum Field Theory: Lectures of Sidney Coleman". In chapter 28.6 he actually present the same calculation that I did here. He also gave the identities verifying that $$P^{T}_{\mu \nu}$$ and $$P^{L}_{\mu \nu}$$ are indeed projectors.