Solution (source code)

= Solution
{c}

Choose <normal coordinates> $\xi^\alpha$ centered at an event $p$. At $p$, the <metric tensor> in these coordinates is the constant <Minkowski metric> $\eta_{\alpha\beta}=\operatorname{diag}(-1,1,1,1)$, with $\xi^0$ measured in length units, and its first <partial derivatives> vanish. In arbitrary coordinates $x^\mu$, the <chain rule> for the <line element> gives
$$
ds^2\big|_p=\eta_{\alpha\beta}\,d\xi^\alpha d\xi^\beta
=g_{\mu\nu}(p)\,dx^\mu dx^\nu,
$$
so
$$
\boxed{g_{\mu\nu}(p)=\left.
\eta_{\alpha\beta}\frac{\partial\xi^\alpha}{\partial x^\mu}
\frac{\partial\xi^\beta}{\partial x^\nu}\right|_p.}
$$
This construction is pointwise. At nearby events, the <metric tensor> in the chosen <normal coordinates> is $g^{(\xi)}_{\alpha\beta}(\xi)=\eta_{\alpha\beta}+O(|\xi|^2)$, with the quadratic corrections determined by the <Riemann curvature tensor>. Replacing $g^{(\xi)}$ by one constant <Minkowski metric> throughout an open region would make that region flat, so it cannot describe general curved <spacetime> exactly.