4  Differentiating vector fields

There are two commonly-used differential operators on vector fields in \(\Real^3\): the “curl” and the “divergence”.

These are more useful than individual partial derivatives of the components, because they are defined in a way that is independent of a particular choice of coordinates.

4.1 Curl

The curl of \(\fb(\xb)\) is the vector field \(\nabla\times\fb\) whose component in the direction \(\hat{\nb}\) is \[ (\nabla\times\fb)\cdot\hat{\nb} = \lim_{|A|\to 0}\frac{1}{|A|}\oint_C\fb\cdot\,d\xb, \] where \(C\) is a loop in the plane with normal \(\hat{\nb}\), and \(|A|\) is the area enclosed. The circulation is calculated in the right-handed direction relative to \(\hat{\nb}\).

Definition of curl.

Thus curl represents circulation per unit area of \(\fb\) around any possible direction. By definition it points in the direction with maximum circulation around it.

To find the Cartesian components of \(\nabla\times\fb\), we can use Green’s Theorem (Theorem 3.3). Let \(\hat{\nb}=\eb_3\), so \(C\) lies in the \(xy\)-plane. Then \[\begin{align*} (\nabla\times\fb)\cdot\eb_3 &= \lim_{|A|\to 0}\frac{1}{|A|}\oint_C\fb\cdot\,d\xb\\ &=\lim_{|A|\to 0}\frac{1}{|A|}\int_A\left(\ddy{f_2}{x} - \ddy{f_1}{y}\right)\,dA\\ &= \ddy{f_2}{x} - \ddy{f_1}{y}. \end{align*}\]

The last step is rigorously justified by the Mean Value Theorem for Double Integrals, which says that if \(g(\xb)\) is continuous on a closed, bounded and connected subset \(A\subset\Real^2\) then there exists \(\xb_0\in A\) such that \[ \int_A g(\xb)\,dA = |A|g(\xb_0). \]

This is a generalisation of the 1-d version \(\displaystyle\int_a^bf(x)\,dx = (b-a)f(x_0)\), as illustrated here:

The Mean Value Theorem for Integrals in 1-d.

Setting \(\displaystyle g(\xb)=\left(\ddy{f_2}{x} - \ddy{f_1}{y}\right)\) gives \[ \lim_{|A|\to 0}\frac{1}{|A|}\int_Ag(\xb)\,dA = \lim_{|A|\to 0}\frac{1}{|A|}|A|g(\xb_0) = \lim_{|A|\to 0}g(\xb_0) = g(\xb). \]

Applying Green’s Theorem to curves in the \(yz\)-plane or \(xz\)-plane, and taking care with the orientations, gives the other two Cartesian components:

Cartesian orientations.

\[\begin{align*} \nabla\times\fb &= \left(\ddy{f_3}{y} - \ddy{f_2}{z} \right)\eb_1 + \left(\ddy{f_1}{z} - \ddy{f_3}{x} \right)\eb_2 + \left(\ddy{f_2}{x} - \ddy{f_1}{y} \right)\eb_3\\ &= \begin{vmatrix} \eb_1 & \eb_2 & \eb_3\\ \displaystyle \ddy{}{x} & \displaystyle\ddy{}{y} & \displaystyle\ddy{}{z}\\ f_1 & f_2 & f_3 \end{vmatrix}. \end{align*}\]

This last expression explains the \(\nabla\times\fb\) notation, if we think of \(\nabla\) as the vector differential operator \[ \nabla = \eb_1\ddy{}{x} + \eb_2\ddy{}{y} + \eb_3\ddy{}{z}. \] You will also see the curl written as “\(\mathrm{curl}\,\fb\)” or in older books as “\(\mathrm{rot}\,\fb\)” (standing for “rotation”).

\[\begin{align*} \nabla\times\fb &= \begin{vmatrix} \eb_1 & \eb_2 & \eb_3\\ \displaystyle \ddy{}{x} & \displaystyle\ddy{}{y} & \displaystyle\ddy{}{z}\\ -\omega y & \omega x & 0 \end{vmatrix}\\ &= \left(\ddy{}{y}(0) - \ddy{}{z}(\omega x)\right)\eb_1 - \left(\ddy{}{x}(0) - \ddy{}{z}(-\omega y)\right)\eb_2 + \left(\ddy{}{x}(\omega x) - \ddy{}{y}(-\omega y)\right)\eb_3\\ &= 2\omega \eb_3. \end{align*}\]

This tells us that \(\fb\) has local circulation only around the \(z\)-direction.

