$$ \def\ab{\boldsymbol{a}} \def\bb{\boldsymbol{b}} \def\cb{\boldsymbol{c}} \def\db{\boldsymbol{d}} \def\eb{\boldsymbol{e}} \def\fb{\boldsymbol{f}} \def\gb{\boldsymbol{g}} \def\hb{\boldsymbol{h}} \def\kb{\boldsymbol{k}} \def\nb{\boldsymbol{n}} \def\tb{\boldsymbol{t}} \def\ub{\boldsymbol{u}} \def\vb{\boldsymbol{v}} \def\xb{\boldsymbol{x}} \def\yb{\boldsymbol{y}} \def\Ab{\boldsymbol{A}} \def\Bb{\boldsymbol{B}} \def\Cb{\boldsymbol{C}} \def\Eb{\boldsymbol{E}} \def\Fb{\boldsymbol{F}} \def\Jb{\boldsymbol{J}} \def\Lb{\boldsymbol{L}} \def\Rb{\boldsymbol{R}} \def\Ub{\boldsymbol{U}} \def\xib{\boldsymbol{\xi}} \def\evx{\boldsymbol{e}_x} \def\evy{\boldsymbol{e}_y} \def\evz{\boldsymbol{e}_z} \def\evr{\boldsymbol{e}_r} \def\evt{\boldsymbol{e}_\theta} \def\evp{\boldsymbol{e}_r} \def\evf{\boldsymbol{e}_\phi} \def\evb{\boldsymbol{e}_\parallel} \def\omb{\boldsymbol{\omega}} \def\dA{\;d\Ab} \def\dS{\;d\boldsymbol{S}} \def\dV{\;dV} \def\dl{\mathrm{d}\boldsymbol{l}} \def\bfzero{\boldsymbol{0}} \def\Rey{\mathrm{Re}} \def\Real{\mathbb{R}} \newcommand{\dds}[1]{\frac{d{#1}}{ds}} \newcommand{\ddy}[2]{\frac{\partial{#1}}{\partial{#2}}} \newcommand{\ddt}[1]{\frac{d{#1}}{dt}} \newcommand{\DDt}[1]{\frac{\mathrm{D}{#1}}{\mathrm{D}t}} $$
A vector field on \(\Real^3\) is a map \(\fb\,:\,\Real^3\to\Real^3\). Intuitively, it prescribes a vector at each point in space, \(\fb(\xb) = f_1(\xb)\eb_1 + f_2(\xb)\eb_2 + f_3(\xb)\eb_3\).
We have already seen an example of a vector field, namely the gradient \(\nabla f\) of a scalar function.
A 2-d vector field may be visualised as a collection of arrows in the plane.
It’s harder to clearly visualise vector fields in 3-d, and there is a whole computer graphics literature on this problem. For example, https://cgl.ethz.ch/Downloads/Publications/Papers/2020/Gun20b/Gun20b.pdf.
In this topic, we will study the standard ways to integrate a vector field \(\fb(\xb)\) either (i) along a curve or (ii) over a surface, in order to obtain a scalar result.
3.1 Line integrals
If \(\fb(\xb)=\fb(x,y,z)\) is a vector field and \(C\) is an arc of a simple curve with arclength parametrisation \(\xb=\xb(s)\) for \(s\in[0,\ell]\), we define the line integral of \(\fb\) along \(C\) as \[ \int_C\fb\cdot\,d\xb = \int_C\fb\cdot\dds{\xb}\,ds. \]
Notice that this is just the scalar line integral of the component of \(\fb\) tangent to the curve.
For a general parametrization \(\xb(t)\), not necessarily arclength, we can use the chain rule to write \[ \int_C\fb\cdot\,d\xb = \int_C\fb\cdot\left(\ddt{\xb}\frac{dt}{ds}\right)\,ds = \int_C\fb\cdot\ddt{\xb}\,dt. \] Thus we can compute the line integral with any parametrisation of our choice.
Writing \(d\xb=dx\eb_1 + dy\eb_2 + dz\eb_3\) gives the alternative notation \[ \int_C\fb\cdot\,d\xb = \int_C\big(f_1\,dx + f_2\,dy + f_3\,dz\big). \]
The classic physical example of a line integral is the work done by a particle moving in a force field \(\Fb(\xb)\) under Newton’s second law \(m\ddot{\xb} = \Fb(\xb)\).
The work done between \(t=0\) and \(t=T\) is the change in kinetic energy \(\displaystyle K=\frac12 m\dot{\xb}\cdot\dot{\xb}\), given by \[ K(T)-K(0) = \int_0^T\ddt{K}\,dt = \int_0^Tm\dot{\xb}\cdot\ddot{\xb}\,dt = \int_0^T\Fb\cdot\dot{\xb}\,dt = \int_C\Fb\cdot\,d\xb, \] where \(C\) is the particle’s trajectory.
3.2 Conservative vector fields
A vector field \(\fb(\xb)\) is called conservative if \(\fb=\nabla\phi\) for some differentiable scalar field \(\phi(\xb)\), called a potential.
The line integral of a conservative vector field is easy to calculate.
Theorem 3.1 (Fundamental Theorem of Line Integrals.) If \(\phi(\xb)\) is a scalar field, and \(C\) is a curve from \(\xb=\ab\) to \(\xb=\bb\), then \[ \int_C\nabla\phi\cdot\,d\xb = \phi(\bb) - \phi(\ab). \]
Proof. Integrating along \(C\) gives \[\begin{align*} \int_C\nabla\phi\cdot\,d\xb &= \int_0^\ell \nabla\phi\cdot\dds{\xb}\,ds\\ &= \int_0^\ell \left(\ddy{\phi}{x}\eb_1 + \ddy{\phi}{y}\eb_2 + \ddy{\phi}{z}\eb_3\right)\cdot\left(\dds{x}\eb_1 + \dds{y}\eb_2 + \dds{z}\eb_3\right)\,ds\\ &= \int_0^\ell\left(\ddy{\phi}{x}\dds{x} + \ddy{\phi}{y}\dds{y} + \ddy{\phi}{z}\dds{z}\right)\,ds\\ &= \int_0^\ell\dds{\phi}\,ds \quad \textrm{[by the chain rule]}\\ &= \phi(\bb) - \phi(\ab). \quad\textrm{[by the Fundamental Theorem of Calculus]} \end{align*}\]
Theorem 3.1 says that a line integral is the inverse of the gradient.
It is the first of several generalisations of the Fundamental Theorem of Calculus that we will meet. Indeed, if we consider a vector field \(\fb=\nabla\phi\) with \(\phi=\phi(x)\) and take \(C\) to be an interval on the \(x\)-axis, then the theorem reduces to \(\int_a^b\phi'(x)\,dx = \phi(b)-\phi(a)\).
The name “conservative” comes from Theorem 3.1. If you integrate along a closed path, in other words if \(\bb=\ab\), then \(\int_C\nabla\phi\cdot\,d\xb = 0\) so there is no net change in \(\phi\).
Force fields in nature have this property. For example, the gravitational field around a planet of mass \(M\) has the form \[ \Fb(\xb) = \nabla\left(\frac{GM}{|\xb|}\right), \] where \(G\) is the gravitational constant. If you move up then come back down to the same height, the net work done against gravity is zero (i.e., you don’t gain or lose any energy).
There is an important corollary to this result.
Corollary 3.1 (Path independence.) If \(C_1\), \(C_2\) are any two curves from \(\xb=\ab\) to \(\xb=\bb\), and \(\fb=\nabla\phi\), then \[ \int_{C_1}\fb\cdot\,d\xb = \int_{C_2}\fb\cdot\,d\xb. \]
Proof. Since \(\fb=\nabla\phi\), by Theorem 3.1, both integrals are equal to \(\phi(\bb)-\phi(\ab)\). They depend only on the endpoints and are independent of the path taken between.
What about the converse to Corollary 3.1? Are conservative vector fields the only ones with path independent line integrals?
Theorem 3.2 (Path independence.) The vector field \(\fb(\xb)\) has path independent line integrals between any pair of points if and only if \(\fb=\nabla\phi\).
Proof. Corollary 3.1 already showed that conservative fields have path-independent line integrals. So suppose that \(\fb\) has path-indepedendent line integrals. Define the scalar field \[ \phi(\xb) = \int_{C(\xb)}\fb\cdot\,d\xb, \] where \(C(\xb)\) is any curve going from the origin to \(\xb\). We claim that this scalar field satisfies \(\nabla\phi = \fb\).
To show that \(\displaystyle\ddy{\phi}{z}=f_3\), choose (thanks to path-independence) a curve consisting of three straight lines:
These have parametrisations: \[\begin{align*} &C_1:\quad \xb(t) = t\eb_1, \quad t\in[0,x] \quad \implies \ddt{\xb} = \eb_1,\\ &C_2:\quad \xb(t) = x\eb_1 + t\eb_2, \quad t\in[0,y] \quad \implies \ddt{\xb} = \eb_2,\\ &C_3:\quad \xb(t) = x\eb_1 + y\eb_2 + t\eb_3, \quad t\in[0,z] \quad \implies \ddt{\xb} = \eb_3. \end{align*}\] Therefore \[\begin{align*} \phi(\xb) &= \int_{C_1}\fb\cdot\,d\xb + \int_{C_2}\fb\cdot\,d\xb + \int_{C_3}\fb\cdot\,d\xb\\ &= \int_0^xf_1(t,0,0)\,dt + \int_0^y f_2(x,t,0)\,dt + \int_0^zf_3(x,y,t)\,dt. \end{align*}\] Differentiating with respect to \(z\) gives \[ \ddy{\phi}{z} = \ddy{}{z}\int_0^zf_3(x,y,t)\,dt = f_3(x,y,z). \] A similar argument works for the other two components.
We will see an easier way to test whether a vector field is conservative when we introduce the “curl” in Topic 4.
3.3 Circulation
If the curve is closed, meaning \(\xb(0)=\xb(\ell)\), then the line integral of \(\fb\) is written \[ \oint_C\fb\cdot\,d\xb \] and is called the circulation of \(\fb\) around \(C\).
If \(C\) lies in the \(xy\)-plane then by convention it is traversed anti-clockwise.
Circulation plays an important role in aeroplane flight. The Kutta-Joukowski theorem from fluid mechanics says that the lift force on a 2-d wing is given by \[ L=-\rho_\infty V_\infty\oint_C\vb\cdot\dS, \] where \(\rho_\infty\) and \(V_\infty\) are the background air density and speed (far) upstream of the wing, and \(\vb\) is the velocity field of the air.
The circulation is generated when the plane starts moving and is maintained throughout the flight.
The Magnus effect – explaining why spinning balls are deflected sideways – is similar.
If we have a conservative vector field \(\fb=\nabla\phi\), then it follows immediately from Theorem 3.1 that \[ \oint_C\nabla\phi\cdot\,d\xb = 0 \] around any closed curve \(C\).
In fact there is a neat (albeit non-zero) formula for circulation even when \(\fb\) is not conservative.
We will consider here only curves lying in the \(xy\)-plane. (We will see the result for more general curves in Topic 4.) Think of a curve \(C\), or collection of curves \(C\), as the boundary of a region \(A\):
Theorem 3.3 (Green’s Theorem.) Let \(\fb\) be a vector field with continuous partial derivatives, and let \(A\subset \Real^2\) be a bounded region whose boundary \(C\) is a finite collection of piecewise-smooth curves. If \(C\) is traversed with \(A\) on the left, then \[ \oint_C\fb\cdot\,d\xb = \int_A\left(\ddy{f_2}{x} - \ddy{f_1}{y} \right)\,dA. \]
To get a simple intuition for Green’s Theorem, think about an infinitesimal square:
Proof. First let \(\fb=f_2(x,y)\eb_2\), and suppose \(A\) is an x-simple domain:
Then \[ \oint_C\fb\cdot\,d\xb = \int_{C_1}\fb\cdot\,d\xb - \int_{C_0}\fb\cdot\,d\xb. \] (The integrals along \(C_B\) and \(C_T\) vanish because \(\fb\cdot\eb_1 = 0\).) Parametrise as follows: \[\begin{align*} &C_0: \quad \xb(t) = x_0(t)\eb_1 + t\eb_2,\quad t\in[y_0,y_1] \quad \implies \ddt{\xb} = x_0'(t)\eb_1 + \eb_2,\\ &C_1: \quad \xb(t) = x_1(t)\eb_1 + t\eb_2,\quad t\in[y_0,y_1] \quad \implies \ddt{\xb} = x_1'(t)\eb_1 + \eb_2. \end{align*}\] Then \[\begin{align*} \oint_C\fb\cdot\,d\xb &= \int_{y_0}^{y_1}f_2\big(x_1(t),t\big)\,dt - \int_{y_0}^{y_1}f_2\big(x_0(t),t\big)\,dt\\ &= \int_{y_0}^{y_1}\Big[f_2\big(x_1(y),y\big) - f_2\big(x_0(y),y\big) \Big]\,dy\\ &= \int_{y_0}^{y_1}\int_{x_0(y)}^{x_1(y)}\ddy{f_2}{x}\,dx\,dy \quad \textrm{[Fundamental Thm of Calculus]}\\ &= \int_A\ddy{f_2}{x}\,dA. \quad (\mathrm{a}) \end{align*}\]
Now let \(\fb=f_1(x,y)\eb_1\) and suppose \(A\) is y-simple:
Repeating the argument but noting the opposite signs of the curves gives \[ \oint_C\fb\cdot\,d\xb = \int_{x_0}^{x_1}\Big[f_1\big(x,y_0(x)\big) - f_1\big(x,y_1(x)\big)\Big]\,dx = -\int_A\ddy{f_1}{y}\,dA. \quad (\mathrm{b}) \]
Adding (a) and (b) gives Green’s Theorem for the case where \(A\) is both x-simple and y-simple.
The result extends to any bounded piecewise-smooth domain by decomposing it into simple subdomains, and noting that the line integrals cancel between neighbouring regions on the internal boundaries, just leaving the portions on the global boundary \(C\).
We needed continuous partial derivatives \(\displaystyle\ddy{f_2}{x}\),\(\displaystyle\ddy{f_1}{y}\) to apply the Fundamental Theorem of Calculus.
3.4 Surface integrals
If \(\fb(\xb)\) is a vector field and \(S\) is an oriented surface, we define the flux of \(\fb\) through \(S\) as the surface integral \[ \int_S\fb\cdot\dS = \int_S\fb\cdot\hat{\nb}\,dS, \] where \(\hat{\nb}\) is the unit normal to the surface.
The vector surface element \(\dS = \hat{\nb}\,dS\) has direction pointing normal to the surface and magnitude given by the infinitesimal area element \(dS\).
Notice that the sign of \(\int_S\fb\cdot\dS\) depends on the chosen sign of \(\hat{\nb}\). Here oriented surface means that we have specified the sign of \(\hat{\nb}\), which is possible consistently provided the surface is orientable.
We usually calculate the surface integral with a parametrisation \(\xb(u,v)\) of \(S\), in which case (from Section 2.4) the unit normal is \[ \hat{\nb} = \frac{\displaystyle\ddy{\xb}{u}\times\ddy{\xb}{v}}{\displaystyle\left|\ddy{\xb}{u}\times\ddy{\xb}{v}\right|}, \] so \[ \int_S\fb\cdot\dS = \int_U \fb\big(\xb(u,v)\big)\cdot\left(\ddy{\xb}{u}\times\ddy{\xb}{v}\right)\,du\,dv, \] where \(U\) is the appropriate region in \((u,v)\) space.
The flux contribution from the infinitesimal patch \(dS\) is the scalar triple product \[ \fb\cdot\left(\ddy{\xb}{u}\times\ddy{\xb}{v}\right)\,du\,dv, \] so can be visualised as the volume of a parallelepiped sticking out of the surface:
If \(\fb\) represents the velocity field of a fluid, then this contains precisely the fluid that flows through the surface during one unit of time. Hence the name “flux”.
If the surface is closed, we (often) write \(\displaystyle\oint_S\fb\cdot\dS\), similar to a line integral over a closed curve. In that case, there is a convention that \(\hat{\nb}\) points outward.
In electromagnetism – for which much of vector calculus was originally developed – Gauss’ law relates the flux of an electric field \(\Eb\) through a closed surface to the net electric charge \(Q\) enclosed by the surface: \[ \oint_S\Eb\cdot\dS = Q. \] If we assume by symmetry that \(\Eb = E\hat{\nb}\) (for \(E\) constant), then we can invert the surface integral: \[ \oint_SE\,dS = Q \quad \implies E = \frac{Q}{\textrm{[surface area of $S$]}}. \] If \(S\) is a sphere of radius \(R\), then \(\displaystyle E = \frac{Q}{4\pi R^2}\).
This gives the famous Coulomb (inverse-square) law for the electrostatic force on one point charge from another. The force on a point charge \(q_1\) at \(\xb=\xb_1\) is \(\Fb = q_1\Eb(\xb_1)\). The electric field arises from the other point charge \(q_2\) at \(\xb=\xb_2\), so \[ \Eb(\xb_1) = \frac{q_2}{4\pi|\xb_1 - \xb_2|^2} \quad \implies \Fb = \frac{q_1q_2}{4\pi|\xb_1-\xb_2|^2}. \] [This is like gravity except that it can be repulsive as well as attractive, depending on the relative signs of \(q_1\) and \(q_2\).]