When does the trapezoidal rule overestimate or underestimate?

To tell whether the trapezoidal rule gives an overestimate, we look at how the curve bends. The top of each trapezoid is a straight segment joining two points on the curve, so its position above or below the curve determines the error. Let’s compare the two kinds of concavity and see why a straight line gives an exact result.

Concave up gives an overestimate

When a function is concave up across each subinterval, the straight segment joining the endpoints lies above the curve. The trapezoid therefore includes extra area above the curve, so the trapezoidal approximation is at least as large as the definite integral.

For a curve that bends strictly upward, the estimate is larger than the integral. If the second derivative is positive throughout the interval, it tells us the function is concave up there.

f′′(x)>0Tn>∫abf(x)dx

Concave down gives an underestimate

When the function is concave down across each subinterval, the segment joining the endpoints lies below the curve. Some area under the curve is above the trapezoid and is left out of the approximation, so the trapezoidal estimate is at most the value of the definite integral.

f′′(x)<0Tn<∫abf(x)dx
How concavity changes a trapezoidal estimateIn the upper panel, the straight line joining the curve’s endpoints lies above a concave-up curve. In the lower panel, the straight line lies below a concave-down curve. Both example curves rise from left to right.Concave up: overestimateConcave down: underestimate
The coral segment joins the endpoints. Compare it with the blue curve to see the extra or missing area.

In both panels, the curve increases from left to right. One estimate is too large and the other is too small because the curves bend differently. Concavity, rather than whether the function increases or decreases, determines this comparison.

Example: Check concavity before calculating

Let’s estimate this integral using four trapezoids:

∫26ex2dx

For f(x)=ex2, the second derivative is

f′′(x)=(2+4x2)ex2

Both factors are positive on the interval from 2 to 6. The curve is concave up throughout that interval, so the trapezoidal approximation overestimates the integral. We can determine the direction of the error before finding the numerical approximation.

When is the trapezoidal rule exact?

For a linear function, the graph between any two endpoints is already a straight segment. The top of each trapezoid matches the graph, so the trapezoidal rule gives the exact integral.

If a function changes concavity within the interval, different parts of the estimate can contribute errors in opposite directions. A single concavity label then does not determine the overall result; we need to examine the pieces or compare the approximation with the integral.

What if the function is below the x-axis?

These comparisons concern the signed definite integral. “Overestimate” means the approximation is numerically larger, which can mean less negative when the integral is negative. For a nonnegative function, the definite integral is also the ordinary area under the curve.

For the calculation itself, see how to use the trapezoidal rule.