Tutorials › Calculus III › Divergence and Curl of Radial Fields

Curl and Divergence · Tutorial 912 of 999

Divergence and Curl of Radial Fields

Learn to compute divergence and curl of radial fields directly from Cartesian derivatives and identify when the origin requires separate attention.

Advanced 10 min read

What You'll Learn

  • Define radial fields using the distance from the origin and the radial unit vector.
  • Derive divergence formulas for both common forms of radial fields.
  • Show why the curl of a differentiable radial field vanishes away from the origin.
  • Convert between unit-radial and position-vector representations.
  • Check radial-field formulas by differentiating Cartesian components.
  • Distinguish ordinary derivative results away from the origin from singular behavior at the origin.

Radial Fields and Distance from the Origin

A radial vector field points directly toward or away from the origin. Its magnitude may vary with distance, but it has no tangential component. Such fields appear in models with spherical symmetry, including idealized force and flow fields.

Let \(\mathbf{x}=(x,y,z)\) be a point in \(\mathbb{R}^3\), and let \(r=\|\mathbf{x}\|=\sqrt{x^2+y^2+z^2}\). For \(r>0\), the radial unit vector is \(\mathbf{x}/r\). A radial field can be written in either of two useful ways: as a scalar magnitude times the radial unit vector, or as a scalar function times the position vector.

Definition: For \(r>0\), a field of the form \(\mathbf{F}(\mathbf{x})=f(r)\mathbf{x}/r\) is a radial field with radial magnitude \(f(r)\). A field of the form \(\mathbf{F}(\mathbf{x})=g(r)\mathbf{x}\) is another representation of a radial field. The scalar functions \(f\) and \(g\) are assumed differentiable for \(r>0\) when computing divergence and curl.

These forms are equivalent away from the origin: \(g(r)=f(r)/r\), or \(f(r)=r g(r)\). The distinction matters because their divergence formulas look different. The curl, in contrast, is zero for either form wherever the field is differentiable and \(r>0\).

Deriving the Formulas in Cartesian Coordinates

We derive the results using Cartesian partial derivatives, so no formulas for other coordinate systems are needed. Write a general radial field as \(\mathbf{F}(\mathbf{x})=a(r)\mathbf{x}\). This includes the unit-radial form by taking \(a(r)=f(r)/r\), and the position-vector form by taking \(a(r)=g(r)\).

For each coordinate \(x_j\), the chain rule gives \(\partial r/\partial x_j=x_j/r\) when \(r>0\). Writing \(F_i=a(r)x_i\), the product rule therefore gives the entries of the Jacobian matrix:

$$ \frac{\partial F_i}{\partial x_j} = a(r)\delta_{ij} + \frac{a'(r)}{r}x_i x_j. $$

Here \(\delta_{ij}\) equals \(1\) when \(i=j\) and \(0\) otherwise. The divergence is the trace of this matrix. The curl is formed from differences of paired off-diagonal entries.

Theorem: If \(a\) is differentiable for \(r>0\), then for \(\mathbf{F}(\mathbf{x})=a(r)\mathbf{x}\), $$ \nabla\cdot\mathbf{F}=3a(r)+r a'(r), \qquad \nabla\times\mathbf{F}=\mathbf{0}, \qquad r>0. $$

To see the divergence, sum the diagonal entries of the Jacobian. Since \(x^2+y^2+z^2=r^2\), the sum is \(3a+(a'/r)r^2=3a+ra'\). For the curl, the Jacobian is symmetric: its \(i,j\) entry equals its \(j,i\) entry. Each component of the curl is a difference of such paired partial derivatives, so every component is zero. This proves both claims wherever the derivatives exist and \(r>0\).

For \(\mathbf{F}=f(r)\mathbf{x}/r\), substitute \(a(r)=f(r)/r\). Differentiating gives \(a'(r)=f'(r)/r-f(r)/r^2\). Thus \(3a+ra'=3f/r+f'-f/r=f'+2f/r\).

Radial-field formulas: For \(r>0\) and differentiable scalar functions, $$ \begin{aligned} \mathbf{F}(\mathbf{x})=f(r)\frac{\mathbf{x}}{r} &\quad\Longrightarrow\quad \nabla\cdot\mathbf{F}=f'(r)+\frac{2f(r)}{r}, \qquad \nabla\times\mathbf{F}=\mathbf{0},\\[4pt] \mathbf{F}(\mathbf{x})=g(r)\mathbf{x} &\quad\Longrightarrow\quad \nabla\cdot\mathbf{F}=3g(r)+r g'(r), \qquad \nabla\times\mathbf{F}=\mathbf{0}. \end{aligned} $$

Worked Examples

Worked Example: A Quadratically Growing Radial Magnitude

Let \(\mathbf{F}(\mathbf{x})=r^2\mathbf{x}/r\), for \(r>0\). Here \(f(r)=r^2\), so \(f'(r)=2r\). The formulas give

$$ \nabla\cdot\mathbf{F} = 2r+\frac{2r^2}{r} = 4r, \qquad \nabla\times\mathbf{F}=\mathbf{0}. $$

Check this directly at \(\mathbf{x}=(1,2,2)\). There \(r=\sqrt{1+4+4}=3\), and \(\mathbf{F}=r\mathbf{x}\). Its Jacobian is \(r\mathbf{I}+\mathbf{x}\mathbf{x}^{\top}/r\), so at this point it is

$$ \begin{pmatrix} 10/3 & 2/3 & 2/3\\ 2/3 & 13/3 & 4/3\\ 2/3 & 4/3 & 13/3 \end{pmatrix}. $$

The trace is \((10+13+13)/3=12\), agreeing with \(4r=12\). The matrix is symmetric, so the curl components, which are differences of paired off-diagonal entries, are all zero.

Worked Example: An Inverse-Cube Position-Vector Field

For \(r>0\), let \(\mathbf{F}(\mathbf{x})=\mathbf{x}/r^3\). In the position-vector form, \(g(r)=r^{-3}\) and \(g'(r)=-3r^{-4}\). Therefore

$$ \nabla\cdot\mathbf{F} = 3r^{-3}+r(-3r^{-4}) = 0, \qquad \nabla\times\mathbf{F}=\mathbf{0}. $$

To check the calculation, differentiate its components \(F_i=x_i r^{-3}\):

$$ \frac{\partial F_i}{\partial x_j} = \frac{\delta_{ij}}{r^3} - \frac{3x_i x_j}{r^5}. $$

This matrix is symmetric. Its trace is \(3/r^3-3(x^2+y^2+z^2)/r^5=3/r^3-3r^2/r^5=0\), as required. This check applies only when \(r>0\); the field itself is undefined at the origin.

Worked Example: A Radial Field with Nonzero Divergence

Let \(\mathbf{F}(\mathbf{x})=\mathbf{x}/r^2\), for \(r>0\). This is \(f(r)\mathbf{x}/r\) with \(f(r)=1/r\). Since \(f'(r)=-1/r^2\),

$$ \nabla\cdot\mathbf{F} = -\frac{1}{r^2}+\frac{2}{r}\frac{1}{r} = \frac{1}{r^2}, \qquad \nabla\times\mathbf{F}=\mathbf{0}. $$

At \((1,0,0)\), \(r=1\). Writing \(\mathbf{F}=a(r)\mathbf{x}\) gives \(a(r)=r^{-2}\) and \(a'(r)=-2r^{-3}\). The Jacobian is \(a\mathbf{I}+(a'/r)\mathbf{x}\mathbf{x}^{\top}\); at this point it is the diagonal matrix with entries \(-1,1,1\). Its trace is \(1\), matching \(1/r^2=1\), and its off-diagonal entries are equal in opposite pairs, giving zero curl.

Why the Origin Requires Separate Attention

The formulas above are ordinary divergence and curl formulas on the punctured space \(r>0\). They do not automatically define either derivative at the origin. Both \(\mathbf{x}/r\) and \(\mathbf{x}/r^3\) are undefined there, and expressions such as \(f'(r)+2f(r)/r\) can also fail to have a finite limit as \(r\) approaches zero.

For example, the field \(\mathbf{F}=\mathbf{x}/r\) has \(f(r)=1\), so its divergence is \(2/r\) away from the origin. Its direction depends on the direction of approach to the origin, so assigning a value at the origin does not make this field continuous there. The field \(\mathbf{x}/r^3\) has zero divergence at every point where it is defined, but that fact is not a claim that it has a divergence at the origin.

Some radial fields do extend smoothly to the origin. For instance, if \(f(r)=r\), then \(f(r)\mathbf{x}/r=\mathbf{x}\), including at the origin when defined by \(\mathbf{F}(\mathbf{0})=\mathbf{0}\). Its divergence is \(3\) and its curl is zero everywhere. The key is to check the field and its derivatives at the origin separately rather than substituting \(r=0\) into a formula derived for \(r>0\).

Important: A formula that holds at every point with \(r>0\) does not, by itself, determine behavior at \(r=0\). Verify whether the field is defined and differentiable at the origin before making a pointwise claim there.

A Common Formula Error

A frequent mistake is to calculate the divergence of \(f(r)\mathbf{x}/r\) as just \(f'(r)\), as though only the change in radial magnitude mattered. For \(f(r)=r^2\), that mistaken calculation gives \(2r\). It omits the change in the direction of the radial unit vector as position varies.

The correct result includes the additional term \(2f(r)/r\):

$$ f'(r)+\frac{2f(r)}{r} = 2r+\frac{2r^2}{r} = 4r. $$

The Cartesian derivation explains the correction: divergence sums changes in all three coordinate directions, and the radial components vary with position as well as with distance. A useful check is to rewrite the field as \(a(r)\mathbf{x}\), compute \(3a+ra'\), and then simplify.

Using the Two Forms Efficiently

Choose the form that matches the expression given. If the field is specified by its radial magnitude, \(f(r)\), use \(f'+2f/r\). If it is given as a scalar times the position vector, \(g(r)\mathbf{x}\), use \(3g+rg'\). Both forms give zero curl away from the origin under the differentiability assumptions used above.

Field representationDivergence for \(r>0\)Curl for \(r>0\)
\(f(r)\mathbf{x}/r\)\(f'(r)+2f(r)/r\)\(\mathbf{0}\)
\(g(r)\mathbf{x}\)\(3g(r)+rg'(r)\)\(\mathbf{0}\)

The two divergence formulas agree when \(f(r)=rg(r)\). In fact, \(f'(r)=g(r)+rg'(r)\), so \(f'(r)+2f(r)/r=g(r)+rg'(r)+2g(r)=3g(r)+rg'(r)\). This is a useful consistency check when changing representations.

Check Your Understanding

Use the formulas for \(r>0\), and state whether the origin needs separate consideration.

  1. For \(\mathbf{F}=r^3\mathbf{x}/r\), find the divergence and curl.
  2. For \(\mathbf{F}=r^{-2}\mathbf{x}\), find the divergence and curl.
  3. Rewrite \(f(r)\mathbf{x}/r\) in the form \(g(r)\mathbf{x}\). What is \(g(r)\)?
  4. Why does zero curl away from the origin not establish that a field has a curl at the origin?
  5. For \(\mathbf{F}=\mathbf{x}\), verify the divergence using both radial-field representations.