Skip to main content
Logo image

Coordinated Multivariable Calculus

Section 4.4 Path-Independent Vector Fields and the Fundamental Theorem of Calculus for Line Integrals

In Activity 4.3.3, Example 4.3.5, and Activity 4.3.4, we have encountered situations where C1 and C2 are different oriented curves from a point P to a point Q and C1Fdr=C2Fdr. In this section, we explore vector fields which have the property that for all points P and Q, if C1 and C2 are oriented paths from P to Q, then C1Fdr=C2Fdr.

Preview Activity 4.4.1.

In Activity 4.3.3, we considered the vector field F(x,y)=y2,2xy+3 and two different oriented curves from (1,0) to (1,0). We found that the value of the line integral of F was the same along those two oriented curves.

(a)

Verify that F(x,y)=y2,2xy+3 is a gradient vector field by showing that F=f for the function f(x,y)=xy2+3y.
Answer.
Calculate fx and fy.
Solution.
Since fx=y2 and fy=2xy+3, F=f.

(b)

Calculate the change in the output of the scalar function f over the curves C1 and C2. In other words, what is the difference in the output of f at the start of the curve and the end of the curve. How does this value compare to the value of the line integral C1Fdr you found in Activity 4.3.3?
Answer.
0
Solution.
Algebraically, f(1,0)f(1,0)=00=0. There is no net change in the output of f. The line integral is also 0.

(c)

Let C3 be the line segment from (1,1) to (3,4). Calculate C3Fdr as well as f(3,4)f(1,1). What do you notice?
Answer.
56
Solution.
The line segmentC3 is given by r(t)=1+2t,1+3t as 0t1. Thus,
C3Fdr=01(1+3t)2,2(1+2t)(1+3t)2,3dt=56
Note here that f(3,4)f(1,1)=604=56 which is the same as the result of the line integral.

(d)

Earlier in the chapter, we’ve used Clairaut’s Theorem to argue that a vector field in R2 is not a gradient vector field when F1/yF2/x. Earlier in this preview activity, you verified that a given vector field was the gradient of a particular function of two variables. Clairaut’s Theorem holds for functions of three variables. However, in that case there are six mixed partials to calculate, and thus it can be rather tedious.The remaining parts of this preview activity suggest a process for determining if a vector field in R3 is a gradient vector field as well as finding a potential function for the vector field.
Let G(x,y,z)=3ey2+zsin(x),6xyey2z,3z2ycos(x) and H(x,y,z)=3x2y,x3+2yz3,xz+3y2z2.
If G and H are to be gradient vector fields, then there are functions g and h for which G=g and H=h. What would this tell us about the partial derivatives gx, gy, gz, hx, hy, and hz?
Answer.
Each of the partial derivatives of g and h would have to be as follows: gx=3ey2+zsin(x), gy=,6xyey2z, gz=3z2ycos(x), hx=x2y, hy=x3+2yz3, and hz=xz+3y2z2.
Solution.
Each of the partial derivatives of g and h would have to be as follows: gx=3ey2+zsin(x), gy=,6xyey2z, gz=3z2ycos(x), hx=x2y, hy=x3+2yz3, and hz=xz+3y2z2.

(e)

Let g1(x,y,z)=3ey2+xyzzsin(x). Calculate g1/x. Could g1 be a potential function for the vector field G?
Answer.
g1x=3ey2+yzzcos(x). No.
Solution.
The partial of g1 with respect to x would be 3ey2+yzzcos(x). Since the partial of g1 with respect to x is not the same as the x-component of G, g1 cannot be a potential function for G.

(f)

Find a function g so that g/x=3ey2+zsin(x). Find a function h so that h/x=3x2y.
Answer.
g(x,y,z)=3xey2zcos(x) and h(x,y,z)=x3y
Solution.
g(x,y,z)=3xey2zcos(x) and h(x,y,z)=x3y

(g)

