Tutorials › AP Calculus › Positive and Negative Contributions to Average Value

Accumulation and Average Value · Tutorial 626 of 999

Positive and Negative Contributions to Average Value

Understand when positive and negative function values cancel and how the signed average differs from the average magnitude.

Intermediate 9 min read

What You'll Learn

  • Interpret positive and negative contributions to a signed average
  • Calculate the average absolute value on an interval
  • Split an integral where a function changes sign
  • Explain how cancellation can make a signed average zero
  • Compare signed and absolute averages using an inequality

Two Different Kinds of Average

A function can take both positive and negative values on an interval. Its average value accounts for the signs: positive contributions increase the average, while negative contributions decrease it. As a result, contributions can cancel.

Sometimes the question is instead about the typical magnitude of the function, regardless of its sign. That calls for averaging the absolute values. These are related quantities, but they answer different questions.

Definition: For an integrable function \(f\) on an interval \([a,b]\), where \(a<b\), its signed average value is \(\frac{1}{b-a}\int_a^b f(x)\,dx\). Its average absolute value is \(\frac{1}{b-a}\int_a^b |f(x)|\,dx\). The first preserves signs; the second measures magnitudes.

The denominator \(b-a\) is the interval's length in the input variable. Both averages therefore use the same normalization. The difference is the integrand: \(f(x)\) for the signed average and \(|f(x)|\) for the average absolute value.

Separate the Positive and Negative Contributions

To describe cancellation precisely, define the positive and negative parts of \(f\) by \(f^+(x)=\max(f(x),0)\) and \(f^-(x)=\max(-f(x),0)\). Both are nonnegative. At each input, at most one is nonzero, and they satisfy \(f=f^+-f^-\) and \(|f|=f^++f^-\).

Let \(P=\int_a^b f^+(x)\,dx\) and \(N=\int_a^b f^-(x)\,dx\). These quantities are nonnegative. The signed integral is \(P-N\), whereas the integral of the absolute value is \(P+N\). Dividing each by the interval length gives the corresponding averages.

$$ \text{Signed average}=\frac{P-N}{b-a}, \qquad \text{Average absolute value}=\frac{P+N}{b-a}. $$

This decomposition explains why a signed average can be small even when the function's values are often far from zero: substantial positive and negative contributions may nearly or completely cancel. In contrast, the average absolute value adds their magnitudes instead of subtracting them.

A Relationship Between the Two Averages

The average absolute value is always at least as large as the absolute value of the signed average. To see why, use the nonnegative quantities \(P\) and \(N\). For any nonnegative numbers, the absolute value of their difference is no greater than their sum. Thus \(|P-N|\leq P+N\). Dividing by the positive interval length preserves the inequality.

Theorem: For an integrable function \(f\) on \([a,b]\), with \(a<b\), \(\left|\frac{1}{b-a}\int_a^b f(x)\,dx\right|\leq\frac{1}{b-a}\int_a^b |f(x)|\,dx\). Equality holds when one of \(P\) and \(N\) is zero; that is, when \(f\) has only one sign apart from values equal to zero, in the integral sense.

The inequality does not say that the signed average is always positive. It says that its magnitude cannot exceed the average absolute value. If positive and negative contributions balance exactly, the signed average is zero even though the average absolute value may be positive.

Worked Example: A Linear Function with Equal Positive and Negative Contributions

Worked Example: A Linear Function with Equal Positive and Negative Contributions

Find the signed average value and the average absolute value of \(f(x)=x-1\) on \([0,2]\).

The interval length is \(2-0=2\). First calculate the signed integral:

$$ \int_0^2 (x-1)\,dx =\left[\frac{x^2}{2}-x\right]_0^2 =\left(\frac{4}{2}-2\right)-\left(0-0\right) =0. $$

Therefore the signed average is \(0/2=0\). For the absolute value, \(x-1\) is negative on \([0,1)\) and positive on \((1,2]\), so split at \(x=1\):

$$ \begin{aligned} \int_0^2 |x-1|\,dx &=\int_0^1(1-x)\,dx+\int_1^2(x-1)\,dx\\ &=\left[x-\frac{x^2}{2}\right]_0^1 +\left[\frac{x^2}{2}-x\right]_1^2\\ &=\left(1-\frac12\right)-0 +\left(2-2\right)-\left(\frac12-1\right)\\ &=\frac12+\frac12=1. \end{aligned} $$

Thus the average absolute value is \(1/2\). As a check, the negative contribution to the signed integral is \(-1/2\), and the positive contribution is \(1/2\); their sum is \(0\), while their magnitudes sum to \(1\). Dividing these totals by the interval length \(2\) gives \(0\) and \(1/2\), respectively.

Finding Where to Split

To calculate an integral of \(|f(x)|\), identify where \(f\) is positive and where it is negative. On intervals where \(f(x)\geq 0\), \(|f(x)|=f(x)\); where \(f(x)<0\), \(|f(x)|=-f(x)\). A sign change can therefore require splitting the integral at a zero of \(f\).

