You CAN Ace Calculus  

17calculus > vector fields > path and line integrals  


Topics You Need To Understand For This Page
Calculus Main Topics
Single Variable Calculus 

MultiVariable Calculus 
Tools
math tools 

general learning tools 
additional tools 
Related Topics and Links
external links you may find helpful 

Path and Line Integrals 

on this page: ► path integrals ► line integrals ► line integrals using the unit tangent vector ► line integrals in differential form ► fundamental theorem of line integrals 
Your experience with the power of integrals has been expanding since you first learned about them. You started with evaluating the area under a curve and then quickly went to evaluating area between curves. Then you were able to calculate volumes of revolution. Double and triple integrals expanded your ability to solve all kinds of problems in two and three dimensions. Now you are about to embark on another integration adventure involving line integrals. 
If you want complete lectures on this topic, here are some videos.
Prof Leonard  How to Compute Line Integrals (Over NonConservative V.Fields) [2hr17min23secs]  
Prof Leonard  Line Integrals on CONSERVATIVE V. Fields (Independence of Path) [1hr53min57secs]  
Basically, the idea is that you can evaluate an integral along a specific path. This allows you to solve all kinds of problems involving vector fields in physics and engineering. Before you jump into this technique, you need an important skill that is usually not covered very well as a separate topic. Many instructors just assume you can pick it up as you go. However, it does help to have a bit of explanation and some examples. This skill is the ability to parameterize a smooth line or curve, i.e. to be able to describe a line or curve using parametric equations. This next panel will get you started or help you remember how to do this.
Describing A Region In The xyPlane
To describe an area in the xyplane, the first step is to plot the boundaries and determine the actual region that needs to be described. There are several graphing utilities listed on the tools page. Our preference is to use the free program winplot ( used to plot these graphs; we used gimp to add labels and other graphics ). However, graphing by hand is usually the best and quickest way.
We use the graph to the right to facilitate this discussion. A common way to describe this area is the area bounded by \(f(x)\) (red line), \(g(x)\) (blue line) and \(x=a\) (black line).
[Remember that an equation like \(x=a\) can be interpreted two ways, either the point x whose value is a or the vertical line. You should be able to tell what is meant by the context.]
Okay, so we plotted the boundaries and shaded the area to be described. Now, we need to choose a direction to start, either vertically or horizontally. We will show both ways, starting with vertically, since it is more natural and what you are probably used to seeing. Also, this area is easier to describe vertically than horizontally (you will see why as you read on).
Vertically 

Our first step is to draw a vertical arrow on the graph somewhere within the shaded area, like we have done here. Some books draw an example rectangle with the top on the upper graph and the bottom on the lower graph. That is the same idea as we have done with the arrow.
Now we need to think of this arrow as starting at the left boundary and sweeping across to the right boundary of the area. This sweeping action is important since it will sweep out the area. As we think about this sweeping, we need to think about where the arrow enters and leaves the shaded area. Let's look our example graph to demonstrate. Think about the arrow sweeping left to right. Notice that it always enters the area by crossing \(g(x)\), no matter where we draw it. Similarly, the arrow always exits the area by crossing \(f(x)\), no matter where we draw it. Do you see that?
But wait, how far to the right does it go? We are not given that information. What we need to do is find the xvalue where the functions \(f(x)\) and \(g(x)\) intersect. You should be able to do that. We will call that point \((b,f(b))\). Also, we will call the left boundary \(x=a\). So now we have everything we need to describe this area. We give the final results below.
vertical arrow  

\( g(x) \leq y \leq f(x) \)  arrow leaves through \(f(x)\) and enters through \(g(x)\) 
\( a \leq x \leq b \)  arrow sweeps from left (\(x=a\)) to right (\(x=b\)) 
Horizontally 