When finding the most general anti-derivative for a function of one variable, we add a constant of integration (usually denoted by C) to capture the fact that any constant will become 0 through differentiation.
(i)
When taking the partial derivative with respect to x of a function of x, y, and z, what variables can appear in terms that become 0 in the partial derivative because they are treated as constants?
Answer.
y and z
Solution.
Any terms that do not contain an x-variable will be treated as a constant, so y and z are allowed.
(ii)
What does this tell you should be added to g and h in the previous part to make them the most general possible functions with the desired partial derivatives with respect to x?
Answer.
g(x,y,z)=3xey2zcos(x)+C1(y,z) and h(x,y,z)=x3y+C2(y,z)
Solution.
The most general form of g and h are g(x,y,z)=3xey2zcos(x)+C1(y,z) and h(x,y,z)=x3y+C2(y,z), where C1 and C2 are functions.

(h)

Now calculate g/y and h/y. Explain why this tells you that we must have
g(x,y,z)=3xey2zcos(x)yz+m1(z)
and
h(x,y,z)=x3y+y2z3+m2(z)
for some functions m1 and m2 depending only on z.
Answer.
gy=6xyey2+C1y, hy=x3+C2y.
Solution.
We find that gy=6xyey2+C1y and hy=x3+C2y. This means that we need to add terms to g and h in y and z such that the partial with respect to y will correspond to the second component of G and H.

(i)

Calculate g/z and h/z for the functions in the part above. Notice that m1 and m2 are functions of z alone, so taking a partial derivative with respect to z is the same as taking an ordinary derivative, and thus you may use the notation m1(z) and m2(z).
Answer.
gz=cos(x)y+m1z and hz=3y2z2+m2z
Solution.
gz=cos(x)y+m1z and hz=3y2z2+m2z

(j)

Explain why G is a gradient vector field but H is not a gradient vector field. Find a potential function for G.
Answer.
g(x,y,z)=3xey2zcos(x)yz+z3
Solution.
If g(x,y,z)=3xey2zcos(x)yz+z3, then g=G. There is no m2(z) that will have a partial with respect to z of xz since m2(z) cannot have a dependence on x.

Subsection 4.4.1 Path-Independent Vector Fields

We say that a vector field F defined on a domain D is path-independent if C1Fdr=C2Fdr whenever C1 and C2 are oriented paths in D such that both curves start at the same point P and end at point Q.
In Activity 4.3.3 and Example 4.3.5, we encountered situations where we had evidence that a vector field was path-independent. However, since the definition of path-independence requires that the value of the line integral be the same for every pair of points in the domain and every possible path from one point to the other, it doesn’t appear that verifying a vector field is path-independent is an easy task.
Fortunately, one familiar class of vector fields can be shown to be path-independent. Let f:R3R be a function for which f is continuous on a domain D. Suppose that P and Q are points in D and let C be a smooth oriented path from P to Q. Let’s take a look at Cfdr by fixing an arbitrary parametrization r(t) of C, atb. Since f(r(t))=fx(r(t)),fy(r(t)),fz(r(t)), we know that
Cfdr=abf(r(t))r(t)dt=abfx(r(t)),fy(r(t)),fz(r(t))r(t)dt
If r(t)=x(t),y(t),z(t), then the integrand above is
fx(r(t)),fy(r(t)),fz(r(t))x(t),y(t),z(t)=fx(x(t),y(t),z(t))x(t)+fy(x(t),y(t),z(t))y(t)+fz(x(t),y(t),z(t))z(t).
Notice that this is exactly what the chain rule tells us ddtf(r(t)) is equal to. Therefore,
Cfdr=abddtf(r(t))dt=f(r(b))f(r(a))=f(Q)f(P).
In other words, gradient vector fields are path-independent vector fields, and we can evaluate line integrals of gradient vector fields by using a potential function. (Technically the argument above assumed that C was smooth, but we can replace C by a piecewise smooth curve by splitting the line integral up into the sum of finitely many line integrals along smooth curves.)
This result is so important that it is frequently called the Fundamental Theorem of Calculus for Line Integrals, because of its similarity to the Fundamental Theorem of Calculus, which can be written as
abf(x)dx=f(b)f(a).