If \(\omega>0\), then \((\nabla\times\fb)\cdot\eb_3 > 0\), indicating anti-clockwise circulation of the vector field. It is independent of \(x, y\), so \(\fb\) has the same circulation around every infinitesimal loop in the \(xy\)-plane:

The vector field.

A physical way to think of curl is to imagine \(\fb(\xb)\) to be the velocity field \(\vb(\xb)\) of a fluid. A small “paddle wheel” will align its axis with the direction of \(\nabla\times\vb\) and rotate with angular speed \(\propto|\nabla\times\vb|\).

The previous example corresponds to a rigid rotation of the fluid, where each particle of fluid follows the trajectory \(\xb(t) = r\cos(\omega t)\eb_1 + r\sin(\omega t)\eb_2\). The corresponding velocity field is \[ \vb(\xb) = \ddt{\xb} = -\omega r\sin(\omega t)\eb_1 + \omega r\cos(\omega t)\eb_2 = \omega(-y\eb_1 + x\eb_2). \] This velocity field has \(|\nabla\times\vb| = 2|\omega|\), i.e. twice the angular speed. The non-zero curl tells us that the paddle wheel rotates as it moves around the origin:

Rotation of a paddle wheel.

Clearly the partial derivatives don’t exist at \(\xb=\bfzero\) so the curl is not defined there.

For any other point, we have \[\begin{align*} \nabla\times\fb &= \begin{vmatrix} \eb_1 & \eb_2 & \eb_3\\ \displaystyle \ddy{}{x} & \displaystyle\ddy{}{y} & \displaystyle\ddy{}{z}\\ \displaystyle\frac{-y}{x^2+y^2} & \displaystyle\frac{x}{x^2+y^2} & 0 \end{vmatrix}\\ &= (0)\eb_1 + (0)\eb_2 + \left[\ddy{}{x}\left(\frac{x}{x^2+y^2}\right) - \ddy{}{y}\left(\frac{-y}{x^2+y^2}\right)\right]\eb_3\\ &= \left[\frac{(x^2+y^2) - 2x^2}{(x^2+y^2)^2} + \frac{(x^2+y^2) - 2y^2}{(x^2+y^2)^2}\right]\eb_3\\ &= \bfzero. \end{align*}\]

So (at least away from the origin) this vector field has no local circulation even though it is clearly rotating globally.

Rotation of a paddle wheel in the vortex.

[This more closely approximates the motion when you pull the plug in a bathtub – in fluid mechanics it is called a line vortex.]

From the Cartesian expression, we see that we the \(i\)th component of \(\nabla\times\fb\) may be written in index notation as \[ \big[\nabla\times\fb\big]_i = \epsilon_{ijk}\ddy{}{x_j}(f_k) = \epsilon_{ijk}\ddy{f_k}{x_j}. \]

The \(i\)th component is \[\begin{align*} \Big[\nabla\times(\nabla\times\fb)\Big]_i &= \epsilon_{ijk}\ddy{}{x_j}\left(\big[\nabla\times\fb\big]_k \right)\\ &= \epsilon_{ijk}\ddy{}{x_j}\Big(\epsilon_{klm}\ddy{}{x_l}(f_m)\Big)\\ &= \epsilon_{ijk}\epsilon_{klm}\ddy{}{x_j}\Big(\ddy{}{x_l}(f_m)\Big) \quad \textrm{[since $\epsilon_{klm}$ is a constant]}\\ &= \epsilon_{ijk}\epsilon_{klm}\ddy{}{x_j}\Big(\ddy{}{x_l}(r^2a_m)\Big)\\ &= \epsilon_{ijk}\epsilon_{klm}a_m\ddy{}{x_j}\Big(\ddy{}{x_l}(r^2)\Big) \quad \textrm{[since $a_m$ is a constant]}. \end{align*}\] Note that \(r^2=x^2 + y^2 + z^2\). So \(\displaystyle\ddy{}{x_l}(r^2) = 2x_l\). Therefore \[\begin{align*} \Big[\nabla\times(\nabla\times\fb)\Big]_i &=\epsilon_{ijk}\epsilon_{klm}a_m\ddy{}{x_j}(2x_l)\\ &= 2\epsilon_{ijk}\epsilon_{klm}a_m\delta_{jl}\\ &= 2(\delta_{il}\delta_{jm} - \delta_{im}\delta_{jl})\delta_{jl}a_m\\ &= 2\delta_{il}\delta_{jm}\delta_{jl}a_m - 2\delta_{im}\delta_{jl}\delta_{jl}a_m\\ &= 2\delta_{ij}a_j - 2\delta_{jj}a_i\\ &= 2a_i - 6a_i\\ &= -4a_i. \end{align*}\]

