Tutorials › Calculus I › Cancellation Across Sign Changes

Integral Properties and Estimates · Tutorial 988 of 1495

Cancellation Across Sign Changes

Use sign changes and interval additivity to distinguish a graph’s net signed contribution from its total area.

Intermediate 11 min read

What You'll Learn

  • Split a definite integral at points where a function changes sign.
  • Define the positive and negative contributions of an integrable function.
  • Show why a signed integral is the positive contribution minus the negative magnitude.
  • Recognize exact cancellation, including the case when both contributions are zero.
  • Distinguish a zero signed integral from zero total area.
  • Check cancellation calculations using interval additivity and absolute values.

Positive and Negative Contributions

A definite integral records a signed accumulation. Where a function is above the horizontal axis, its values contribute positively; where it is below the axis, its values contribute negatively. These contributions can cancel when they are combined.

Interval additivity makes the cancellation visible. If \(f\) is integrable on \([a,b]\) and \(c\) lies between \(a\) and \(b\), then the integral over the whole interval is the sum of the integrals over the two pieces. When \(c\) is a point where the sign changes, the pieces can be interpreted separately as positive and negative contributions.

Definition: For a continuous function \(f\) on \([a,b]\), define its positive part and negative part by \(f^+(x)=\max(f(x),0)\) and \(f^-(x)=\max(-f(x),0)\). The positive contribution is \(P=\int_a^b f^+(x)\,dx\), and the negative magnitude is \(N=\int_a^b f^-(x)\,dx\). Both \(P\) and \(N\) are nonnegative.

Continuity is a convenient sufficient condition here: \(f^+\), \(f^-\), and \(|f|\) are then continuous and integrable. The same identities hold for any Riemann integrable \(f\), but continuity will be enough for the discussion and examples below.

At each point \(x\), at most one of \(f^+(x)\) and \(f^-(x)\) is nonzero. Their pointwise relationships to \(f\) and \(|f|\) are the key to separating signed accumulation from total area.

$$ f=f^+-f^- \qquad\text{and}\qquad |f|=f^++f^-. $$

The Cancellation Identities

Integrating the pointwise identities gives two useful equations. The first says that the signed integral is the positive contribution minus the magnitude of the negative contribution. The second says that the total area between the graph and the horizontal axis is the sum of those two nonnegative contributions.

Theorem: If \(f\) is continuous on \([a,b]\), then \(\int_a^b f(x)\,dx=P-N\) and \(\int_a^b |f(x)|\,dx=P+N\), where \(P=\int_a^b f^+(x)\,dx\) and \(N=\int_a^b f^-(x)\,dx\).

The first identity follows from linearity of the integral applied to \(f=f^+-f^-\); the second follows by integrating \(|f|=f^++f^-\). In each case, the integrals of the positive and negative parts are nonnegative because those functions are nonnegative.

These identities give an exact test for cancellation. If the signed integral is zero, then \(P-N=0\), so \(P=N\). This does not necessarily mean either contribution is zero: both may be zero, or they may be positive and equal. The total area is zero precisely when \(P+N=0\). Since both terms are nonnegative, that requires \(P=N=0\).

$$ \int_a^b f(x)\,dx=0 \quad\Longleftrightarrow\quad P=N, \qquad \int_a^b |f(x)|\,dx=0 \quad\Longleftrightarrow\quad P=N=0. $$

Why Splitting at Sign Changes Works

Suppose a continuous function has one sign on each of a finite number of consecutive subintervals. At a point where its sign changes, split the integral. Interval additivity says that the original integral equals the sum of the integrals on the pieces. On a piece where \(f\geq 0\), the integral contributes to \(P\); on a piece where \(f\leq 0\), it contributes \(-N\). Adding the pieces therefore preserves the sign of each contribution and shows precisely how they can cancel.

This reasoning does not require a function to change sign at every zero. A graph may touch the axis and remain on the same side; such a zero is not a sign change. Also, a continuous function can have infinitely many zeros. In that situation, do not assume that listing finitely many crossing points will split every positive and negative portion. The definitions using \(f^+\) and \(f^-\) still apply, and the two identities above remain valid.

1
Locate the sign changes.
Find the points that divide the interval into pieces on which the function has a consistent sign.
2
Use interval additivity.
Write the integral over the full interval as the sum of the integrals over those pieces.
3
Keep the signs attached.
Positive pieces contribute to \(P\); negative pieces contribute negative values to the signed integral and positive values to \(N\).
4
Compare the two totals.
The signed integral is \(P-N\), while the total area is \(P+N\).

Worked Examples

Worked Example: Equal Contributions Cancel