Activity 4.4.2.

Calculate each of the following line integrals.
(a)
Cfdr if f(x,y)=3xy2sin(x)+ey and C is the top half of the unit circle oriented from (1,0) to (1,0).
Answer.
0
Solution.
Because f(1,0)=sin(1)+1 and f(1,0)=sin(1)+1, then Cfdr=(sin(1)+1)(sin(1)+1)=0.
(b)
Cgdr if g(x,y,z)=xz25y3cos(z)+6 and C is the portion of the helix r(t)=5cos(t),5sin(t),3t from (5,0,0) to (0,5,9π/2).
Answer.
0
Solution.
Because g(5,0,0)=00+6 and g(0,5,9π2)=00+6, then Cgdr=(6)(6)=0.
(c)
Chdr if h(x,y,z)=3y2ey35xsin(x3z)+z2 and C is the curve consisting of the line segment from (0,0,0) to (1,1,1), followed by the line segment from (1,1,1) to (1,3,2), followed by the line segment from (1,3,2) to (0,0,10).
Answer.
100
Solution.
Because h(0,0,0)=0 and h(0,0,10)=00+100, then Chdr=(100)(0)=100.
By following the methodology laid out in Preview Activity 4.4.1 to show that a given vector field is a gradient vector field, the Fundamental Theorem of Calculus for Line Integrals makes evaluating a large number of line integrals simpler now.

Activity 4.4.3.

Calculate each of the following line integrals.
(a)
CFdr if F(x,y)=2x,2y and C is the line segment from (1,2) to (1,0).
Hint.
Find f(x,y) such that f=F.
Answer.
4
Solution.
We can choose f(x,y)=x2+y2+C and note that f=F. so by the Fundamental Theorem of Calculus for Line Integrals, CFdr=f(1,2)f(1,0)=51=4.
(b)
CGdr if G(x,y)=4x312ycos(xy),9y212xcos(xy) and C is the portion of the unit circle from (0,1) to (0,1).
Answer.
6
Solution.
We can choose g(x,y)=x412sin(xy)+3y3+C and note that g=G. so by the Fundamental Theorem of Calculus for Line Integrals, CGdr=g(0,1)g(0,1)=3(3)=6.
(c)
CHdr if H(x,y,z)=H1,H2,H3 with
H1(x,y,z)=ez2+2xy3z+cos(x)y3sin(x)H2(x,y,z)=2yey2+3x2y2z+3y2z2+3y2cos(x)H3(x,y,z)=x2y3+2xzez2+2y3z4z3
and C is the curve consisting of the line segment from (1,1,1) to (3,0,3), followed by the line segment from (3,0,3) to (1,5,1), followed by the line segment from (1,5,1) to (0,0,0).
Answer.
1(2e+sin(1)+cos(1))
Solution.
We can choose h(x,y,z)=xez2+x2y3z+sin(x)+y3cos(x)+ey2z4 and note that h=H. so by the Fundamental Theorem of Calculus for Line Integrals, CHdr=h(0,0,0)h(1,1,1)=1(e+1+sin(1)+cos(1)+e1)=1(2e+sin(1)+cos(1)).

Subsection 4.4.2 Line Integrals Along Closed Curves

Recall that we call an oriented curve C closed if it has the same initial and terminal point. A typical example of a closed curve would be a circle (with an orientation of which way to go around), but we could also consider something like the square with vertices (1,1), (1,1), (1,1), and (1,1), oriented clockwise (or counterclockwise). Recall that we sometimes use the symbol for a line integral when the curve is closed and that if C=C1+C2, then CFdr=C1Fdr+C2Fdr.

Activity 4.4.4.

