From Boundary Flux to Interior Accumulation
A vector field assigns a vector to each point in space. Its flux through a surface measures the component of that field passing through the surface. For a closed surface, the outward flux records the net amount leaving the enclosed solid.
The Divergence Theorem connects this boundary measurement to a quantity defined throughout the solid: the divergence of the field. Instead of integrating the field across the boundary, one can integrate its divergence throughout the enclosed volume, provided the field and boundary satisfy the theorem's hypotheses.
Precise Statement
Let \(E\) be a bounded solid region in \(\mathbb{R}^3\), and let \(\partial E\) denote its boundary. Assume that \(\partial E\) is closed and piecewise smooth: it is made of finitely many smooth surface pieces that fit together along edges or curves. Assume also that a vector field \(\mathbf{F}=(P,Q,R)\) has continuous first partial derivatives on an open set containing all of \(E\).
At each smooth point of \(\partial E\), let \(\mathbf{n}\) be the unit normal pointing out of \(E\). The edges where surface pieces meet do not affect the surface integral. The divergence of \(\mathbf{F}\) is the scalar field
Here \(dS\) denotes an element of surface area and \(dV\) an element of volume. The hypotheses matter: the boundary must enclose a bounded solid, and the field must be sufficiently smooth throughout a neighborhood of that solid. In particular, a singularity of the field inside \(E\) prevents direct use of this version of the theorem.
Why the Orientation and Region Must Match
The two sides describe different measurements of the same field on the same solid. On the left, the field is measured at the boundary, using the outward-pointing normal. On the right, divergence is accumulated over the enclosed volume. Using a different region on the right would generally describe a different amount of accumulated divergence.
The direction of the normal is not a harmless convention. Replacing \(\mathbf{n}\) by \(-\mathbf{n}\) changes the sign of the flux integrand:
The volume integral, however, does not change when someone reverses a surface normal. Thus the theorem pairs the volume integral with the outward flux, not with an arbitrarily oriented flux.
Specify the bounded region \(E\) whose boundary is under consideration.
The surface integral covers the closed boundary \(\partial E\), including every boundary piece.
Use the unit normal directed away from the interior of \(E\) on each smooth boundary piece.
The divergence integral is over \(E\), not over a different region suggested by the field or by one boundary piece.
A Direct Consequence for the Position Field
A useful derivation comes from the position field \(\mathbf{F}(x,y,z)=(x,y,z)\). Its divergence is \(1+1+1=3\). Applying the theorem to any solid \(E\) that satisfies its hypotheses gives
where \(\mathbf{r}=(x,y,z)\) and \(\operatorname{Vol}(E)\) denotes the volume of \(E\). This derivation shows how the theorem turns a surface-flux calculation into a volume calculation when the divergence is simple. The result depends on the boundary being oriented outward and enclosing exactly the region whose volume appears.
Worked Checks on Smooth Solids
Worked Example: Position Field on the Unit Sphere
Let \(E\) be the unit ball \(x^2+y^2+z^2\leq 1\), and let \(\mathbf{F}=(x,y,z)\). The boundary is the unit sphere. Check both sides of the theorem.
First calculate the divergence:
The unit ball has volume \(4\pi/3\), so the volume-integral side is
On the unit sphere, the outward unit normal is \(\mathbf{n}=(x,y,z)\), because each point has distance \(1\) from the origin. Therefore \(\mathbf{F}\cdot\mathbf{n}=x^2+y^2+z^2=1\) on the boundary. The flux is
since the unit sphere has surface area \(4\pi\). Both sides equal \(4\pi\), as required.
Worked Example: Position Field on an Ellipsoid
Let \(E\) be the ellipsoid \(x^2/4+y^2+z^2/9\leq 1\), and again take \(\mathbf{F}=(x,y,z)\). This example checks how the theorem matches flux and volume even when the boundary is not spherical.
The divergence is still \(3\). The ellipsoid has semiaxes \(a=2\), \(b=1\), and \(c=3\), so its volume is \(4\pi abc/3=8\pi\). Hence
To check the flux directly, parametrize its boundary by \(\mathbf{r}(\theta,\phi)=(2\sin\theta\cos\phi,\sin\theta\sin\phi,3\cos\theta)\), where \(0\leq\theta\leq\pi\) and \(0\leq\phi\leq2\pi\). The outward-oriented surface element is
Taking its dot product with \(\mathbf{F}(\mathbf{r}(\theta,\phi))\) gives
Thus the flux is
This agrees with the volume integral. The outward orientation is confirmed by the positive radial direction of the parametrization's cross product.
Worked Example: A Symmetric Field with Zero Net Flux
Let \(E\) again be the unit ball, but now take \(\mathbf{F}=(x^2,y^2,z^2)\). Calculate both sides and check why the result is zero.
The divergence is
The ball is symmetric under reflection in each coordinate plane. For instance, the contribution from \(2x\) cancels between points \((x,y,z)\) and \((-x,y,z)\). The same argument applies to \(2y\) and \(2z\). Therefore
On the unit sphere, \(\mathbf{n}=(x,y,z)\), so the flux integrand is
Each term integrates to zero: reflection across the corresponding coordinate plane changes the sign of that term while preserving surface area. Hence the total boundary flux is \(0+0+0=0\). The two sides agree. This check also illustrates that the theorem concerns net outward flux; positive and negative contributions can cancel.
A Common Orientation Error
For the unit sphere and position field in the first example, the outward normal gives a flux of \(4\pi\). If the inward normal is used instead, the computation becomes
Equating this value to the unchanged volume integral \(3(4\pi/3)=4\pi\) would incorrectly claim that \(-4\pi=4\pi\). The correction is to use the outward normal required by the theorem. Reversing the normal reverses the flux, but it does not reverse or alter the divergence integral.
Why the Conversion Is Useful
The theorem is useful when one side of the equality is easier to calculate than the other. A complicated closed surface may be inconvenient for a direct flux integral, while the divergence may be simple over the enclosed solid. Conversely, the theorem gives a precise way to interpret a volume integral of divergence as the net outward flux across the boundary.
Before applying it, check the whole setup: the boundary is closed and piecewise smooth, the field has continuous first partial derivatives on a neighborhood of the solid, the normal points outward, and the volume region is exactly the one enclosed by that boundary. These conditions are part of the theorem, not optional details.
Check Your Understanding
Answer these questions using the theorem's definitions and conditions.
- Which integral measures outward flux, and which integral accumulates divergence through the solid?
- What conditions must the field and the boundary satisfy for the stated theorem to apply?
- Why must the volume integral be taken over the solid enclosed by the surface?
- If the unit normal is reversed, what happens to the flux integral? Does the volume integral change?
- For \(\mathbf{F}=(x,y,z)\), what does the Divergence Theorem say the outward flux equals in terms of the volume of \(E\)?