Proposition 4.1 (Properties of curl.) Let \(a,b\) be scalar constants, \(\fb(\xb)\), \(\gb(\xb)\) be vector fields, and \(h(\xb)\) be a scalar field, all in \(\Real^3\). Then

\((i)\;\;\) \(\nabla\times(a\fb + b\gb) = a\nabla\times\fb + b\nabla\times\gb.\)

\((ii)\;\;\) \(\nabla\times(h\fb) = (\nabla h)\times\fb + h\nabla\times\fb.\)

\((iii)\;\;\) \(\nabla\times(\nabla h) = \bfzero\).

Proof. \((i)\) This just follows from the linearity of partial differentiation.

\((ii)\) Using index notation, we have \[ \big[\nabla\times(h\fb)\big]_i = \epsilon_{ijk}\ddy{}{x_j}(hf_k). \] Since \(h\) and the \(f_k\) are both scalars, we can use the normal product rule from Calculus to find \[\begin{align*} \big[\nabla\times(h\fb)\big]_i &= \epsilon_{ijk}\left(\ddy{h}{x_j}f_k + h\ddy{f_k}{x_j} \right)\\ &= \epsilon_{ijk}\big[\nabla h\big]_j f_k + h \epsilon_{ijk}\ddy{f_k}{x_j}\\ &= \Big[(\nabla h) \times\fb \Big]_i + \Big[ h\nabla\times\fb \Big]_i. \end{align*}\] Here we used the fact that the \(j\)th component of \(\nabla h\) is \(\displaystyle\ddy{h}{x_j}\).

\((iii)\) Again using index notation, we have \[\begin{align*} \Big[\nabla\times(\nabla h)\Big]_i &= \epsilon_{ijk}\ddy{}{x_j}\left(\ddy{h}{x_k}\right)\\ &= \epsilon_{ijk}\ddy{}{x_k}\left(\ddy{h}{x_j}\right) \quad \textrm{[assuming $h$ is sufficiently smooth]}\\ &= \epsilon_{ikj}\ddy{}{x_j}\left(\ddy{h}{x_k}\right) \quad \textrm{[relabelling $j\leftrightarrow k$]}\\ &= -\epsilon_{ijk}\ddy{}{x_j}\left(\ddy{h}{x_k}\right) \quad \textrm{[using antisymmetry $\epsilon_{ikj}=-\epsilon_{ijk}$]}. \end{align*}\] Since this expression is equal to minus itself, it must be zero.


By “sufficiently smooth” in \((iii)\), I mean that the second partial derivatives \(\displaystyle\ddy{^2h}{x\partial y}\) and \(\displaystyle\ddy{^2h}{y\partial x}\) are continuous. This is the condition required for them to be equal, by Clairaut’s Theorem.

4.2 Divergence

The divergence of \(\fb(\xb)\) is the scalar field \[ \nabla\cdot\fb = \lim_{|V|\to 0}\frac{1}{|V|}\oint_S\fb\cdot\dS, \] where \(S\) is a closed surface enclosing a volume \(|V|\).

Definition of the divergence.

The divergence represents flux per unit volume of \(\fb\) away from a given point. A positive divergence means an outward flux, while a negative divergence means an inward flux.

To find the Cartesian expression for \(\nabla\cdot\fb\), consider an infinitesimal cube of side \(\delta\):

Infinitesimal cube.

From the definition, \(\displaystyle \nabla\cdot\fb = \lim_{\delta\to 0}\frac{1}{\delta^3}\sum_{i=1}^6\int_{S_i}\fb\cdot\hat{\nb}\,dS\), where \(S_i\) is the \(i\)th face.

The front face (say \(S_1\)) has normal \(\hat{\nb}=\eb_1\), so \[ \int_{S_1}\fb\cdot\hat{\nb}\,dS = \int_{S_1}\fb\cdot\eb_1\,dS = \int_{S_1}f_1\,dS = \delta^2f_1(\xb_1), \] where the last step used the Mean Value Theorem for Double Integrals, so that \(\xb_1\) is some (unknown) point on \(S_1\).

Repeating for the other five faces gives \[\begin{align*} \nabla\cdot\fb &= \lim_{\delta\to 0}\left(\frac{f_1(\xb_1)-f_1(\xb_2)}{\delta} + \frac{ f_2(\xb_3)-f_2(\xb_4)}{\delta} + \frac{f_3(\xb_5)-f_3(\xb_6)}{\delta}\right)\\ &= \ddy{f_1}{x} + \ddy{f_2}{y} + \ddy{f_3}{z}. \end{align*}\]