Suppose that F is a continuous path-independent vector field (in R2 or R3) on some domain D.
(a)
Let P and Q be points in D and let C1 and C2 be oriented curves from P to Q. What can you say about C1Fdr and C2Fdr?
Answer.
C1Fdr=C2Fdr.
Solution.
Because F is a path-independent vector field and both C1 and C2 start at P and end at Q, C1Fdr=C2Fdr.
(b)
Let C=C1C2. Explain why C is a closed curve.
Answer.
C starts and ends at P.
Solution.
The curve C is closed because the end of C1 is the start of C2 and the end of C2 is the start of C1, thus C starts and ends at P.
(c)
Calculate CFdr.
Answer.
0
Solution.
CFdr=C1Fdr+C2Fdr=C1FdrC2Fdr and by part 1, this difference is zero.
(d)
Write a sentence that summarizes what we can conclude at this point in the activity.
Solution.
The line integral along every closed curve in a path-independent vector field is 0.
(e)
Now let us suppose that G is a continuous vector field on a domain D for which CGdr=0 for all closed curves C. Pick two points P and Q in D. Let C1 and C2 be oriented curves from P to Q. What type of curve is C=C1C2?
Answer.
Closed
Solution.
We have that C is a closed curve (from P to P) because C1 will go from P to Q and C2 will go from Q back to P.
(f)
What is CGdr? Why?
Answer.
0
Solution.
We see that CGdr=0 because (as stated above) G is a continuous vector field on a domain D for which CGdr=0 for all closed curves C.
(g)
What does that tell you about the relationship between C1Gdr and C2Gdr?
Answer.
C1Gdr=C2Gdr
Solution.
Since CGdr=0=C1Gdr+C2Gdr=C1GdrC2Gdr, C1Gdr=C2Gdr.
(h)
Explain why this shows that G is path-independent.
Answer.
Arbitrary paths with common initial and terminal points were used.
Solution.
The argument above relies only on the fact that the two paths have the same initial and terminal points.
We summarize the result of Activity 4.4.4 with the theorem below. Although this theorem is not a terribly useful way to show that a vector field is path-independent, it can be a useful way to show that a vector field is not path-independent: find a closed curve around which the circulation is not zero.
The following activity gives you a chance to reason about path-independence based purely on a graphical representation of a vector field.

Activity 4.4.5.

Explain why neither of the vector fields in Figure 4.4.3 is path-independent.
described in detail following the image
A vector field in which all vectors are horizontal. The vectors are 0 along the x-axis, point to the right for y>0 and point to the left for y<0. Vectors get longer as distance from the x-axis increases.
(a) F
described in detail following the image
A vector field in which vectors appear to circulate in a clockwise manner around the point (3,0). The magnitude of vectors increases with the distance from (3,0). The plot shows the portion of the vector field with 0x6 and 3y3.
(b) G
Figure 4.4.3. Two vector fields that are not path-independent.
Answer.
For F, consider a square with lower-left corner (1,1) and upper-right corner (1,1). For G, consider a circle centered at (3,0).
Solution.
In F, we consider the square with lower-left corner (1,1) and upper-right corner (1,1), oriented clockwise, to be C. Notice that CFdr>0 because the line integrals along the horizontal edges of the square are both positive and the line integrals along the vertical sides are zero because F is orthogonal to those sides. Because the line integral along this closed curve is not 0, F is not path-independent.
In G, consider the circle C of radius 2 centered at the point (3,0). It appears that G is tangent to C, but we can confidently say that Gdr>0 along C, which makes CGdr, and thus G is not path-independent.

Subsection 4.4.3 What other vector fields are path-independent?

