# Divergence and Curl

- Last updated

- Save as PDF

- Page ID
- 21059

\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

\( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

\( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

\( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

\( \newcommand{\Span}{\mathrm{span}}\)

\( \newcommand{\id}{\mathrm{id}}\)

\( \newcommand{\Span}{\mathrm{span}}\)

\( \newcommand{\kernel}{\mathrm{null}\,}\)

\( \newcommand{\range}{\mathrm{range}\,}\)

\( \newcommand{\RealPart}{\mathrm{Re}}\)

\( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

\( \newcommand{\Argument}{\mathrm{Arg}}\)

\( \newcommand{\norm}[1]{\| #1 \|}\)

\( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

\( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

\( \newcommand{\vectorA}[1]{\vec{#1}} % arrow\)

\( \newcommand{\vectorAt}[1]{\vec{\text{#1}}} % arrow\)

\( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

\( \newcommand{\vectorC}[1]{\textbf{#1}} \)

\( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

\( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

\( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

\( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

\( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

\(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)##### Learning Objectives

- Determine divergence from the formula for a given vector field.
- Determine curl from the formula for a given vector field.
- Use the properties of curl and divergence to determine whether a vector field is conservative.

In this section, we examine two important operations on a vector field: divergence and curl. They are important to the field of calculus for several reasons, including the use of curl and divergence to develop some higher-dimensional versions of the Fundamental Theorem of Calculus. In addition, curl and divergence appear in mathematical descriptions of fluid mechanics, electromagnetism, and elasticity theory, which are important concepts in physics and engineering. We can also apply curl and divergence to other concepts we already explored. For example, under certain conditions, a vector field is conservative if and only if its curl is zero.

In addition to defining curl and divergence, we look at some physical interpretations of them, and show their relationship to conservative and source-free vector fields.

## Divergence

Divergence is an operation on a vector field that tells us how the field behaves toward or away from a point. Locally, the divergence of a vector field \(\vecs{F}\) in \(\mathbb{R}^2\) or \(\mathbb{R}^3\) at a particular point \(P\) is a measure of the “outflowing-ness” of the vector field at \(P\). If \(\vecs{F}\) represents the velocity of a fluid, then the divergence of \(\vecs{F}\) at \(P\) measures the net rate of change with respect to time of the amount of fluid flowing away from \(P\) (the tendency of the fluid to flow “out of” P). In particular, if the amount of fluid flowing into \(P\) is the same as the amount flowing out, then the divergence at \(P\) is zero.

##### Definition: divergence in \(\mathbb{R}^3\)

If \(\vecs{F} = \langle P,Q,R \rangle\) is a vector field in \(\mathbb{R}^3\) and \(P_x, \, Q_y, \) and \(R_z\) all exist, then the divergence of \(\vecs{F}\) is defined by

\[\begin{align} \text{div}\, F &= P_x + Q_y + R_z \\[4pt] &= \dfrac{\partial P}{\partial x} + \dfrac{\partial Q}{\partial y} + \dfrac{\partial R}{\partial z}. \end{align} \nonumber \]

Note the divergence of a vector field is not a vector field, but a scalar function. In terms of the gradient operator

\[\vecs \nabla = \langle \dfrac{\partial}{\partial x}, \dfrac{\partial}{\partial y}, \dfrac{\partial}{\partial z} \rangle \nonumber \]

divergence can be written symbolically as the dot product

\[\text{div}\, \vecs F = \vecs \nabla \cdot \vecs{F}. \nonumber \]

Note this is merely helpful notation, because the dot product of a vector of operators and a vector of functions is not meaningfully defined given our current definition of dot product.

If \(\vecs{F} = \langle P,Q \rangle\) is a vector field in \(\mathbb{R}^2\), and \(P_x\) and \(Q_y\) both exist, then the divergence of \(\vecs{F}\) is defined similarly as

\[\begin{align*} \text{div}\, \vecs{F} &= P_x + Q_y \\[4pt] &= \dfrac{\partial P}{\partial x} + \dfrac{\partial Q}{\partial y} \\[4pt] &= \vecs \nabla \cdot \vecs{F}. \end{align*}\]

To illustrate this point, consider the two vector fields in Figure \(\PageIndex{1}\). At any particular point, the amount flowing in is the same as the amount flowing out, so at every point the “outflowing-ness” of the field is zero. Therefore, we expect the divergence of both fields to be zero, and this is indeed the case, as

\[\text{div}(\langle 1,2 \rangle ) = \dfrac{\partial}{\partial x} (1) + \dfrac{\partial}{\partial y}(2) = 0 \nonumber \]

and

\[\text{div}(\langle -y,x \rangle ) = \dfrac{\partial}{\partial x} (-y) + \dfrac{\partial}{\partial y} (x) = 0. \nonumber \]

By contrast, consider radial vector field \(\vecs{R} (x,y) = \langle -x, -y \rangle\) in Figure \(\PageIndex{2}\). At any given point, more fluid is flowing in than is flowing out, and therefore the “outgoingness” of the field is negative. We expect the divergence of this field to be negative, and this is indeed the case, as

\[\text{div}(\vecs{R}) = \dfrac{\partial}{\partial x} (-x) + \dfrac{\partial}{\partial y} (-y) = -2. \nonumber \]

To get a global sense of what divergence is telling us, suppose that a vector field in \(\mathbb{R}^2\) represents the velocity of a fluid. Imagine taking an elastic circle (a circle with a shape that can be changed by the vector field) and dropping it into a fluid. If the circle maintains its exact area as it flows through the fluid, then the divergence is zero. This would occur for both vector fields in Figure \(\PageIndex{1}\). On the other hand, if the circle’s shape is distorted so that its area shrinks or expands, then the divergence is not zero. Imagine dropping such an elastic circle into the radial vector field in Figure \(\PageIndex{2}\) so that the center of the circle lands at point \((3, 3)\). The circle would flow toward the origin, and as it did so the front of the circle would travel more slowly than the back, causing the circle to “scrunch” and lose area. This is how you can see a negative divergence.

##### Example \(\PageIndex{1}\): Calculating Divergence at a Point

If \(\vecs{F}(x,y,z) = e^x \hat{i} + yz \hat{j} - yz^2 \hat{k}\), then find the divergence of \(\vecs{F}\) at \((0,2,-1)\).

**Solution**

The divergence of \(\vecs{F}\) is

\[\dfrac{\partial}{\partial x} (e^x) + \dfrac{\partial}{\partial y}(yz) - \dfrac{\partial}{\partial z} (y z^2) = e^x + z - 2yz. \nonumber \]

Therefore, the divergence at \((0,2,-1)\) is \(e^0 - 1 + 4 = 4\). If \(\vecs{F}\) represents the velocity of a fluid, then more fluid is flowing out than flowing in at point \((0,2,-1)\).

##### Exercise \(\PageIndex{1}\)

Find \(\text{div}\, \vecs{F}\) for

\[\vecs{F}(x,y,z) = \langle xy, \, 5-z^2, \, x^2 + y^2 \rangle \nonumber. \nonumber \]

**Hint**-
Follow Example \(\PageIndex{1}\).

**Answer**-
\(\text{div}\, \vecs{F} = y \)

Another application for divergence is detecting whether a field is source free. Recall that a source-free field is a vector field that has a stream function; equivalently, a source-free field is a field with a flux that is zero along any closed curve. The next two theorems say that, under certain conditions, source-free vector fields are precisely the vector fields with zero divergence.

##### Theorem: Divergence of a Source-Free Vector Field

If \(\vecs{F} = \langle P,Q \rangle\) is a source-free continuous vector field with differentiable component functions, then \(\text{div}\, \vecs{F} = 0\).

##### Proof

Since \(\vecs{F}\) is source free, there is a function \(g(x,y)\) with \(g_y = P\) and \(-g_x = Q\). Therefore, \(\vecs{F} = \langle g_y, -g_x \rangle\) and \(\text{div}\, \vecs{F} = g_{yx} - g_{xy} = 0\) by Clairaut’s theorem.

\(\square\)

The converse of Divergence of a Source-Free Vector Field is true on simply connected regions, but the proof is too technical to include here. Thus, we have the following theorem, which can test whether a vector field in \(\mathbb{R}^2\) is source free.

##### Theorem: Divergence Test for Source-Free Vector Fields

Let \(\vecs{F} = \langle P,Q \rangle \) be a continuous vector field with differentiable component functions with a domain that is simply connected. Then, \(\text{div}\, \vecs{F} = 0\) if and only if \(\vecs{F}\) is source free.

##### Example \(\PageIndex{3}\): Determining Whether a Field Is Source Free

Is field \(\vecs{F} (x,y) = \langle x^2 y, \, 5 - xy^2 \rangle\) source free?

**Solution**

Note the domain of \(\vecs{F}\) is \(\mathbb{R}^2\) which is simply connected. Furthermore, \(\vecs{F}\) is continuous with differentiable component functions. Therefore, we can use the Divergence Test for Source-Free Vector Fields to analyze \(\vecs{F}\). The divergence of \(\vecs{F}\) is

\[\dfrac{\partial}{\partial x} (x^2 y) + \dfrac{\partial}{\partial y} (5 - xy^2 ) = 2xy - 2xy = 0. \nonumber \]

Therefore, \(\vecs{F}\) is source free by the Divergence Test for Source-Free Vector Fields.

##### Exercise \(\PageIndex{2}\)

Let \(\vecs{F} (x,y) = \langle -ay, bx \rangle\) be a rotational field where \(a\) and \(b\) are positive constants. Is \(\vecs{F}\) source free?

**Hint**-
Calculate the divergence.

**Answer**-
Yes

Recall that the flux form of Green’s theorem says that

\[\oint_C \vecs F \cdot \vecs N \; ds = \iint_D P_x + Q_y \;dA, \nonumber \]

where \(C\) is a simple closed curve and \(D\) is the region enclosed by \(C\). Since \(P_x + Q_y = \text{div}\,\vecs F\), Green’s theorem is sometimes written as

\[\oint_C \vecs F \cdot \vecs N\; ds = \iint_D \text{div}\, \vecs F \;dA. \nonumber \]

Therefore, Green’s theorem can be written in terms of divergence. If we think of divergence as a derivative of sorts, then Green’s theorem says the “derivative” of \(\vecs{F}\) on a region can be translated into a line integral of \(\vecs{F}\) along the boundary of the region. This is analogous to the Fundamental Theorem of Calculus, in which the derivative of a function \(f\) on a line segment \([a,b]\) can be translated into a statement about \(f\) on the boundary of \([a,b]\). Using divergence, we can see that Green’s theorem is a higher-dimensional analog of the Fundamental Theorem of Calculus.

We can use all of what we have learned in the application of divergence. Let \(\vecs{v}\) be a vector field modeling the velocity of a fluid. Since the divergence of \(\vecs{v}\) at point \(P\) measures the “outflowing-ness” of the fluid at \(P\), \(\text{div}\, v(P) > 0\) implies that more fluid is flowing out of \(P\) than flowing in. Similarly, \(\text{div}\, v(P) < 0\) implies the more fluid is flowing in to \(P\) than is flowing out, and \(\text{div}\, \vecs{v}(P) = 0\) implies the same amount of fluid is flowing in as flowing out.

##### Example \(\PageIndex{4}\): Determining Flow of a Fluid

Suppose \(\vecs{v}(x,y) = \langle -xy,y \rangle, \, y > 0\) models the flow of a fluid. Is more fluid flowing into point \((1,4)\) than flowing out?

**Solution**

To determine whether more fluid is flowing into \((1,4)\) than is flowing out, we calculate the divergence of \(\vecs v\) at \((1,4)\):

\[div(\vecs{v}) = \dfrac{\partial}{\partial x} (-xy) + \dfrac{\partial}{\partial y} (y) = -y + 1. \nonumber \]

To find the divergence at \((1,4)\) substitute the point into the divergence: \(-4 + 1 = -3\). Since the divergence of \(\vecs v\) at \((1,4)\) is negative, more fluid is flowing in than flowing out (Figure \(\PageIndex{4}\)).

##### Exercise \(\PageIndex{3}\)

For vector field \(\vecs{v}(x,y) = \langle -xy, y \rangle , \, y > 0\), find all points \(P\) such that the amount of fluid flowing in to \(P\) equals the amount of fluid flowing out of \(P\).

**Hint**-
Find where the divergence is zero.

**Answer**-
All points on line \(y = 1\).

## Curl

The second operation on a vector field that we examine is the curl, which measures the extent of rotation of the field about a point. Suppose that \(\vecs{F}\) represents the velocity field of a fluid. Then, the curl of \(\vecs{F}\) at point \(P\) is a vector that measures the tendency of particles near \(P\) to rotate about the axis that points in the direction of this vector. The magnitude of the curl vector at \(P\) measures how quickly the particles rotate around this axis. In other words, the curl at a point is a measure of the vector field’s “spin” at that point. Visually, imagine placing a paddlewheel into a fluid at \(P\), with the axis of the paddlewheel aligned with the curl vector (Figure \(\PageIndex{5}\)). The curl measures the tendency of the paddlewheel to rotate.

Consider the vector fields in Figure \(\PageIndex{1}\). In part (a), the vector field is constant and there is no spin at any point. Therefore, we expect the curl of the field to be zero, and this is indeed the case. Part (b) shows a rotational field, so the field has spin. In particular, if you place a paddlewheel into a field at any point so that the axis of the wheel is perpendicular to a plane, the wheel rotates counterclockwise. Therefore, we expect the curl of the field to be nonzero, and this is indeed the case (the curl is \(2\,\mathbf{\hat k}\)).

To see what curl is measuring globally, imagine dropping a leaf into the fluid. As the leaf moves along with the fluid flow, the curl measures the tendency of the leaf to rotate. If the curl is zero, then the leaf doesn’t rotate as it moves through the fluid.

##### Definition: Curl

If \(\vecs{F} = \langle P,Q,R \rangle\) is a vector field in \(\mathbb{R}^3\), and \(P_x, \, Q_y\), and \(R_z\) all exist, then the curl of \(\vecs{F}\) is defined by

\[\begin{align} \text{curl}\, \vecs{F} &= (R_y - Q_z) \,\mathbf{\hat i} + (P_z - R_x) \,\mathbf{\hat j} + (Q_x - P_y) \,\mathbf{\hat k}\\[4pt]

&= \left( \dfrac{\partial R}{\partial y} - \dfrac{\partial Q}{\partial z} \right) \,\mathbf{\hat i} + \left( \dfrac{\partial P}{\partial z} - \dfrac{\partial R}{\partial x} \right) \,\mathbf{\hat j} + \left( \dfrac{\partial Q}{\partial x} - \dfrac{\partial P}{\partial y} \right) \,\mathbf{\hat k}. \end{align} \nonumber \]

Note that the curl of a vector field is a vector field, in contrast to divergence.

The definition of curl can be difficult to remember. To help with remembering, we use the notation \(\vecs \nabla \times \vecs{F}\) to stand for a “determinant” that gives the curl formula:

\[\begin{vmatrix} \hat{i} & \hat{j} & \hat{k} \\ \dfrac{\partial}{\partial x} & \dfrac{\partial}{\partial y} & \dfrac{\partial}{\partial z} \\ P & Q & R \end{vmatrix}. \nonumber \]

The determinant of this matrix is

\[(R_y - Q_z) \,\mathbf{\hat i} - (R_x - P_z) \,\mathbf{\hat j} + (Q_x - P_y) \,\mathbf{\hat k} = (R_y - Q_z) \,\mathbf{\hat i} + (P_z - R_x) \,\mathbf{\hat j} + (Q_x - P_y)\,\mathbf{\hat k} = \text{curl}\, \vecs{F}. \nonumber \]

Thus, this matrix is a way to help remember the formula for curl. Keep in mind, though, that the word *determinant* is used very loosely. A determinant is not really defined on a matrix with entries that are three vectors, three operators, and three functions.

If \(\vecs{F} = \langle P,Q \rangle\) is a vector field in \(\mathbb{R}^2\), then the curl of \(\vecs{F}\), by definition, is

\[\text{curl}\, \vecs{F} = (Q_x - P_y)\,\mathbf{\hat k} = \left(\dfrac{\partial Q}{\partial x} - \dfrac{\partial P}{\partial y} \right)\,\mathbf{\hat k}. \nonumber \]

##### Example \(\PageIndex{5}\): Finding the Curl of a Three-Dimensional Vector Field

Find the curl of \(\vecs{F}(P,Q,R) = \langle x^2 z, e^y + xz, xyz \rangle\).

**Solution**

The curl is

\[\begin{align*} \text{curl}\, f &= \vecs\nabla \times \vecs{F} \\ &= \begin{vmatrix} \mathbf{\hat i} & \mathbf{\hat j} & \mathbf{\hat k} \\ \partial/\partial x & \partial/\partial y & \partial / \partial z \\ P & Q & R \end{vmatrix} \\ &= (R_y - Q_z)\,\mathbf{\hat i} + (P_z - R_x)\,\mathbf{\hat j} + (Q_x - P_y)\,\mathbf{\hat k} \\ &= (xz - x)\,\mathbf{\hat i} + (x^2 - yz)\,\mathbf{\hat j} + z \,\mathbf{\hat k}. \end{align*}\]

##### Exercise \(\PageIndex{4}\)

Find the curl of \(\vecs{F} = \langle \sin x \, \cos z, \, \sin y \, \sin z, \, \cos x \, \cos y \rangle \) at point \(\left(0, \dfrac{\pi}{2}, \dfrac{\pi}{2} \right)\).

**Hint**-
Find the determinant of matrix \(\vecs \nabla \times \vecs{F}\).

**Answer**-
\(-\hat{i}\)

##### Example \(\PageIndex{6}\): Finding the Curl of a Two-Dimensional Vector Field

Find the curl of \(\vecs{F} = \langle P,Q \rangle = \langle y,0\rangle\).

**Solution**

Notice that this vector field consists of vectors that are all parallel. In fact, each vector in the field is parallel to the *x*-axis. This fact might lead us to the conclusion that the field has no spin and that the curl is zero. To test this theory, note that

\[\text{curl}\, \vecs{F} = (Q_x - P_y)\,\mathbf{\hat k} = -\,\mathbf{\hat k} \neq \vecs 0. \nonumber \]

Therefore, this vector field does have spin. To see why, imagine placing a paddlewheel at any point in the first quadrant (Figure \(\PageIndex{6}\)). The larger magnitudes of the vectors at the top of the wheel cause the wheel to rotate. The wheel rotates in the clockwise (negative) direction, causing the coefficient of the curl to be negative.

Note that if \(\vecs{F} = \langle P,Q\rangle\) is a vector field in a plane, then \(\text{curl}\, \vecs{F} \cdot \mathbf{\hat k} = (Q_x - P_y)\,\mathbf{\hat k} \cdot \mathbf{\hat k} = Q_x - P_y\). Therefore, the circulation form of Green’s theorem is sometimes written as

\[\oint_C \vecs{F} \cdot d\vecs{r} = \iint_D \text{curl}\, \vecs F \cdot \,\mathbf{\hat k}\,dA, \nonumber \]

where \(C\) is a simple closed curve and \(D\) is the region enclosed by \(C\). Therefore, the circulation form of Green’s theorem can be written in terms of the curl. If we think of curl as a derivative of sorts, then Green’s theorem says that the “derivative” of \(\vecs{F}\) on a region can be translated into a line integral of \(\vecs{F}\) along the boundary of the region. This is analogous to the Fundamental Theorem of Calculus, in which the derivative of a function \(f\) on line segment \([a,b]\) can be translated into a statement about \(f\) on the boundary of \([a,b]\). Using curl, we can see the circulation form of Green’s theorem is a higher-dimensional analog of the Fundamental Theorem of Calculus.

We can now use what we have learned about curl to show that gravitational fields have no “spin.” Suppose there is an object at the origin with mass \(m_1\) at the origin and an object with mass \(m_2\). Recall that the gravitational force that object 1 exerts on object 2 is given by field

\[ \vecs{F}(x,y,z) = - Gm_1m_2 \left\langle \dfrac{x}{(x^2 + y^2 + z^2 )^{3/2}}, \dfrac{y}{(x^2 + y^2 + z^2 )^{3/2}}, \dfrac{z}{(x^2 + y^2 + z^2 )^{3/2}}\right\rangle. \nonumber \]

##### Example \(\PageIndex{7}\): Determining the Spin of a Gravitational Field

Show that a gravitational field has no spin.

**Solution**

To show that \(\vecs{F}\) has no spin, we calculate its curl. Let

- \(P(x,y,z) = \dfrac{x}{(x^2 + y^2 + z^2 )^{3/2}}\),
- \(Q(x,y,z) = \dfrac{y}{(x^2 + y^2 + z^2 )^{3/2}}\), and
- \(R(x,y,z) = \dfrac{z}{(x^2 + y^2 + z^2 )^{3/2}}\).

Then,

\[\begin{align*} \text{curl}\, \vecs{F} &= - Gm_1m_2 [(R_y - Q_z)\mathbf{\hat i} + (P_z - R_x)\mathbf{\hat j} + (Q_x - P_y)\mathbf{\hat k}] \\[4pt]

&= - Gm_1m_2 \begin{pmatrix} \left(\dfrac{-3yz}{(x^2 + y^2 + z^2 )^{5/2}} - \left(\dfrac{-3yz}{(x^2 + y^2 + z^2 )^{5/2}} \right) \right)\mathbf{\hat i} \nonumber \\[4pt]

+ \left(\dfrac{-3xz}{(x^2 + y^2 + z^2 )^{5/2}} - \left(\dfrac{-3xz}{(x^2 + y^2 + z^2 )^{5/2}} \right) \right) \mathbf{\hat j} \nonumber \\[4pt]

+ \left(\dfrac{-3xy}{(x^2 + y^2 + z^2 )^{5/2}} - \left(\dfrac{-3xy}{(x^2 + y^2 + z^2 )^{5/2}} \right) \right) \mathbf{\hat k} \end{pmatrix} \\[4pt]

&= \vecs 0. \end{align*}\]

Since the curl of the gravitational field is zero, the field has no spin.

##### Exercise \(\PageIndex{7}\)

Field \(\vecs{v}(x,y) = \langle - \dfrac{y}{x^2+y^2}, \dfrac{x}{x^2+y^2} \rangle \) models the flow of a fluid. Show that if you drop a leaf into this fluid, as the leaf moves over time, the leaf does not rotate.

**Hint**-
Calculate the curl.

**Answer**-
\(\text{curl}\, \vecs{v} = \vecs 0\)

## Using Divergence and Curl

Now that we understand the basic concepts of divergence and curl, we can discuss their properties and establish relationships between them and conservative vector fields.

If \(\vecs{F}\) is a vector field in \(\mathbb{R}^3\) then the curl of \(\vecs{F}\) is also a vector field in \(\mathbb{R}^3\). Therefore, we can take the divergence of a curl. The next theorem says that the result is always zero. This result is useful because it gives us a way to show that some vector fields are not the curl of any other field. To give this result a physical interpretation, recall that divergence of a velocity field \(\vecs{v}\) at point \(P\) measures the tendency of the corresponding fluid to flow out of \(P\). Since \(\text{div}(\text{curl}\,\vecs v) = 0\), the net rate of flow in vector field \(\text{curl}\;\vecs v\) at any point is zero. Taking the curl of vector field \(\vecs{F}\) eliminates whatever divergence was present in \(\vecs{F}\).

##### Theorem: Divergence of the Curl

Let \(\vecs{F} = \langle P,Q,R \rangle \) be a vector field in \(\mathbb{R}^3\) such that the component functions all have continuous second-order partial derivatives. Then,

\[\text{div}(\text{curl}\, \vecs{F}) = \vecs\nabla \cdot (\vecs \nabla \times \vecs F) = 0. \nonumber \]

##### Proof

By the definitions of divergence and curl, and by Clairaut’s theorem,

\[\begin{align*} \text{div}(\text{curl}\, \vecs{F}) = \text{div}[(R_y - Q_z)\,\mathbf{\hat i} + (P_z - R_x)\,\mathbf{\hat j} + (Q_x - P_y)\,\mathbf{\hat k}] \\ = R_{yx} - Q_{xz} + P_{yz} - R_{yx} + Q_{zx} - P_{zy}\\ = 0. \end{align*}\]

\(\Box\)

##### Example \(\PageIndex{8}\): Showing That a Vector Field Is Not the Curl of Another

Show that \(\vecs{F}(x,y,z) = e^x\,\mathbf{\hat i}+ yz\,\mathbf{\hat j} + xz^2\,\mathbf{\hat k}\) is not the curl of another vector field. That is, show that there is no other vector \(\vecs{G}\) with \(\text{curl} \, \vecs G = \vecs F\).

**Solution**

Notice that the domain of \(\vecs{F}\) is all of \(\mathbb{R}^3\) and the second-order partials of \(\vecs{F}\) are all continuous. Therefore, we can apply the previous theorem to \(\vecs{F}\).

The divergence of \(\vecs{F}\) is \(e^x + z + 2xz\). If \(\vecs{F}\) were the curl of vector field \(\vecs{G}\), then \(\text{div}\, \vecs F = \text{div}(\text{curl} \,\vecs G) = 0\). But, the divergence of \(\vecs{F}\) is not zero, and therefore \(\vecs{F}\) is not the curl of any other vector field.

##### Exercise \(\PageIndex{8}\)

Is it possible for \(\vecs G(x,y,z) = \langle \sin x, \, \cos y, \, \sin (xyz)\rangle \) to be the curl of a vector field?

**Hint**-
Find the divergence of \(\vecs{G}\).

**Answer**-
No.

With the next two theorems, we show that if \(\vecs{F}\) is a conservative vector field then its curl is zero, and if the domain of \(\vecs{F}\) is simply connected then the converse is also true. This gives us another way to test whether a vector field is conservative.

##### Theorem: Curl of a Conservative Vector Field

If \(\vecs{F} = \langle P,Q,R\rangle\) is conservative, then \(\text{curl} \, \vecs{F} = \vecs 0\).

##### Proof

Since conservative vector fields satisfy the cross-partials property, all the cross-partials of \(\vecs F\) are equal. Therefore,

\[\begin{align*} \text{curl}\, \vecs{F} &= (R_y - Q_z)\,\mathbf{\hat i} + (P_z - R_x)\,\mathbf{\hat j} + (Q_x - P_y)\,\mathbf{\hat k} \\[4pt] &= \vecs 0. \end{align*}\]

\(\Box\)

The same theorem is true for vector fields in a plane.

Since a conservative vector field is the gradient of a scalar function, the previous theorem says that \(\text{curl}\, (\vecs \nabla f) = \vecs 0\) for any scalar function \(f\). In terms of our curl notation, \(\vecs \nabla \times \vecs \nabla (f) = \vecs 0\). This equation makes sense because the cross product of a vector with itself is always the zero vector. Sometimes equation \(\vecs \nabla \times \vecs \nabla (f) = \vecs 0\) is simplified as \(\vecs \nabla \times \vecs \nabla = \vecs 0\).

##### Theorem: Curl Test for a Conservative Field

Let \(\vecs{F} = \langle P,Q,R\rangle\) be a vector field in space on a simply connected domain. If \(\text{curl}\;\vecs F = \vecs 0\), then \(\vecs{F}\) is conservative.

##### Proof

Since \(\text{curl}\, \vecs F = \vecs 0\), we have that \(R_y = Q_z, \, P_z = R_x\), and \(Q_x = P_y\). Therefore, \(\vecs{F}\) satisfies the cross-partials property on a simply connected domain, and the Cross-Partial Property of Conservative Fields implies that \(\vecs{F}\) is conservative.

\(\Box\)

The same theorem is also true in a plane. Therefore, if \(\vecs{F}\) is a vector field in a plane or in space and the domain is simply connected, then \(\vecs{F}\) is conservative if and only if \(\text{curl}\, \vecs F = \vecs 0\).

##### Example \(\PageIndex{9}\): Testing Whether a Vector Field Is Conservative

Use the curl to determine whether \(\vecs{F}(x,y,z) = \langle yz, xz, xy\rangle\) is conservative.

**Solution**

Note that the domain of \(\vecs{F}\) is all of \(\mathbb{R}^3\) which is simply connected (Figure \(\PageIndex{7}\)). Therefore, we can test whether \(\vecs{F}\) is conservative by calculating its curl.

The curl of \(\vecs{F}\) is

\[\left(\dfrac{\partial}{\partial y}xy - \dfrac{\partial}{\partial z} xz \right) \,\mathbf{\hat i} + \left(\dfrac{\partial}{\partial y}yz - \dfrac{\partial}{\partial z} xy \right) \,\mathbf{\hat j} + \left(\dfrac{\partial}{\partial y}xz - \dfrac{\partial}{\partial z} yz \right)\,\mathbf{\hat k}= (x - x)\,\mathbf{\hat i} + (y - y)\,\mathbf{\hat j} + (z - z)\,\mathbf{\hat k} = \vecs 0. \nonumber \]

Thus, \(\vecs{F}\) is conservative.

We have seen that the curl of a gradient is zero. What is the divergence of a gradient? If \(f\) is a function of two variables, then \(\text{div}(\vecs \nabla f) = \vecs \nabla \cdot (\vecs \nabla f) = f_{xx} + f_{yy}\). We abbreviate this “double dot product” as \(\vecs \nabla^2\). This operator is called the *Laplace operator**,* and in this notation Laplace’s equation becomes \(\vecs \nabla^2 f = 0\). Therefore, a harmonic function is a function that becomes zero after taking the divergence of a gradient.

Similarly, if \(f\) is a function of three variables then

\[\text{div}(\vecs \nabla f) = \vecs \nabla \cdot (\vecs \nabla f) = f_{xx} + f_{yy} + f_{zz}. \nonumber \]

Using this notation we get Laplace’s equation for harmonic functions of three variables:

\[\vecs \nabla^2 f = 0. \nonumber \]

Harmonic functions arise in many applications. For example, the potential function of an electrostatic field in a region of space that has no static charge is harmonic.

##### Example \(\PageIndex{10}\): Finding a Potential Function

Is it possible for \(f(x,y) = x^2 + x - y\) to be the potential function of an electrostatic field that is located in a region of \(\mathbb{R}^2\) free of static charge?

**Solution**

If \(f\) were such a potential function, then \(f\) would be harmonic. Note that \(f_{xx} = 2\) and \(f_{yy} = 0\), and so \(f_{xx} + f_{yy} \neq 0\). Therefore, \(f\) is not harmonic and \(f\) cannot represent an electrostatic potential.

##### Exercise \(\PageIndex{10}\)

Is it possible for function \(f(x,y) = x^2 - y^2 + x\) to be the potential function of an electrostatic field located in a region of \(\mathbb{R}^2\) free of static charge?

**Hint**-
Determine whether the function is harmonic.

**Answer**-
Yes.

## Key Concepts

- The divergence of a vector field is a scalar function. Divergence measures the “outflowing-ness” of a vector field. If \(\vecs{v}\) is the velocity field of a fluid, then the divergence of \(\vecs{v}\) at a point is the outflow of the fluid less the inflow at the point.
- The curl of a vector field is a vector field. The curl of a vector field at point \(P\) measures the tendency of particles at \(P\) to rotate about the axis that points in the direction of the curl at \(P\).
- A vector field with a simply connected domain is conservative if and only if its curl is zero.

## Key Equations

**Curl**

\[\vecs \nabla \times \vecs{F} = (R_y - Q_z)\,\mathbf{\hat i} + (P_z - R_x)\,\mathbf{\hat j} + (Q_x - P_y)\,\mathbf{\hat k} \nonumber \]

**Divergence**

\[\vecs \nabla \cdot \vecs{F} = P_x + Q_y + R_z\nonumber \]

**Divergence of curl is zero**

\[\vecs \nabla \cdot (\vecs \nabla \times \vecs F) = 0\nonumber \]

**Curl of a gradient is the zero vector**

\[\vecs \nabla \times (\vecs \nabla f) = 0 \nonumber \]

## Glossary

**curl**- the curl of vector field \(\vecs{F}=⟨P,Q,R⟩\), denoted \(\vecs ∇× \vecs{F}\) is the “determinant” of the matrix \[\begin{vmatrix} \mathbf{\hat i} & \mathbf{\hat j} & \mathbf{\hat k} \\ \dfrac{\partial}{\partial x} & \dfrac{\partial}{\partial y} & \dfrac{\partial}{\partial z} \\ P & Q & R \end{vmatrix}. \nonumber \] and is given by the expression \((R_y−Q_z)\,\mathbf{\hat i} +(P_z−R_x)\,\mathbf{\hat j} +(Q_x−P_y)\,\mathbf{\hat k} \); it measures the tendency of particles at a point to rotate about the axis that points in the direction of the curl at the point

**divergence**- the divergence of a vector field \(\vecs{F}=⟨P,Q,R⟩\), denoted \(\vecs ∇× \vecs{F}\), is \(P_x+Q_y+R_z\); it measures the “outflowing-ness” of a vector field

One application for divergence occurs in physics, when working with magnetic fields. A magnetic field is a vector field that models the influence of electric currents and magnetic materials. Physicists use divergence in Gauss’s law for magnetism, which states that if \(\vecs{B}\) is a magnetic field, then \(\vecs \nabla \cdot \vecs{B} = 0\); in other words, the divergence of a magnetic field is zero.

## Example \(\PageIndex{2}\): Determining Whether a Field Is Magnetic

Is it possible for \(\vecs{F} (x,y) = \langle x^2 y, \, y - xy^2 \rangle \) to be a magnetic field?

SolutionIf \(\vecs{F}\) were magnetic, then its divergence would be zero. The divergence of \(\vecs{F}\) is

\[\dfrac{\partial}{\partial x} (x^2y) + \dfrac{\partial}{\partial y} (y - xy^2) = 2 xy + 1 - 2 xy = 1 \nonumber \]

and therefore \(\vecs{F}\) cannot model a magnetic field (Figure \(\PageIndex{3}\)).