Let \(f(x)=x-1\) on \([0,2]\). The function is negative for \(0\leq x<1\), zero at \(x=1\), and positive for \(1<x\leq 2\). Split at \(x=1\), and use the antiderivative \(F(x)=\frac{x^2}{2}-x\), for which \(F'(x)=x-1=f(x)\).

On the negative interval,

$$ \int_0^1 (x-1)\,dx =F(1)-F(0) =\left(\frac12-1\right)-0 =-\frac12. $$

Thus the negative magnitude is \(N=\frac12\). On the positive interval,

$$ \int_1^2 (x-1)\,dx =F(2)-F(1) =(2-2)-\left(\frac12-1\right) =\frac12. $$

Interval additivity now gives

$$ \int_0^2 (x-1)\,dx =-\frac12+\frac12=0. $$

The positive contribution is \(P=\frac12\), equal to \(N\), so the contributions cancel exactly. The total area is instead

$$ \int_0^2 |x-1|\,dx =\frac12+\frac12=1. $$

As a check, \(F'(x)=x-1\), and the two subinterval integrals recombine to give the whole-interval integral.

Worked Example: A Nonzero Signed Integral

Let \(f(x)=x-1\) on \([0,3]\). It is negative on \([0,1)\) and positive on \((1,3]\). Again use \(F(x)=\frac{x^2}{2}-x\), with \(F'(x)=x-1\). The negative piece is

$$ \int_0^1 (x-1)\,dx =F(1)-F(0) =\left(\frac12-1\right)-0 =-\frac12, $$

so \(N=\frac12\). The positive piece is

$$ \int_1^3 (x-1)\,dx =F(3)-F(1) =\left(\frac92-3\right)-\left(\frac12-1\right) =\frac32+\frac12=2, $$

so \(P=2\). The signed integral and total area are therefore

$$ \int_0^3 (x-1)\,dx=P-N=2-\frac12=\frac32, \qquad \int_0^3 |x-1|\,dx=P+N=2+\frac12=\frac52. $$

As a direct check, \(F(3)-F(0)=\frac92-3=\frac32\), agreeing with the sum of the two pieces. The derivative check \(F'(x)=x-1\) confirms the antiderivative used.

Worked Example: Cancellation Across Several Pieces

Define the continuous, piecewise-linear function

$$ f(x)= \begin{cases} 2x, & 0\leq x\leq 1,\\ 4-2x, & 1\leq x\leq 2,\\ 4-2x, & 2\leq x\leq 3,\\ 2x-8, & 3\leq x\leq 4. \end{cases} $$

The formulas agree at the shared endpoints. The graph is nonnegative on \([0,2]\) and nonpositive on \([2,4]\). Compute each piece separately. On \([0,1]\), an antiderivative is \(x^2\), whose derivative is \(2x\), so

$$ \int_0^1 2x\,dx=1^2-0^2=1. $$

On \([1,2]\), an antiderivative of \(4-2x\) is \(4x-x^2\), whose derivative is \(4-2x\). Thus

$$ \int_1^2 (4-2x)\,dx =(8-4)-(4-1)=4-3=1. $$

The positive contribution is \(P=1+1=2\). On \([2,3]\), the same antiderivative gives

$$ \int_2^3 (4-2x)\,dx =(12-9)-(8-4)=3-4=-1. $$

On \([3,4]\), an antiderivative of \(2x-8\) is \(x^2-8x\), whose derivative is \(2x-8\). Therefore,

$$ \int_3^4 (2x-8)\,dx =(16-32)-(9-24)=-16-(-15)=-1. $$

The negative magnitude is \(N=1+1=2\). By interval additivity, the signed integral is \(1+1-1-1=0\), while the total area is \(2+2=4\). These values check against the identities \(P-N=0\) and \(P+N=4\). Each antiderivative differentiates to the formula on its own interval.

A Common Mistake: Calling a Zero Integral Zero Area

A frequent error is to reason, “The signed integral is zero, so the graph encloses no area.” That confuses the difference \(P-N\) with the sum \(P+N\). In the first worked example, the signed integral is zero, but the area is \(1\).

The correction is to distinguish the quantities before interpreting the answer:

$$ \text{signed integral}=P-N, \qquad \text{total area}=\int_a^b |f(x)|\,dx=P+N. $$

A zero signed integral means \(P=N\). It does not necessarily mean either contribution is zero: both may be zero, as for the zero function, or they may be positive and equal. By contrast, zero total area requires both contributions to be zero.

Why the Distinction Matters

When an integral represents net accumulation, positive and negative changes can offset one another. For instance, a quantity that increases and then decreases by the same amount has zero net change, but it has not remained unchanged throughout. The same distinction appears in a graph: equal positive and negative contributions make the signed integral zero even though the graph may enclose substantial area on both sides of the axis.

Interval additivity is useful because it lets you preserve this information rather than combine everything too early. Splitting at sign changes identifies which pieces add and which subtract. If only the signed integral is needed, the pieces can then be combined as \(P-N\). If total area is needed, use \(P+N\), equivalently the integral of the absolute value.

Key takeaway: A definite integral measures signed accumulation. Positive and negative contributions cancel when they have equal magnitude. Total area counts both contributions positively, so cancellation in the signed integral does not imply zero area.

Check Your Understanding

For each question, distinguish the signed integral from the positive and negative contributions.

  1. If \(P=5\) and \(N=5\), what are the signed integral and total area?
  2. If a continuous function is nonnegative throughout an interval and its integral is zero, what can you conclude about its positive contribution and total area?
  3. Why should an integral be split at a sign change when determining the positive and negative contributions?
  4. For \(f(x)=x-1\) on \([0,3]\), what are \(P\), \(N\), the signed integral, and the total area?
  5. Does every zero of a continuous function mark a sign change? Explain.

Test yourself: Calculus I final exam practice

Ready to check what you know? Work a full-length practice final, then open the complete worked solutions.

Want all 1,114 practice problems?

This tutorial covers one topic. Calc Pass covers the full Calculus AB & BC curriculum (the core of Calculus I and II): full review, every practice question, and step-by-step solutions to each one.

QR code to download the Calc Pass app

Get the Calc Pass App

Scan to download and practice on the go, with instant scoring.

Calc Pass Volume 1: 1,114 Practice Questions book cover

Vol. 1: 1,114 Questions

The complete practice question bank, organized by AB & BC topic.

View on Amazon
Calc Pass Volume 2: Solutions Manual book cover

Vol. 2: Solutions Manual

Fully worked solutions to every question in Volume 1.

View on Amazon