\[ \nabla\cdot\fb = \ddy{}{x}(-y) + \ddy{}{y}(x) + \ddy{}{z}(0) = 0. \] So here every infinitesimal cube has zero net flux of \(\fb\), in this case equal “inflow” and “outflow”:

A cube in the vector field.

A vector field with zero divergence is sometimes called solenoidal.

\[ \nabla\cdot\fb = \ddy{}{x}(x) + \ddy{}{y}(y) + \ddy{}{z}(z) = 3. \]

We can visualise \(\fb\) in the \(z=0\) plane:

Projection in the xy-plane.

Since \(\nabla\cdot\fb\) is constant, any infinitesimal cube has the same (net) outward flux. (If instead \(\nabla\cdot\fb<0\) then it would be an inward flux.)

Think of points of positive divergence as sources and points of negative divergence as sinks.

Divergence at a point.

From the Cartesian expression, we see that \(\nabla\cdot\fb\) may be written in index notation as \[ \nabla\cdot\fb = \ddy{}{x_j}(f_j) = \ddy{f_j}{x_j}. \]

Proposition 4.2 (Properties of divergence.) Let \(a,b\) be scalar constants, \(\fb(\xb)\), \(\gb(\xb)\) be vector fields, and \(h(\xb)\) be a scalar field, all in \(\Real^3\). Then

\((i)\;\;\) \(\nabla\cdot(a\fb + b\gb) = a\nabla\cdot\fb + b\nabla\cdot\gb\).

\((ii)\;\;\) \(\nabla\cdot(h\fb) = (\nabla h)\cdot\fb + h\nabla\cdot\fb\).

\((iii)\;\;\) \(\nabla\cdot(\nabla\times\fb) = \bfzero\).

Proof. \((i)\) This just follows from the linearity of partial differentiation.

\((ii)\) By the product rule, \(\displaystyle\nabla\cdot(h\fb) = \ddy{}{x_j}(hf_j) = \ddy{h}{x_j}f_j + h\ddy{f_j}{x_j} = (\nabla h)\cdot\fb + h\nabla\cdot\fb.\)

\((iii)\) We have \[\begin{align*} \ddy{}{x_j}\left(\epsilon_{jkl}\ddy{f_l}{x_k}\right) &= \epsilon_{jkl}\ddy{^2 f_l}{x_j\partial x_k}\\ &= \epsilon_{jkl}\ddy{^2 f_l}{x_k\partial x_j} \quad\textrm{[assuming $f_l$ is sufficiently smooth]}\\ &= \epsilon_{kjl}\ddy{^2 f_l}{x_j\partial x_k} \quad\textrm{[relabelling $j\leftrightarrow k$]}\\ &= -\epsilon_{jkl}\ddy{^2 f_l}{x_j\partial x_k} \quad\textrm{[using antisymmetry $\epsilon_{kjl}=-\epsilon_{jkl}$]}. \end{align*}\] Since this expression is equal to minus itself, it must be zero.


We define the Laplacian of a scalar field \(h(\xb)\) to be the second-derivative operator \[ \nabla^2 h = \nabla\cdot(\nabla h). \] (Sometimes written instead as \(\Delta h\).)

The Laplacian is the differential operator appearing in the Laplace equation \(\nabla^2 h = 0\) (hence the name), as well as the heat and wave equations. More on these partial differential equations next term!

In Cartesian coordinates, we have \[ \nabla\cdot(\nabla h) = \ddy{}{x_j}\left(\ddy{h}{x_j}\right) = \ddy{^2h}{x^2} + \ddy{^2h}{y^2} + \ddy{^2h}{z^2}. \] So here \[ \nabla^2 h = \ddy{}{x}(3x^2 - 3y^2) + \ddy{}{y}(-6xy) = 6x - 6x = 0. \]

Functions like this that solve \(\nabla^2 h=0\) are called harmonic functions.

If you study Complex Analysis II, you will know that both the real and imaginary parts of a differentiable complex function \(f(x+iy)=u(x,y) + iv(x,y)\) satisfy the Cauchy-Riemann equations \[ \ddy{u}{x} = \ddy{v}{y}, \quad \ddy{u}{y}=-\ddy{v}{x}. \] By differentiating you can show that \(\nabla^2 u = \nabla^2 v = 0\).

