Verify the divergence theorem for the vector field \mathbf{v}=x^2 \mathbf{i}+\frac{1}{2} y^2 \mathbf{j}+\frac{1}{2} z^2 \mathbf{k} over the unit cube 0 ≤ x ≤ 1,0 ≤y ≤ 1,0 ≤ z ≤ 1.
Firstly we need to evaluate \oint_S \mathbf{v} \cdot \mathrm{d} \mathbf{S} where S is the surface of the cube. This integral has been calculated in Example 27.24 and shown to be 2.
Secondly we need to calculate \int_V \operatorname{div} \mathbf{v} \mathrm{d} V over the volume of the cube. This has been done in Example 27.23 and again the result is 2.
done in Example 27.23 and again the result is 2. We have verified the divergence theorem that \oint_S \mathbf{v} \cdot \mathrm{d} \mathbf{S}=\int_V \operatorname{div} \mathbf{v} \mathrm{d} V.