Coordinate Representation of Divergence

Theorem
Let $\struct {M, g}$ be a Riemannian manifold.

Let $U \subseteq M$ be an open set.

Let $\tuple {x^i}$ be local smooth coordinates.

Let $X$ be a smooth vector field on $M$.

Let $\operatorname {div}$ be the divergence operator.

Then:


 * $\ds \map {\operatorname {div}} {X^i \dfrac \partial {\partial x^i}} = \frac 1 {\sqrt g} \dfrac \partial {\partial x^i} \paren {X^i \sqrt {g}}$

Proof
Let $\omega$ be the Riemannian volume form on $M$. Recall that the divergence of $X$ is defined by the relation $d(\omega \rfloor X) = \operatorname{div}(X)\omega$, where $\rfloor$ denotes the interior product. In our local coordinates we have $$\omega = \sqrt{g}dx_1 \wedge \dots \wedge dx_n.$$ Thus $$\omega \rfloor X = (-1)^{i - 1}\sqrt{g}X^idx_1 \wedge \dots \wedge \widehat{dx_i} \wedge \dots dx_n.$$ Thus $$d\omega = \frac{\partial}{\partial x_i}(\sqrt{g}X^i)dx_1 \wedge \dots \wedge dx_n.$$ Thus $$\operatorname{div}(X) = \frac{1}{\sqrt{g}}\frac{\partial}{\partial x_i}(\sqrt{g}X^i).$$