Line Integrals of Vector Fields
Line integrals of vector fields measure the work done by a force as an object moves along a path. They connect the geometry of a curve with the behavior of a vector field along that curve, and they form the foundation for Green's Theorem and the bigger results coming later in this unit.
Line Integrals of Vector Fields

Line integrals of vector fields
The line integral of a vector field along a curve is written as . Physically, this computes the total work done by the force field on an object traveling along . The dot product at each point picks out only the component of the force that acts along the direction of motion.
To evaluate this integral, you parametrize the curve. That means you describe the path as a vector function of a single parameter (often representing time):
- 2D: , with
- 3D: , with
Steps to compute a line integral:
- Parametrize the curve with over .
- Compute , the derivative of your parametrization.
- Substitute into so that everything is in terms of .
- Take the dot product .
- Integrate the result from to .
Written out for a 2D field :
The 3D version adds the -component:
where are each evaluated at .

Fundamental theorem for line integrals
If is a conservative vector field, meaning there exists a scalar function such that , then the line integral depends only on the endpoints of the path, not on the path itself. The function is called the potential function.
The theorem states:
This is the multivariable analogue of the Fundamental Theorem of Calculus. Instead of integrating and then evaluating an antiderivative at two numbers, you evaluate a potential function at two points in space.
How to apply it:
- Confirm that is conservative (see the tests below).
- Find the potential function such that .
- Evaluate at the endpoint and the start point .
- Subtract: .
One immediate consequence: the line integral of a conservative field over any closed curve is zero, because the start and end points are the same.
Conservative vector fields vs line integrals
Not every vector field is conservative. Here are the standard tests to check:
- Component test (2D): For , check whether throughout the domain. If equality holds on a simply connected region (no holes), the field is conservative.
- Curl test (3D): Compute . If the curl is everywhere on a simply connected domain, the field is conservative.
- Closed path test: If for every closed curve in the domain, the field is conservative. In practice, you rarely check every closed curve, but finding one closed path with a nonzero integral immediately proves the field is not conservative.
- Multiple path test: Compute the line integral between two fixed points along two different paths. If the results differ, the field is not conservative.
The simply connected condition matters. A field can pass the component or curl test at every point yet still fail to be conservative if the domain has a hole. The classic example is the field , which has everywhere it's defined, but its domain excludes the origin, creating a hole.
Potential functions for conservative fields
Once you've confirmed a field is conservative, you need to find . The most common approach is the partial derivative method:
- Start from . Integrate with respect to to get , where is an unknown function (it plays the role of the "constant" of integration, but it can depend on the other variables).
- Differentiate your result with respect to and set it equal to . This lets you solve for or narrow down .
- If you're in 3D, differentiate with respect to and set equal to to pin down any remaining unknown.
- Combine everything into a single expression for .
Alternative: the line integral method. Pick a convenient reference point (the origin works well) and compute:
Since the field is conservative, you can choose any path you like. A common trick is to integrate along axis-aligned segments (first along , then , then ), which keeps the computation clean.
Both methods give the same potential function, up to an additive constant. Use whichever feels more natural for the problem at hand.