Recall that in single variable calculus, the Second Fundamental Theorem of Calculus tells us that given a constant c and a continuous function f, there is a unique function A(x) for which A(c)=0 and A(x)=f(x). In particular, A(x)=cxf(t)dt is this function. We are about to investigate an analog of this result for path-independent vector fields, but first we require two additional definitions.
If D is a subset of R2 or R3, we say that D is open provided that for every point in D, there is a disc (in R2) or ball (in R3) centered at that point such that every point of the disc/ball is contained in D. For example, the set of points (x,y) in R2 for which x2+y2<1 is open, since we can always surround any point in this set by a tiny disc contained in the set. However, if we change the inequality to x2+y21, then the set is not open, as any point on the circle x2+y2=1 cannot be surrounded by a disc contained in the set; any disc surrounding a point on that circle will contain points outside the set, that is with x2+y2>1. We will also say that a region D is path-connected provided that for every pair of points in D, there is a path from one to the other contained in D.

Activity 4.4.6.

Let F=F1,F2 be a continuous, path-independent vector field on an open, connected region D. We will assume that D is in R2 and F is a two-dimensional vector field, but the ideas below generalize completely to R3. We want to define a function f on D by using the vector field F and line integrals, much like the Second Fundamental Theorem of Calculus allows us to define an antiderivative of a continuous function using a definite integral. To that end, we assign f(x0,y0) an arbitrary value. (Setting f(x0,y0)=0 is probably convenient, but we won’t explicitly tie our hands. Just assume that f(x0,y0) is defined to be some number.) Now for any other point (x,y) in D, define
f(x,y)=f(x0,y0)+CFdr,
where C is any oriented path from (x0,y0) to (x,y). Since D is connected, such an oriented path must exist. Since F is path-independent, f is well-defined. If different paths from (x0,y0) to (x,y) gave different values for the line integral, then we’d not be sure what f(x,y) really is.
To better understand this mysterious function f we’ve now defined, let’s start looking at its partial derivatives.
(a)
Since D is open, there is a disc (perhaps very small) surrounding (x,y) that is contained in D, so fix a point (a,b)in that disc. Since D is path-connected, there is a path C1 from (x0,y0) to (a,b). Let Cy be the line segment from (a,b) to (a,y) and let Cx be the line segment from (a,y) to (x,y). (See Figure 4.4.4.) Rewrite f(x,y) as a sum of f(x0,y0) and line integrals along C1, Cy, and Cx.
described in detail following the image
Two oriented curves from (x0,y0) to (x,y). Both begin with a curved arc from (x0,y0) to (a,b). The curve on the left proceeds vertically from (a,b) to (a,y) and then horizontally to (x,y). The curve on the right proceeds horizontally from (a,b) to (x,b) and then vertically to (x,y).
Figure 4.4.4. Two piecewise smooth oriented curves from (x0,y0) to (x,y).
Answer.
f(x,y)=f(x0,y0)+C1Fdr+CyFdr+CxFdr
Solution.
Because C=C1+Cy+Cx, we have that
f(x,y)=f(x0,y0)+CFdr=f(x0,y0)+C1Fdr+CyFdr+CxFdr.
(b)
Notice that we can parametrize Cy by a,t for bty. Find a similar parametrization for Cx.
Answer.
t,y for atx
Solution.
The curve Cx can be given by r(t)=t,y for atx, since only the x-coordinate of points on Cx varies.
(c)
Use the parametrization from above to write CyFdr and CxFdr as single variable integrals in the manner of Section 4.3. Use the fact that F(x,y)=F1(x,y),F2(x,y) to express your integrals in terms of F1 and F2 without any dot products.
Answer.
CyFdr=byF2(a,t)dt and CxFdr=axF1(t,y)dt
Solution.
Using the parametrization of Cx and Cy from the previous part, we notice that r(t) has only one nonzero component in each case. Thus, we have
CyFdr=by0+F2(a,t)dt
and
CxFdr=axF1(t,y)+0dt.
(d)
Rewrite your expression for f(x,y) using the single variable integrals above (and a line integral along C1).
Answer.
f(x,y)=f(x0,y0)+C1Fdr+byF2(a,t)dt+axF1(t,y)dt
Solution.
Combining the previous parts, we have
f(x,y)=f(x0,y0)+C1Fdr+CyFdr+CxFdr=f(x0,y0)+C1Fdr+byF2(a,t)dt+axF1(t,y)dt.
(e)
Notice that your expression for f(x,y) from the previous part only depends on x as the upper limit of an single variable integral. Use the Second Fundamental Theorem of Calculus to calculate fx(x,y).
Answer.
fx(x,y)=F1(x,y)
Solution.
The first three terms in our expression for f(x,y) do not depend on x, and thus when taking the partial derivative with respect to x, they vanish. By the Second Fundamental Theorem of Calculus (treating a,y as constants),
xaxF1(t,y)dt=F1(x,y).
Therefore, fx(x,y)=F1(x,y).
(f)
To calculate fy(x,y), we continue to consider a path C1 from (x0,y0) to (a,b), but now let Lx be the line segment from (a,b) to (x,b) and let Ly be the line segment from (x,b) to (y,b). Modify the process you used to find fx(x,y) to find fy(x,y).
Answer.
fy(x,y)=F2(x,y)
Solution.
Proceeding as above, we find that
f(x,y)=f(x0,y0)+C1Fdr+LxFdr+LyFdr=f(x0,y0)+C1Fdr+axF1(t,b)dt+byF2(x,t)dt.
Only the last term of this expression depends on y, so the first three terms vanish when calculating fy(x,y). By the Second Fundamental Theorem of Calculus,
ybyF2(x,t)dt=F2(x,y).
Therefore, fy(x,y)=F2(x,y).
(g)
What can you conclude about the relationship between f and F? What does this tell you about F beyond that it is path-independent and continuous?
Answer.
f=F; F is a gradient vector field
Solution.
Since fx(x,y)=F1(x,y) and fy(x,y)=F2(x,y), we can conclude that f=F. Therefore, we know that F is a gradient vector field.
We summarize the result of Activity 4.4.6 below.

