# How does one write the Einstein field equations in terms of Ricci tensor?

How can I go from the 'standard' Einstein equations $R_{\mu\nu} - \frac{1}{2}g_{\mu\nu}R = \frac{8\pi G}{c^4}T_{\mu\nu}$ to these equations: $R_{\mu\nu} = \frac{8\pi G}{c^4}(T_{\mu\nu} - \frac{1}{2}g_{\mu\nu}T)$?

-

Take the trace of the equation by contracting it with $g^{\mu\nu}$:
$$g^{\mu\nu}R_{\mu\nu}-\dfrac{1}{2}g^{\mu\nu}g_{\mu\nu}R=\dfrac{8\pi G}{c^4}g^{\mu\nu}T_{\mu\nu}$$
As $g^{\mu\nu}R_{\mu\nu} = R$, $g^{\mu\nu}T_{\mu\nu} \equiv T$ and $g^{\mu\nu}g_{\mu\nu} = 4$, the previous equation gives you $R = -\dfrac{8\pi G}{c^4}T$. Substituting this into Einstein's equation shall give you the result.