Skip to content

The divergence theorem, explained

5 min read

Short answer

For a solid EE with closed boundary surface SS oriented outward, ∬SF⋅dS=∭E∇⋅F dV.\iint_S\mathbf F\cdot d\mathbf S=\iiint_E\nabla\cdot\mathbf F\,dV. Divergence measures how much the field is spreading out at each point (sources minus sinks), so the total flux out through the boundary equals the total production inside.

Surface side compared with Volume sideSurface sideFlux through SNeeds a normal nSeveral faces to doOutward orientationHard for messy shapesVolume sideIntegral of div FOne triple integralNo normals neededSources − sinks insideOften much easier
Both sides compute the same number. Choose whichever is easier, usually the volume side.

Why it is true

Split the solid into tiny boxes. For each box, the net outward flux is the divergence times its volume. When boxes touch, the flux out of one face is the flux into the next, so interior faces cancel and only the outer boundary remains.

Conditions

The surface must be closed and the field must be continuously differentiable throughout the solid. If F\mathbf F blows up inside (like r/∣r∣3\mathbf r/|\mathbf r|^3 at the origin), the theorem does not apply directly. For an open surface, close it off with extra pieces and subtract their flux.

Worked example

Verify the divergence theorem for F=(x2,y2,z2)\mathbf F=(x^2,y^2,z^2) on the unit cube [0,1]3[0,1]^3.

Volume side: ∇⋅F=2x+2y+2z\nabla\cdot\mathbf F=2x+2y+2z, so ∭(2x+2y+2z) dV=2⋅3⋅12=3.\iiint(2x+2y+2z)\,dV=2\cdot3\cdot\tfrac12=3. Surface side: the face x=1x=1 has n=(1,0,0)\mathbf n=(1,0,0) and F⋅n=1F\cdot n=1, flux 11. The face x=0x=0 has F⋅n=−x2=0F\cdot n=-x^2=0. The same for yy and zz. Total flux =1+1+1=3=1+1+1=3. ✓

Try it yourself

For F=(x,y,z)\mathbf F=(x,y,z), compute the flux leaving a ball of radius 3 centered at the origin.

Show the answer

∇⋅F=3\nabla\cdot\mathbf F=3 and the volume is 43π⋅27=36π\tfrac43\pi\cdot27=36\pi. Flux =3⋅36π=108π=3\cdot36\pi=108\pi.

Keep going with practice

The divergence theorem is a highlight of Vidi's Multivariable & Vector Calculus course.