4.3 The Divergence Theorem

This is a generalisation of Green’s Theorem to a three-dimensional volume.

Theorem 4.1 (Divergence Theorem.) Let \(\fb(\xb)\) be a vector field with continuous partial derivatives on a region \(V\subset\Real^3\), and let \(S\) be the oriented closed surface that bounds \(V\) (with outward unit normal). Then \[ \oint_S\fb\cdot\dS = \int_V(\nabla\cdot\fb)\dV. \]

Volume for the Divergence Theorem.

This is also known as Gauss’ Theorem or sometimes Ostrogradsky’s Theorem.

An intuitive justification for Theorem 4.1 is given by approximating \(V\) with infinitesimal cubes:

Volume broken into cubes.

The volume integral is the sum of \(\nabla\cdot\fb\) over each cube. By definition of divergence, this is (in the limit) the integral of \(\fb\cdot\hat{\nb}\) over the cube surface, where \(\hat{\nb}\) is the outward normal. These surface integrals cancel between neighbouring cubes, leaving only the contribution from the boundary \(S\).

Proof. We follow a similar argument to Green’s Theorem (Theorem 3.3).

First, let \(\fb(\xb)=f_3(\xb)\eb_3\) and assume that \(V\) has the form \((x,y)\in A\), \(z_0(x,y)\leq z\leq z_1(x,y)\).

Domain for the Divergence Theorem proof.

Then \[\begin{align*} \int_V(\nabla\cdot\fb)\dV &= \int_V\ddy{f_3}{z}\,dV\\ &= \int_A\left(\int_{z_0(x,y)}^{z_1(x,y)}\ddy{f_3}{z}\,dz\right)\,dA\\ &= \int_A\Big[f_3\big(x,y,z_1(x,y)\big) - f_3\big(x,y,z_0(x,y)\big)\Big]\,dA \quad \textrm{[Fund. Thm. of Calculus]}. \end{align*}\] On the other hand, the top surface \(z=z_1(x,y)\) has parametrisation \(\xb = x\eb_1 + y\eb_2 + z_1(x,y)\eb_3\) giving normal vector \[ \ddy{\xb}{x}\times\ddy{\xb}{y} = \begin{vmatrix} \eb_1 & \eb_2 & \eb_3\\ 1 & 0 & \displaystyle\ddy{z_1}{x}\\ 0 & 1 & \displaystyle\ddy{z_1}{y} \end{vmatrix} = -\ddy{z_1}{x}\eb_1 - \ddy{z_1}{y}\eb_2 + \eb_3, \] and hence surface integral \[ \int_{z=z_1(x,y)}(f_3\eb_3)\cdot\dS = \int_A(f_3\eb_3)\cdot\left(\ddy{\xb}{x}\times\ddy{\xb}{y}\right)\,dA = \int_Af_3\big(x,y,z_1(x,y)\big)\,dA. \] Similarly the bottom surface has normal \(-\eb_3\) giving \[ \int_{z=z_0(x,y)}(f_3\eb_3)\cdot\dS = - \int_Af_3\big(x,y,z_0(x,y)\big)\,dA. \] There is no contribution from the vertical side face, so putting this together gives \[ \int_V\ddy{f_3}{z}\,dV = \oint_S(f_3\eb_3)\cdot\dS. \] For suitable domains a similar argument gives \[ \int_V\ddy{f_1}{x}\,dV = \oint_S(f_1\eb_1)\cdot\dS \quad \textrm{and} \quad \int_V\ddy{f_2}{y}\,dV = \oint_S(f_2\eb_2)\cdot\dS, \] and summing gives Theorem 4.1.

If \(V\) is a more complicated shape, it must first be broken into a sum over simpler subdomains.


The Divergence Theorem explains why the equation \[ \ddy{\phi}{t} + \nabla\cdot\Fb = 0 \] is called a conservation law. Integrating over some volume \(V\) (and assuming \(\displaystyle\ddy{\phi}{t}\) is continuous) gives \[ \ddt{}{\int_V\phi\,dV = -\oint_{\partial V}\Fb\cdot\dS}. \] This integral form of the conservation law says that the total amount of \(\phi\) in \(V\) changes only if there is a flux, \(\Fb\), through the boundary.