Subsection 4.4.4 Summary

  • Gradient vector fields are path-independent, and if C is an oriented curve from (x1,y1) to (x2,y2), then
    Cfdr=f(x2,y2)f(x1,y1)
    with the analogous result holding if f is a function of three variables.
  • A vector field is path-independent if and only if the circulation around every closed curve in its domain is 0.
  • If a vector field F is path-independent, then there exists a function f such that f=F. That is, F is a conservative or gradient vector field.

Exercises 4.4.5 Exercises

1.

For each of the following line integrals:
(a)
The line integral of F=yz,xz,y along the helix of radius of 3 given by r(t)3sin(t),3cos(t),4πt as πtπ.
(b)
The line integral of F=sin(yz),xzcos(yz)zsin(y),xycos(yz)+cos(y) along the line segment from (0,π,3) to (2,1,2π).
(c)
The integralCy2dx+2xydy where C is the parabolic path along y=x2 from (1,1) to (4,16).

2.

Let F=F1,F2,F3, where F1=3xy2+z and F3=yz2+cos(z).
(a)
Give a component function F2 such that F is a gradient vector field.
(b)
Give a component function F2 such that F is not a gradient vector field.

3.

This exercise focuses on reasoning graphically about line integrals and vector fields.
(a)
Find a closed curve on which the line integral of the vector field pictured below will not be zero. Be sure to clearly define your curve and explain why the line integral over your curve is non-zero.
described in detail following the image
A vector field showing counterclockwise rotation around the origin. At the origin, the vector field is zero, and vector magnitudes increase as distance from the origin increases.
Figure 4.4.6. A vector field
(b)
Explain why you think the following vector field is path independent or not.
described in detail following the image
A vector field in which vector magnitudes increase as distance from the origin increases. Vectors are oriented as if they follow hyperbolas with asymptotes y=x and y=x. Vectors above both asymptotes or below both asymptotes result in counterclockwise rotation. The other vectors result in clockwise rotation.
Figure 4.4.7. Another vector field

4.

Compute Cyezdx+xezdy+xyezdz where C is given by t2,t3,t1 for 1t2.