Tutorials › Calculus III › Radial Fields on Spherical Shells

The Divergence Theorem · Tutorial 966 of 999

Radial Fields on Spherical Shells

Learn to integrate the divergence of a radial field over a ball or spherical shell and match that integral to the field’s signed flux across the boundary spheres.

Advanced 10 min read

What You'll Learn

  • Express a radial vector field using its magnitude in the radial direction.
  • Derive the divergence formula for a radial field in three dimensions.
  • Reduce a divergence integral over a ball or shell to a one-dimensional integral.
  • Identify the correct outward normal on each sphere bounding a shell.
  • Check a divergence-theorem calculation against the field’s boundary values.

Radial Fields and Spherical Boundaries

A radial vector field points directly toward or away from a fixed centre, and its magnitude depends only on distance from that centre. Spheres fit this geometry: on each sphere centred at the field’s centre, the field has the same magnitude and is parallel to the sphere’s normal. This makes the flux especially simple to compute.

For a ball, integrating the divergence from the centre to the boundary recovers the flux across the outer sphere. For a spherical shell, the integral records the difference between the fluxes at the outer and inner radii. The sign at the inner sphere matters: the shell’s outward normal there points toward the centre.

Definition: Let \(r=\sqrt{x^2+y^2+z^2}\). A radial vector field centred at the origin can be written, for \(r>0\), as \(\mathbf{F}(\mathbf{x})=\phi(r)\mathbf{e}_r\), where \(\mathbf{e}_r=(x,y,z)/r\) is the outward radial unit vector and \(\phi(r)\) is the signed radial magnitude. A positive \(\phi\) points outward; a negative \(\phi\) points inward.

Another common form is \(\mathbf{F}(\mathbf{x})=g(r)(x,y,z)\). For \(r>0\), this is the same field with \(\phi(r)=r g(r)\). We will use \(\phi\) to state the flux formulas, since the flux across a sphere of radius \(r\) is then directly proportional to \(r^2\phi(r)\).

The Divergence and Flux of a Radial Field

