An ordinary integral adds up a quantity along a straight interval of the x-axis. A line integral adds up a quantity along a curve: the mass of a bent wire whose density varies, or the work a force field does on a particle that travels along a winding path. The trick is always the same: parametrize the curve, and the line integral becomes an ordinary integral in the parameter t.
Line integrals of functions
Let C be a smooth curve given by r(t)=⟨x(t),y(t)⟩ for a≤t≤b, and let f(x,y) be a function defined on C. Chop C into tiny pieces of arc length Δs, multiply the value of f on each piece by its length, and add. In the limit you get the line integral of f with respect to arc length.
Recall from arc length that a small change dt in the parameter moves you a distance ds=∣r′(t)∣dt along the curve. That gives the formula you actually compute with.
In space, add a z-component: ∣r′(t)∣=x′2+y′2+z′2.
If f=1, the integral is just the length of C. If f is the density of a wire (mass per unit length), the integral is the wire's mass. The value does not depend on which parametrization you choose or which way you traverse the curve, because ds is always a positive length.
Worked example: A straight segment
Evaluate ∫C(x+y)ds, where C is the segment from (0,0) to (3,4).
Parametrize: r(t)=⟨3t,4t⟩, 0≤t≤1. Then r′(t)=⟨3,4⟩ and ∣r′(t)∣=5. On the curve, x+y=7t. So
∫C(x+y)ds=∫017t⋅5dt=35⋅21=235.
Worked example: A quarter circle
Evaluate ∫Cxyds, where C is the quarter of the circle x2+y2=4 in the first quadrant.
Parametrize: r(t)=⟨2cost,2sint⟩, 0≤t≤2π. Then ∣r′(t)∣=4sin2t+4cos2t=2, and
Now let F be a force field and let a particle move along C. On a tiny piece of the curve, the displacement is dr=r′(t)dt, and the work done is the component of force along the motion times the distance: F⋅dr. Adding these up gives the work.
Line integral of a vector field
∫CF⋅dr=∫abF(r(t))⋅r′(t)dt.
If F=⟨P,Q⟩, this is also written ∫CPdx+Qdy, since dx=x′(t)dt and dy=y′(t)dt. In space, ∫CPdx+Qdy+Rdz.
Equivalently, F⋅dr=(F⋅T)ds, where T is the unit tangent vector. So the vector line integral is the scalar line integral of the tangential component of F. Force perpendicular to the path does no work.
The path y = x² from (0, 0) to (1, 1) used in the work example.Open in grapher →
Worked example: Work along a parabola
Find the work done by F(x,y)=⟨y,x2⟩ on a particle moving along y=x2 from (0,0) to (1,1).
Parametrize with x=t: r(t)=⟨t,t2⟩, 0≤t≤1, so r′(t)=⟨1,2t⟩. On the curve F=⟨t2,t2⟩. Then
Traversing C in the opposite direction (written −C) flips every dr, so
∫−CF⋅dr=−∫CF⋅dr,but∫−Cfds=∫Cfds.
A curve made of several pieces, like the sides of a triangle, is handled one piece at a time; add the results.
Common mistake
Don't forget the factor ∣r′(t)∣ in ∫Cfds, and don't insert it into ∫CF⋅dr. The vector integral uses r′(t) itself, dotted with F, with no square root anywhere.
Tip
To parametrize the segment from P to Q, use r(t)=(1−t)P+tQ for 0≤t≤1. Then r′(t)=Q−P, a constant vector.
Practice
Practice 1
Evaluate ∫C2xds, where C is the segment from (0,0) to (1,1).
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Practice 2
Evaluate ∫C(x2+y2)ds, where C is the full circle x2+y2=9.
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Practice 3
Evaluate ∫CF⋅dr for F(x,y)=⟨x,y⟩ along r(t)=⟨t,t2⟩, 0≤t≤2.
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Practice 4
Find the work done by F(x,y)=⟨−y,x⟩ on a particle that travels once counterclockwise around the unit circle.
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Practice 5
Evaluate ∫Cydx+x2dy, where C is given by x=t, y=2t, 0≤t≤1.
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Practice 6
For a curve C, ∫Cfds=6 and ∫CF⋅dr=4. If you traverse the curve in the opposite direction, what are the two integrals?
Practice 7
A thin wire lies along the segment r(t)=⟨t,2t,2t⟩, 0≤t≤1, and has density δ(x,y,z)=xyz. Find its mass.
Enter a number. Fractions like 3/4 and sqrt(2) are OK.