We can also describe this area horizontally (or using a horizontal arrow). We will assume that we can write the equations of \(f(x)\) and \(g(x)\) in terms of \(y\). ( This is not always possible, in which case we cannot describe the area in this way. ) For the sake of this discussion, we will call the corresponding equations \(f(x) \to F(y)\) and \(g(x) \to G(y)\).
Let's look at the graph. Notice we have drawn a horizontal arrow. Just like we did with the vertical arrow, we need to determine where the arrow enters and leaves the shaded area. In this case, the arrow sweeps from the bottom up. As it sweeps, we can see that it always crosses the vertical line \(x=a\). However, there is something strange going on at the point \((b,f(b))\). Notice that when the arrow is below \(f(b)\), the arrow exits through \(g(x)\) but when the arrow is above \(f(b)\), the arrow exits through \(f(x)\). This is a problem. To overcome this, we need to break the area into two parts at \(f(b)\).
Lower Section   This section is described by the arrow leaving through \(g(x)\). So the arrow sweeps from \(g(a)\) to \(g(b)\).
Upper Section   This section is described by the arrow leaving through \(f(x)\). The arrow sweeps from \(f(b)\) to \(f(a)\).
The total area is the combination of these two areas. The results are summarized below.
horizontal arrow  

lower section  upper section  
\( a \leq x \leq G(y) \)  arrow leaves through \(G(y)\) and enters through \(x=a\) 
\( a \leq x \leq F(y) \)  arrow leaves through \(F(y)\) and enters through \(x=a\)  
\( g(a) \leq y \leq g(b) \)  arrow sweeps from bottom (\(y=g(a)\)) to top (\(y=g(b)\)) 
\( f(b) \leq y \leq f(a) \)  arrow sweeps from bottom (\(y=f(b)\)) to top (\(y=f(a)\)) 
Type 1 and Type 2 Regions 

Some instructors may describe regions in the plane as either Type 1 or Type 2 (you may see II instead of 2). As you know from the above discussion, some regions are better described vertically or horizontally. Type 1 regions are regions that are better described vertically, while Type 2 regions are better described horizontally. The example above was a Type 1 region.
Here is a quick video clip going into more detail on Type 1 and Type 2 regions.
Krista King Math  type I and type 2 regions  
like? 21 
[ For some videos and practice problems dedicated to this topic, check out this page. ]
Line integrals and path integrals are two different things, even though some instructors don't separate the two ideas.
A path integral, also called a scalar line integral, is an integral along a certain path and applies to scalar functions. 
A line integral is also an integral along a certain path but we require the integral to be evaluated in a specific direction, i.e. we need to take into account the direction in which the curve is traced, and applies to vector fields. 
We start by discussing the more basic idea of path integrals and then discuss how line integrals are different.
Path Integrals 
Let's start off with a video. This is a great video which includes a complete introduction, with examples, and explanation of applications of path integrals. It is well worth your time to watch it.
Dr Chris Tisdell: Integration over curves  
The equations from the last video are important for evaluating path integrals. Here is a summary.
requirements 
result  