Recall from earlier that \[ \nabla\cdot(h\fb) = (\nabla h)\cdot\fb + h\nabla\cdot\fb. \] Integrating over a volume \(V\) gives \[\begin{align*} \int_V\nabla\cdot(h\fb)\dV &= \int_V(\fb\cdot\nabla h)\dV + \int_V(h\nabla\cdot\fb)\dV\\ \iff\quad \oint_S(h\fb)\cdot\dS &= \int_V(\fb\cdot\nabla h)\dV + \int_V(h\nabla\cdot\fb)\dV \quad \textrm{[by the Divergence Theorem]}. \end{align*}\] Rearranging gives the required formula.

This is analogous to integration by parts in single-variable Calculus.

Unlike curl, the divergence is defined for \(\fb\in\Real^n\) for any dimension \(n>0\). Moreover, the Divergence Theorem holds for any \(n\), where \(V\) is an \(n\)-dimensional volume bounded by an \((n-1)\)-dimensional surface \(S\).

4.4 Stokes’ Theorem

This is a second generalisation of Green’s Theorem.

Theorem 4.2 (Stokes’ Theorem.) Let \(S\) be an oriented surface whose boundary is the closed curve \(C\), and let \(\fb(\xb)\) be a vector field on \(S\) with continuous partial derivatives. Then \[ \int_S(\nabla\times\fb)\cdot\dS = \oint_{C}\fb\cdot\,d\xb, \] where the orientations of \(\dS\) and the line integral must be related in a right-handed sense.

Orientations for Stokes' Theorem.

If \(S\) is a region in the \(xy\)-plane, then \(\dS = \eb_3\,dS\) and Theorem 4.2 reduces to Green’s Theorem (Theorem 3.3). So Stokes’ Theorem is a generalisation of Green’s Theorem to curved surfaces.

An intuitive justification for Theorem 4.2 is given by approximating \(S\) as a polyhedron – for example by “triangulating”:

Approximating a surface by a polyhedron.

The surface integral is the sum of \((\nabla\times\fb)\cdot\hat{\nb}\,dS\) over each triangle. By definition of curl, this is (in the limit) the circulation around the triangle. Since \(\hat{\nb}\) has a consistent orientation, the line integrals cancel between neighbouring triangles, leaving only the contribution from the boundary \(C\).

Hemisphere bounded by circle.

Left-hand side. The curl is \[ \nabla\times\fb = \begin{vmatrix} \eb_1 & \eb_2 & \eb_3\\ \displaystyle\ddy{}{x} & \displaystyle\ddy{}{y} & \displaystyle\ddy{}{z}\\ z & x & -x \end{vmatrix} = 2\eb_2 + \eb_3. \] We can parametrize the surface using spherical polar coordinates as \[ \xb(\theta,\phi) = \sin\theta\cos\phi\eb_1 + \sin\theta\sin\phi\eb_2 + \cos\theta\eb_3, \quad \theta\in[0,\pi/2], \quad \phi\in[0,2\pi]. \] As we found earlier, \(\displaystyle \ddy{\xb}{\theta}\times\ddy{\xb}{\phi} = \sin\theta\xb\), which points upward (\(z\)-component > \(0\)). The surface integral is \[\begin{align*} \int_S(\nabla\times\fb)\cdot\dS &= \int_0^{2\pi}\int_0^{\pi/2}(\nabla\times\fb)\cdot\left(\ddy{\xb}{\theta}\times\ddy{\xb}{\phi}\right)\,d\theta\,d\phi\\ &= \int_0^{2\pi}\int_0^{\pi/2}\sin\theta(2\eb_2 + \eb_3)\cdot(x\eb_1 + y\eb_2 + z\eb_3)\,d\theta\,d\phi\\ &= \int_0^{2\pi}\int_0^{\pi/2}(2y+z)\sin\theta\,d\theta\,d\phi\\ &= \int_0^{2\pi}\int_0^{\pi/2}(2\sin^2\theta\sin\phi + \sin\theta\cos\theta)\,d\theta\,d\phi\\ &= \int_0^{2\pi}\int_0^{\pi/2}\frac12\sin(2\theta)\,d\theta\,d\phi\\ &= -\frac{\pi}{2}\Big[\cos(2\theta)\Big]_0^{\pi/2} = \pi. \end{align*}\]

Right-hand side. The boundary \(C\) is the circle \(x^2+y^2=1\), \(z=0\), which has the standard polar coordinate parametrisation \[ \xb(t) = \cos t\eb_1 + \sin t\eb_2, \quad t\in[0,2\pi]. \] Notice that this traces \(C\) anti-clockwise, which is consistent with the upward orientation of the surface normal. This parametrisation gives tangent vector \(\displaystyle \ddt{\xb}= -\sin t\eb_1 + \cos t\eb_2,\) so the circulation is \[\begin{align*} \oint_C\fb\cdot\,d\xb &= \int_0^{2\pi}\fb\cdot\ddt{\xb}\,dt\\ &= \int_0^{2\pi}(\cos{t}\eb_2 - \cos{t}\eb_3)\cdot(-\sin t\eb_1 + \cos t\eb_2)\,dt\\ &= \int_0^{2\pi}\cos^2{t}\,dt = \pi. \end{align*}\]

