The theorem
Before you start: you'll need surface integrals, triple integrals and divergence.
If \(V\) is a solid bounded by a closed surface \(S\) with outward unit normal \(\hat n\), and \(\vec F\) has continuous partial derivatives in \(V\), then
\[\iint_S \vec F\cdot\hat n\,dS = \iiint_V \nabla\cdot\vec F\,dV\]
The idea in one picture
Think of \(\vec F\) as the flow of a fluid. The divergence at each point measures how much fluid is created there. Adding up everything created inside \(V\) must equal everything flowing out through its surface.
Solved examples
Example 1: A sphere
EasyFind the outward flux of \(\vec r = x\mathbf{i} + y\mathbf{j} + z\mathbf{k}\) through the sphere of radius \(a\).
- \(\nabla\cdot\vec r = 3\), so the flux is \(\displaystyle\iiint_V 3\,dV = 3\cdot\frac{4}{3}\pi a^3\).
Answer\(4\pi a^3\), matching the direct calculation in Surface integrals, Example 2
Example 2: A unit cube
MediumUse the divergence theorem to evaluate \(\displaystyle\iint_S \vec F\cdot\hat n\,dS\) for \(\vec F = 4xz\,\mathbf{i} - y^2\,\mathbf{j} + yz\,\mathbf{k}\), where \(S\) is the surface of the cube \(0 \le x, y, z \le 1\).
- \(\nabla\cdot\vec F = 4z - 2y + y = 4z - y\).
- \(\displaystyle\iiint_V (4z - y)\,dV = 4\cdot\frac{1}{2} - \frac{1}{2}\) (the average of \(z\) and of \(y\) over the cube is \(\tfrac{1}{2}\)).
Answer\(\dfrac{3}{2}\). Doing it directly would need six separate surface integrals, one per face.
Example 3: Cubes of the coordinates
MediumEvaluate the outward flux of \(\vec F = x^3\mathbf{i} + y^3\mathbf{j} + z^3\mathbf{k}\) through the sphere of radius \(a\).
- \(\nabla\cdot\vec F = 3(x^2 + y^2 + z^2) = 3r^2\).
- \(\displaystyle\int_0^{2\pi}\!\!\int_0^\pi\!\!\int_0^a 3r^2\cdot r^2\sin\theta\,dr\,d\theta\,d\phi = 3\cdot\frac{a^5}{5}\cdot 4\pi\).
Answer\(\dfrac{12\pi a^5}{5}\)
Example 4: A cylinder
MediumFind the outward flux of \(\vec r\) through the closed cylinder \(x^2 + y^2 \le 4\), \(0 \le z \le 3\) (including top and bottom).
- \(\nabla\cdot\vec r = 3\), and the volume is \(\pi\cdot 4\cdot 3 = 12\pi\).
Answer\(36\pi\)
If a question asks for the flux through a closed surface made of several faces (a cube, a closed cylinder), use the divergence theorem. One triple integral replaces several surface integrals.
Common mistakes
1. Using it on an open surface
The surface must be closed. For an open surface (a hemisphere without its base), either close it with a flat disc and subtract that disc's flux, or compute directly.
2. Ignoring a point where \(\vec F\) blows up
For \(\vec F = \dfrac{\vec r}{r^3}\), \(\nabla\cdot\vec F = 0\) everywhere except the origin, yet the flux through a sphere about the origin is \(4\pi\), not 0. The theorem needs \(\vec F\) to be smooth throughout \(V\).
3. Using an inward normal
The theorem gives the outward flux.
Practice questions
Q1Outward flux of \(\vec r\) through the unit cube \(0 \le x, y, z \le 1\).
\(3\times\text{volume} = 3\).
Q2Outward flux of \(\vec F = 2x\,\mathbf{i} + 3y\,\mathbf{j} + 4z\,\mathbf{k}\) through the unit sphere.
\(\nabla\cdot\vec F = 9\): \(9\cdot\dfrac{4\pi}{3} = 12\pi\).
Q3Outward flux of \(\vec F = y\,\mathbf{i} + z\,\mathbf{j} + x\,\mathbf{k}\) through any closed surface.
\(\nabla\cdot\vec F = 0\), so the flux is 0.
Q4Outward flux of \(\vec F = x^2\mathbf{i} + y^2\mathbf{j} + z^2\mathbf{k}\) through the closed cylinder \(x^2 + y^2 \le a^2\), \(0 \le z \le h\).
\(\nabla\cdot\vec F = 2(x + y + z)\). The \(x\) and \(y\) terms integrate to 0 by symmetry, leaving \(\displaystyle\iiint 2z\,dV = 2\cdot\pi a^2\cdot\frac{h^2}{2} = \pi a^2h^2\).
Bring it to a free demo class and work through it with Vipul Sir. Book on WhatsApp.
Frequently asked questions
What does the divergence theorem say?
The total outward flux of a field through a closed surface equals the integral of its divergence over the volume inside.
Where is it used?
Throughout physics and engineering: Gauss's law in electrostatics, conservation of mass in fluid flow, and heat conduction.