1
Find the sign intervals.
Determine where \(f\) is positive, negative, or zero on the interval.
2
Write the absolute value on each interval.
Use \(f\) where \(f\geq 0\), and \(-f\) where \(f<0\).
3
Integrate and normalize.
Add the pieces for \(\int_a^b |f(x)|\,dx\), then divide by \(b-a\).

Zeros inside the interval are natural places to split, but the sign must still be checked: a function can touch zero without changing sign. The absolute-value integral uses the function's sign on each subinterval, not merely a list of its zeros.

Worked Example: A Piecewise Function with Exact Cancellation

Worked Example: A Piecewise Function with Exact Cancellation

Let \(g(x)=2\) for \(0\leq x<1\), and \(g(x)=-1\) for \(1\leq x\leq 3\). Find both averages on \([0,3]\). The value assigned at the single point \(x=1\) does not affect either integral.

The interval length is \(3\). The signed integral is the sum of the constant value times the length of each piece:

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

So the signed average is \(0/3=0\). For the absolute-value integral, the two magnitudes are \(2\) and \(1\):

$$ \int_0^3 |g(x)|\,dx =|2|(1-0)+|-1|(3-1) =2(1)+1(2)=4. $$

The average absolute value is \(4/3\). Check the contributions: the positive signed contribution is \(2\), and the negative signed contribution is \(-2\), giving net change \(0\). Their magnitudes add to \(4\), so dividing by \(3\) gives the stated absolute average.

Worked Example: A Function with Unequal Positive and Negative Contributions

Worked Example: A Function with Unequal Positive and Negative Contributions

For \(h(x)=x^2-1\) on \([-2,2]\), find the signed average and the average absolute value. The function is negative for \(-1<x<1\) and positive for \(-2\leq x<-1\) and \(1<x\leq 2\).

An antiderivative of \(x^2-1\) is \(F(x)=x^3/3-x\). The signed integral is

$$ \begin{aligned} \int_{-2}^{2}(x^2-1)\,dx &=F(2)-F(-2)\\ &=\left(\frac83-2\right)-\left(-\frac83+2\right)\\ &=\frac23-\left(-\frac23\right)=\frac43. \end{aligned} $$

The interval length is \(2-(-2)=4\), so the signed average is \((4/3)/4=1/3\). To find the average absolute value, calculate the positive and negative contributions separately. On \([1,2]\), the positive contribution is

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

By symmetry, the contribution on \([-2,-1]\) is also \(4/3\), giving total positive contribution \(8/3\). On \([-1,1]\), the function is negative, so its contribution to the integral of the absolute value is

$$ \int_{-1}^{1}(1-x^2)\,dx =\left[x-\frac{x^3}{3}\right]_{-1}^{1} =\left(1-\frac13\right)-\left(-1+\frac13\right) =\frac23-\left(-\frac23\right) =\frac43. $$

Consequently, \(\int_{-2}^{2}|x^2-1|\,dx=8/3+4/3=4\), and the average absolute value is \(4/4=1\). Check the signed integral using the same contributions: \(8/3-4/3=4/3\), which reproduces the signed average \(1/3\). The inequality also holds: \(|1/3|\leq 1\).

A Common Mistake: Treating Cancellation as Magnitude

A frequent error is to calculate the signed integral correctly, then interpret its average as the typical size of the function. For \(f(x)=x-1\) on \([0,2]\), one might write:

$$ \frac{1}{2}\int_0^2(x-1)\,dx =\frac{0}{2}=0, \qquad\text{so the average magnitude is }0. $$

The first equation correctly gives the signed average, but the conclusion about magnitude is wrong. Positive and negative contributions canceled; neither contribution had magnitude zero. To find the average magnitude, the absolute value must be inside the integral:

$$ \frac{1}{2}\int_0^2|x-1|\,dx =\frac{1}{2}\cdot 1 =\frac12. $$

Use the signed average when direction or net effect matters. Use the average absolute value when the question asks about magnitude without regard to sign. The wording of a problem determines which quantity is appropriate.

Key takeaway: Positive and negative values can reduce or eliminate a signed average through cancellation. Taking the absolute value before integrating prevents that cancellation and measures average magnitude instead.

Check Your Understanding

For each question, distinguish carefully between a signed contribution and a contribution to the average absolute value.

  1. For \(f(x)=x-2\) on \([0,4]\), where does the function change sign?
  2. For that function, compute the signed average value.
  3. For the same function and interval, compute the average absolute value.
  4. If the positive and negative contributions to an integral are equal in magnitude, what is the signed average?
  5. State the inequality relating the absolute value of the signed average to the average absolute value.

Test yourself: AP Calculus practice exams

Ready to check what you know? Work an AP-style practice exam, then open the full solutions.

Want all 1,114 practice problems?

This tutorial covers one topic. Calc Pass covers all of AP Calculus AB & BC: 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