continuous scalar function \(f(x,y,z)\) 
path integral of \(f\) over \( \mathcal{C} \)  
curve \( \mathcal{C} \) parameterized as \(\vec{c}(t)\) on an interval \(a \leq t \leq b\) 
\(\displaystyle{ \int_{\mathcal{C}}{ f(x,y,z)~ds} = }\) \(\displaystyle{ \int_{a}^{b}{ f(\vec{c}(t)) ~ \ \vec{c}'(t) \ ~dt } }\)  
continuous \(\vec{c}'(t)\) [ derivative of \(\vec{c}(t)\) with respect to \(t\) ] 
Most of the above equations should be familiar to you. However, one comment is in order about the term \(f(\vec{c}(t))\). How do you substitute a vector into a function?
If we write the vector as \( \vec{c}(t) = \langle X(t), Y(t), Z(t) \rangle = X(t) \hat{i} + Y(t) \hat{j} + Z(t)\hat{k} \) then we substitute the vector components into \(f(x,y,z)\) as \(x=X(t)\), \(y=Y(t)\) and \(z=Z(t)\). Another way to write this is
\(f(x,y,z) = f(X,Y,Z) = f(X(t), Y(t), Z(t))\). The result is a function of \(t\) only. All \(x\)'s, \(y\)'s and \(z\)'s will be gone, leaving only an integral in \(t\).
A very interesting comment he makes in the above video is that the direction of the curve does not affect the answer, i.e. integrating in the opposite direction will give the same answer. This is true because we use only the magnitude of the derivative of the parameterized curve, i.e. \(\ \vec{c}'(t) \\), which is the same regardless of the direction. However, the path integral is dependent on the chosen path, i.e. different paths will, in general, give different results. So path integrals are sensitive to the paths.
Okay, let's try some practice problems.
Unless otherwise instructed, evaluate the path integral over the curve \(\mathcal{C}\), giving your answers in exact terms.
Practice 1 

\( \int_{\mathcal{C}} x+y ~ds \) 
solution 
Practice 2 

\( \int_{\mathcal{C}}{x+y+z ~ ds } \) 
solution 
Practice 3 

\( \int_{\mathcal{C}}{x+y+z ~ ds } \) 
solution 
Practice 4 

\( f(x,y,z) = x^2+y^21+z \) 
solution 
Practice 5 

\( \int_{\mathcal{C}}{ x+y^2 ~ds }\) 
solution 
Practice 6 

\( \int_{\mathcal{C}}{xy^4 ~ds } \) 
solution 
Line Integrals 
Here is an important introduction to line integrals that explains very well the difference between line integrals and path integrals. He also explains the notation and how to calculate them. Notation is critical at this point since line integrals can be written several different ways. So be especially aware of that section of this video.
Dr Chris Tisdell: Intro to line integrals  
Similar to the path integrals video, this video gives the equations used to calculate the line integral, which are summarized below.
\(\displaystyle{ \int_{\mathcal{C}}{\vec{F} \cdot d\vec{s}} = \int_{a}^{b}{ \vec{F}(\vec{c}(t)) \cdot \vec{c}'(t) ~dt } }\) 
This line integral form is called the vector form. Make sure you see the difference between this equation for the line integral and the equation given earlier for the path integral.
Line Integrals Using The Unit Tangent Vector 
For a parameterized vector function \(\vec{c}(t)\), it's unit tangent vector is \(\displaystyle{ \hat{T} = \frac{\vec{c}'(t)}{\ \vec{c}'(t) \} }\). Since we are dividing by \(\ \vec{c}'(t) \\), we require that \(\vec{c}'(t) \neq \vec{0}\). Notice that we are dividing the vector by it's length, giving us a unit vector, i.e. \(\ \hat{T} \ = 1\).
Since the parameterized vector function \(\vec{c}(t)\) sweeps out the curve in a certain direction, the unit tangent vector will be the tangent vector in the forward direction, i.e. in the same direction that the curve is being swept out.
The unit tangent vector comes into the equation for the line integral given above. Here are the intermediate equations.
\(
\begin{array}{rcl}
\int_{\mathcal{C}}{\vec{F} \cdot d\vec{s}} & = & \int_{\mathcal{C}}{\vec{F} \cdot \hat{T} ds} \\
& = & \int_{a}^{b}{ \vec{F}(\vec{c}(t)) \cdot \hat{T}(\vec{c}(t)) \ \vec{c}'(t) \~dt } \\
& = & \int_{a}^{b}{ \vec{F}(\vec{c}(t)) \cdot \frac{\vec{c}'(t)}{\ \vec{c}'(t) \} \ \vec{c}'(t) \~dt } \\
& = & \int_{a}^{b}{ \vec{F}(\vec{c}(t)) \cdot \vec{c}'(t) ~dt }
\end{array}
\)
These equations came from the last video above. We highly recommend that you download the notes for this topic from
Dr Chris Tisdell's site. The video also describes the geometric meaning of the unit tangent vector. If you haven't watched it yet, now would be a good time.
You will probably find in your class, textbook and some of these videos, the boundary between path integrals and line integrals is difficult to see. So don't be too worried. The techniques are very similar. You just need to get some practice with the notation.
Practice 7 

\( \vec{F} = \langle y/(x^2+y^2), x/(x^2+y^2) \rangle \) 
solution 
Practice 8 

\(\displaystyle{\vec{F}=zx\hat{i}+zy\hat{j}+x\hat{k}}\) 
solution 
Practice 9 

Determine the work done by the conservative vector field \(\displaystyle{\vec{F}=yz\hat{i}+xz\hat{j}+xy\hat{k}}\) along any smooth curve from \(A(0,0,0)\) to \(B(1,1,1)\). 
solution 
Practice 10 

\( \vec{F} = \langle x^3, z, 2xy \rangle \) 
solution 
Line Integrals in Differential Form 
Another way to write line integrals of vector fields is in differential form.
If we are given a vector field \(\vec{F}(x,y,z) = M(x,y,z)\hat{i} + N(x,y,z)\hat{j} + P(x,y,z)\hat{k} \) and we need to find the line integral of this vector field over the curve \( \vec{r}(t) = x(t)\hat{i} + y(t)\hat{j} + z(t)\hat{k} \), we can do the following, where \( \vec{r}'(t) = x'(t)\hat{i} + y'(t)\hat{j} + z'(t)\hat{k} \).
\(\displaystyle{
\begin{array}{rcl}
\int_{\mathcal{C}}{ \vec{F} \cdot d\vec{r}} & = & \int_{\mathcal{C}}{ \vec{F} \cdot \frac{d\vec{r}} {dt}~dt } \\
& = & \int_{a}^{b}{ \left( M\hat{i} + N\hat{j} + P\hat{k} \right) \cdot \vec{r}'(t) ~dt } \\
& = & \int_{a}^{b}{ \left[ M\frac{dx}{dt} + N\frac{dy}{dt} + P\frac{dz}{dt} \right] ~dt } \\
& = & \int_{\mathcal{C}}{ M~dx + N~dy + P~dz }
\end{array} }\)
Some general comments are in order.
1. The above equations relate to vector fields in (3dim) space. For vector fields in the plane, we just drop the \(dz\) term to get \(\displaystyle{ \int_{\mathcal{C}}{ \vec{F} \cdot d\vec{r}} = \int_{\mathcal{C}}{ M~dx + N~dy } }\).
2. The final equation that we use to calculate the line integral does not seem to involve a vector field. However, you can see that M, N and P are the components of the vector field \(\vec{F}\). So keep in mind that this is a line integral of a vector field (not a path integral of a scalar function).
Practice 11  

\( \int_{\mathcal{C}}{ xy~dx+y~dy } \)  
answer 
solution 
Practice 12  

\( \int_{\mathcal{C}}{ (2xy)~dx+(x+3y)~dy } \)  
answer 
solution 
Practice 13 

\( \int_{\mathcal{C}}{ 9x~dy9y~dx }\) 
solution 
Practice 14 

\( \int_{\mathcal{C}}{(2x+yz)dx +xz dy + xy dz} \) 
solution 
Practice 15 

Compute \(\displaystyle{ \int_{(1,1)}^{(4,2)}{ (x+y)~dx+(yx)~dy } }\) along the curve \(x=y^2\). 
solution 
Fundamental Theorem of Line Integrals 
Similar to the Fundamental Theorem of Calculus we have the Fundamental Theorem of Line Integrals. Basically, this says, that for a conservative vector field, the line integral is independent of the path and depends only on the endpoints.
Here is a great video that explains this theorem in detail and includes examples.
Dr Chris Tisdell: Line integrals: Fundamental theorem  
Okay, now you are ready to learn about Green's Theorem. 
next: green's theorem → 