Stokes’ Theorem implies that \(\displaystyle\int_S(\nabla\times\fb)\cdot\dS\) will be the same for all surfaces \(S\) that share the same boundary curve \(C\).

Sometimes they are called capping surfaces for \(C\).

Disk bounded by circle.

We can parametrise the disk with polar coordinates \[ \xb(r,\theta) = r\cos\theta\eb_1 + r\sin\theta\eb_2, \quad r\in[0,1],\quad \theta\in[0,2\pi]. \] Then \[ \ddy{\xb}{r}\times\ddy{\xb}{\theta} = \begin{vmatrix} \eb_1 & \eb_2 & \eb_3\\ \cos\theta & \sin\theta & 0\\ -r\sin\theta & r\cos\theta & 0 \end{vmatrix} = r\eb_3, \] so \[\begin{align*} \int_{S'}(\nabla\times\fb)\cdot\dS &= \int_0^{2\pi}\int_0^1(\nabla\times\fb)\cdot\left(\ddy{\xb}{r}\times\ddy{\xb}{\theta}\right)\,dr\,d\theta\\ &= \int_0^{2\pi}\int_0^1r(2\eb_2 + \eb_3)\cdot\eb_3\,dr\,d\theta\\ &= \int_0^{2\pi}\int_0^1r\,dr\,d\theta = \int_0^{2\pi}\frac12\,d\theta = \pi. \end{align*}\] We get the same answer as before, because \(S'\) and \(S\) share the same boundary. (Again, we have to choose the appropriate orientation for it to work.)

Proof (of Theorem 4.2). Suppose \(S\) has parametrisation \(\xb(u,v)\), so \[\begin{align*} \int_S(\nabla\times\fb)\cdot\dS &= \int_U(\nabla\times\fb)\cdot\left(\ddy{\xb}{u}\times\ddy{\xb}{v}\right)\,du\,dv. \end{align*}\] The basic idea will be to apply Green’s Theorem to the region \(U\) in the \(uv\)-plane.

To simplify the integrand here it is neatest to use index notation. We have \[\begin{align*} (\nabla\times\fb)\cdot\left(\ddy{\xb}{u}\times\ddy{\xb}{v}\right) &= \left(\epsilon_{ijk}\ddy{f_k}{x_j}\right)\left( \epsilon_{ilm}\ddy{x_l}{u}\ddy{x_m}{v}\right)\\ &= \epsilon_{jki}\epsilon_{ilm}\ddy{f_k}{x_j}\ddy{x_l}{u}\ddy{x_m}{v}\\ &= (\delta_{jl}\delta_{km} - \delta_{jm}\delta_{kl})\ddy{f_k}{x_j}\ddy{x_l}{u}\ddy{x_m}{v} \quad \textrm{[by Lemma 1.1]}\\ &= \ddy{f_k}{x_j}\ddy{x_j}{u}\ddy{x_k}{v} - \ddy{f_k}{x_j}\ddy{x_k}{u}\ddy{x_j}{v}\\ &= \left(\ddy{f_k}{x_j}\ddy{x_j}{u} \right)\ddy{x_k}{v} - \left( \ddy{f_k}{x_j}\ddy{x_j}{v} \right)\ddy{x_k}{u}\\ &= \ddy{f_k}{u}\ddy{x_k}{v} - \ddy{f_k}{v}\ddy{x_k}{u} \quad \textrm{[by the chain rule]}\\ &= \ddy{\xb}{v}\cdot\ddy{\fb}{u} - \ddy{\xb}{u}\cdot\ddy{\fb}{v}. \end{align*}\]

Putting this into our surface integral gives \[\begin{align*} \int_S(\nabla\times\fb)\cdot\dS &= \int_U\left(\ddy{\xb}{v}\cdot\ddy{\fb}{u} - \ddy{\xb}{u}\cdot\ddy{\fb}{v} \right)\,du\,dv\\ &= \int_U\left[\ddy{}{u}\left(\fb\cdot\ddy{\xb}{v} \right) -\fb\cdot\ddy{^2\xb}{u\partial v} - \ddy{}{v}\left(\fb\cdot\ddy{\xb}{u}\right) + \fb\cdot\ddy{^2\xb}{v\partial u} \right]\,du\,dv\\ &= \int_U\left[\ddy{}{u}\left(\fb\cdot\ddy{\xb}{v} \right) - \ddy{}{v}\left(\fb\cdot\ddy{\xb}{u}\right) \right]\,du\,dv\\ &= \oint_{\partial U}\left(\fb\cdot\ddy{\xb}{u}\,du + \fb\cdot\ddy{\xb}{v}\,dv \right) \quad \textrm{[by Green's Theorem]}\\ &= \oint_C\fb\cdot\,d\xb. \end{align*}\]


A classic application of Stokes’ Theorem is to derive Ampère’s law. Empirically, the magnetic field \(\Bb(\xb)\) integrated around a closed loop is proportional to the electric current passing through the loop: \[ \oint_C\Bb\cdot\,d\xb = \mu_0\int_S\Jb\cdot\dS, \] where \(\Jb\) is the current density (current per unit area) and \(\mu_0\) is a constant (the “permeability of free space”). Applying Stokes’ Theorem shows that \[ \int_S(\nabla\times\Bb)\cdot\,d\xb = \mu_0\int_S\Jb\cdot\dS, \] but since the loop was arbitrary we deduce Ampère’s Law \[ \nabla\times\Bb=\mu_0\Jb. \] Note the trick of deriving the local (i.e. differential) form of a physical law from the integral form.

There is a much more general form of Stokes’ Theorem in Differential Geometry, written elegantly as \[ \int_\Omega\mathrm{d}\omega = \int_{\partial\Omega}\omega. \] Here \(\Omega\) is a manifold, the operator \(\mathrm{d}\) is the exterior derivative, and the object \(\omega\) is a differential form. In fact, Green’s Theorem, our Stokes’ Theorem and the Divergence Theorem are all special cases of this result.

A mathematical corollary of Stokes’ Theorem is the following. Recall that a conservative vector field \(\fb=\nabla\phi\) has \(\nabla\times\fb=\bfzero\), because \(\nabla\times\nabla\phi=\bfzero\). But does \(\nabla\times\fb=\bfzero\) imply \(\fb=\nabla\phi\)?

Corollary 4.1 If \(\fb(\xb)\) has continuous first derivatives with \(\nabla\times\fb=\bfzero\) in a simply connected region \(V\subset\Real^3\), then there exists a differentiable scalar potential \(\phi\) in that region such that \(\fb=\nabla\phi\).

A region \(V\subset\Real^3\) is simply connected if any closed curve in \(V\) can be continuously shrunk to a point in \(V\). A ball (the interior of a sphere) is simply connected, but a toroid (interior of a torus) is not:

Ball and toroid.

Proof. Recall that \(\fb=\nabla\phi\) if and only if \(\fb\) has path independent line integrals (Theorem 3.2), so consider two arbitrary curves \(C_1, C_2\) between the same two endpoints \(\ab, \bb \in V\). Then \[ \int_{C_1}\fb\cdot\,d\xb - \int_{C_2}\fb\cdot\,d\xb = \int_C\fb\cdot\,d\xb, \] where \(C\) is defined as “\(C_1-C_2\)”:

Definition of paths.

Since \(V\) is simply connected, we can always find a capping surface \(S\) for \(C\) that lies wholly within \(V\). Then \(\nabla\times\fb=\bfzero\) everywhere on that surface so Stokes’ Theorem gives \[ \int_C\fb\cdot\,d\xb = 0 \quad \implies \int_{C_1}\fb\cdot\,d\xb = \int_{C_2}\fb\cdot\,d\xb. \]


Recall that this vector field has \(\nabla\times\fb=\bfzero\) for \(\xb\neq\bfzero\).

But we cannot apply Stokes’ Theorem since the region \(\Real^2\backslash\{\bfzero\}\) is not simply connected. (There is a “hole” at \(\xb=\bfzero\).)

Indeed, if \(C\) is the unit circle \(x^2+y^2=1\), then Stokes’ Theorem would suggest that \(\displaystyle\oint_C\fb\cdot\,d\xb=\int_S(\bfzero)\cdot\dS=0\), but in fact a direct calculation (check!) shows that \(\displaystyle\oint_C\fb\cdot\,d\xb = 2\pi.\)

This non-zero circulation means that \(\fb\) is not a conservative vector field.

This result shows us that there is a deep relation between the topology of a domain and the types of vector fields that can exist on that domain, owing to the constraints of continuity.