For \(r>0\), the divergence of \(\mathbf{F}=\phi(r)\mathbf{e}_r\) is \(\phi'(r)+2\phi(r)/r\). A sphere of radius \(R\) has area \(4\pi R^2\), and its outward unit normal is \(\mathbf{e}_r\). Since \(\mathbf{F}\cdot\mathbf{e}_r=\phi(R)\) everywhere on that sphere, its outward flux is \(4\pi R^2\phi(R)\).

Key formulas: For a radial field centred at the origin, \(\nabla\cdot\mathbf{F}=\phi'(r)+2\phi(r)/r\) when \(r>0\), and the outward flux across a sphere of radius \(R\) is \(4\pi R^2\phi(R)\). If \(\mathbf{F}=g(r)(x,y,z)\), these formulas become \(\nabla\cdot\mathbf{F}=3g(r)+r g'(r)\) and sphere flux \(4\pi R^3g(R)\).

The divergence theorem applies to a solid ball or spherical shell when the field is continuously differentiable on an open region containing the solid and its boundary. In particular, a field used on a ball must be regular at the centre. On a shell with inner radius \(a>0\), the field need only be defined and continuously differentiable on a neighbourhood of that shell.

Why the Divergence Integral Reduces to Boundary Values

In spherical coordinates, a function depending only on \(r\) has volume integral \(4\pi\int r^2(\text{function of }r)\,dr\). For a radial field, multiplying its divergence by \(r^2\) produces a derivative:

$$ r^2\left(\phi'(r)+\frac{2\phi(r)}{r}\right) =r^2\phi'(r)+2r\phi(r) =\frac{d}{dr}\bigl(r^2\phi(r)\bigr). $$

This identity explains the boundary formulas. Integrating the divergence over a shell from radius \(a\) to radius \(b\), where \(0<a<b\), gives the difference of \(r^2\phi(r)\) at the two endpoints. For a ball, the same calculation starts at zero, and the endpoint term at zero vanishes for a field that is continuously differentiable at the centre.

Theorem: Suppose \(\mathbf{F}=\phi(r)\mathbf{e}_r\) is continuously differentiable on a neighbourhood of the solid ball of radius \(R\). Then \(\displaystyle \iiint_{r\le R}\nabla\cdot\mathbf{F}\,dV=4\pi R^2\phi(R)\). If the field is continuously differentiable on a neighbourhood of the shell \(a\le r\le b\), where \(0<a<b\), then \(\displaystyle \iiint_{a\le r\le b}\nabla\cdot\mathbf{F}\,dV=4\pi\bigl(b^2\phi(b)-a^2\phi(a)\bigr)\).

For the ball formula, continuity of the field at the centre makes it bounded near \(r=0\), so \(r^2\phi(r)\) tends to zero there. If the field is differentiable on the entire ball, its divergence is continuous there as well, so the volume integral is well defined. The following calculation proves both formulas and identifies their boundary-flux meaning.

1
Integrate the divergence over a shell.
Using spherical coordinates and the derivative identity, \(\displaystyle \iiint_{a\le r\le b}\nabla\cdot\mathbf{F}\,dV=4\pi\int_a^b r^2\left(\phi'(r)+\frac{2\phi(r)}{r}\right)\,dr=4\pi\bigl(b^2\phi(b)-a^2\phi(a)\bigr)\), by the fundamental theorem of calculus.
2
Compute the shell’s boundary flux.
At \(r=b\), the shell’s outward unit normal is \(\mathbf{e}_r\), so the outer flux is \(4\pi b^2\phi(b)\). At \(r=a\), its outward unit normal is \(-\mathbf{e}_r\), so the inner flux is \(-4\pi a^2\phi(a)\). Their sum equals the divergence integral.
3
Take the ball limit.
Let \(a\) tend to zero in the shell calculation. Since \(r^2\phi(r)\) tends to zero for a field regular at the centre, the inner endpoint term vanishes. The remaining value is \(4\pi R^2\phi(R)\), which is the outward flux across the ball’s boundary sphere.

This calculation is also a direct verification of the divergence theorem in this radial setting: the volume integral equals the sum of the outward fluxes on the boundary spheres. In the shell case, it is a signed difference, not a sum of two positive magnitudes.

Worked Examples

Worked Example: A Radial Field on a Ball

Let \(\mathbf{F}=(1+r^2)(x,y,z)\), and find the outward flux across the sphere \(r=2\) by integrating the divergence over the ball.

Here \(g(r)=1+r^2\), so \(\mathbf{F}=\phi(r)\mathbf{e}_r\) with \(\phi(r)=r(1+r^2)=r+r^3\). Using the radial divergence formula in the \(g\)-form gives \(\nabla\cdot\mathbf{F}=3g(r)+rg'(r)=3(1+r^2)+r(2r)=3+5r^2\).

The divergence integral is \(\displaystyle 4\pi\int_0^2(3+5r^2)r^2\,dr=4\pi\int_0^2(3r^2+5r^4)\,dr=4\pi\left[r^3+r^5\right]_0^2=4\pi(8+32)=160\pi.\)

Check using the boundary sphere: \(\phi(2)=2+2^3=10\), so its outward flux is \(4\pi(2^2)(10)=160\pi\). The boundary value agrees with the divergence integral.

Worked Example: A Radial Field on a Spherical Shell

Let \(\mathbf{F}=r(x,y,z)\), and find the outward flux through the boundary of the shell \(1\le r\le 3\) by integrating the divergence.

Since \(\mathbf{F}=r^2\mathbf{e}_r\), we have \(\phi(r)=r^2\). Thus \(\phi'(r)=2r\), and \(\nabla\cdot\mathbf{F}=\phi'(r)+2\phi(r)/r=2r+2r=4r\).

Integrate over the shell: \(\displaystyle \iiint_{1\le r\le 3}\nabla\cdot\mathbf{F}\,dV=4\pi\int_1^3(4r)r^2\,dr=16\pi\int_1^3r^3\,dr=4\pi\left[r^4\right]_1^3=4\pi(81-1)=320\pi.\)

Check the two boundary contributions. The outer sphere contributes \(4\pi(3^2)\phi(3)=4\pi(9)(9)=324\pi\). The inner sphere’s outward normal for the shell points inward, so its contribution is \(-4\pi(1^2)\phi(1)=-4\pi\). The total is \(324\pi-4\pi=320\pi\), as required.

Worked Example: A Field with Zero Divergence on a Shell

On the shell \(1\le r\le 2\), let \(\mathbf{F}=\mathbf{e}_r/r^2\). Find its net outward flux by integrating the divergence.

Here \(\phi(r)=1/r^2\), so \(\phi'(r)=-2/r^3\). Therefore \(\nabla\cdot\mathbf{F}=-2/r^3+2(1/r^2)/r=0\) throughout the shell. Its divergence integral is consequently \(\displaystyle 4\pi\int_1^2 0\cdot r^2\,dr=0\).

Check the boundary values: the outer sphere contributes \(4\pi(2^2)(1/2^2)=4\pi\), while the inner sphere contributes \(-4\pi(1^2)(1/1^2)=-4\pi\). Their sum is \(4\pi-4\pi=0\), matching the volume integral.

A Common Sign Error

It is easy to use the outward normal of a sphere at the inner boundary, even though the required normal is the outward normal of the shell. The two normals point in opposite directions. For the shell in the second example, treating both sphere contributions as positive would give \(324\pi+4\pi=328\pi\). That is not the shell’s outward flux: on the inner sphere, “outward” means pointing out of the shell and into its central hole.

Check the inner boundary: For a shell \(a\le r\le b\), the outer sphere contributes \(4\pi b^2\phi(b)\), and the inner sphere contributes \(-4\pi a^2\phi(a)\). Therefore the net flux is \(4\pi\bigl(b^2\phi(b)-a^2\phi(a)\bigr)\).

Why the Boundary Comparison Is Useful

For a radial field, the divergence integral does more than provide an alternative way to calculate flux. It shows how the net flux depends on the field’s radial values at the endpoints of the region. Changes in the field within a shell are accounted for by the difference between the outer and inner boundary contributions. If that difference is zero, as in the third example, the net outward flux is zero even though the field itself is nonzero on both boundary spheres.

When solving a problem, use the divergence integral when the divergence is manageable and spherical coordinates simplify the volume integral. Then check the result using the boundary formula. For a ball, evaluate \(4\pi R^2\phi(R)\). For a shell, evaluate the outer contribution and subtract the inner one. Agreement is a useful check on the integration and on the orientation of the normals.

Check Your Understanding

Use the radial divergence and flux formulas to answer these questions.

  1. For \(\mathbf{F}=\phi(r)\mathbf{e}_r\), what is \(\nabla\cdot\mathbf{F}\) when \(r>0\)?
  2. Why does the inner boundary contribution for a shell have a minus sign?
  3. For \(\phi(r)=r^3\), write the divergence integral over the shell \(1\le r\le 2\) as a one-dimensional integral.
  4. If the field is continuously differentiable at the centre of a ball, what happens to \(r^2\phi(r)\) as \(r\) tends to zero?
  5. For \(\phi(r)=1/r^2\) on a shell, what is the net outward flux, and how do its two boundary contributions compare?