Intuition What this page is for
The parent note gave you the formula
f avg = b − a 1 ∫ a b f ( x ) d x
and three friendly examples where everything was positive and tidy. But real problems are messier: functions dip below zero , intervals sit in negative territory, the average can come out negative or exactly zero , sometimes the interval shrinks to a single point, and word problems hide the formula in disguise.
This page walks every one of those scenarios , one at a time, from zero. By the end you should never meet a case you haven't already seen worked.
Every "average value" problem falls into one of these cells. We will hit all of them .
#
Case class
What's tricky about it
Example that covers it
C1
f ≥ 0 everywhere
the baseline, area is honest area
Ex 1
C2
f ≤ 0 everywhere
integral is negative → average negative
Ex 2
C3
f changes sign, symmetric
positive & negative bits cancel → average = 0
Ex 3
C4
f changes sign, not symmetric
partial cancellation → small nonzero average
Ex 4
C5
interval in negative x
limits like [ − 2 , − 1 ] , watch the width
Ex 5
C6
degenerate: b − a → 0
formula becomes 0/0 → limiting value
Ex 6
C7
real-world word problem
you must find a , b , f yourself
Ex 7
C8
exam twist: find the c (MVT)
solve f ( c ) = f avg , keep the root in range
Ex 8
The last cell uses the Mean Value Theorem for Integrals (abbreviated MVT from here on — it is the theorem that guarantees a special interior point c where the function equals its own average).
Before we start, one thing to burn in: an integral is a signed area . Bits of the curve above the x -axis count as positive area; bits below count as negative area. The average value is that signed area divided by the width. The figure below shows exactly this.
Figure 1 — A wiggly f crossing the x -axis. The green shading is the piece of area above the axis (it counts as + ); the red shading is the piece below the axis (it counts as − ). The integral is green-area minus red-area, and the average is that signed total spread across the width. This one picture is the engine behind every case on this page.
Definition Signed area (the one idea behind every case)
∫ a b f d x = ( area above axis ) − ( area below axis ) . Dividing by b − a turns this signed total into an average height , which can be positive, negative, or zero. See Definite Integral as Area .
Worked example Example 1 —
f ( x ) = x 2 on [ 1 , 4 ]
Forecast: x 2 runs from 1 up to 16 . It's a curve that grows fast , so it spends more time near the top. Guess the average is well above the midpoint of 1 and 16 (which is 8.5 )? Actually curves that accelerate spend more time low , so guess a bit below 8.5 . Hold that thought.
Step 1. Write the formula with a = 1 , b = 4 :
f avg = 4 − 1 1 ∫ 1 4 x 2 d x .
Why this step? Slot the endpoints in so the machinery has numbers.
Step 2. Antiderivative of x 2 is 3 x 3 (power rule, from the Fundamental Theorem of Calculus ):
∫ 1 4 x 2 d x = [ 3 x 3 ] 1 4 = 3 64 − 3 1 = 3 63 = 21.
Why this step? The FTC says evaluate the antiderivative at top minus bottom.
Step 3. Divide by the width 4 − 1 = 3 :
f avg = 3 21 = 7.
Why this step? The integral 21 is an area , not an average; dividing by the width b − a spreads that total evenly across the interval to give the average height .
Answer: f avg = 7 .
Verify: 7 lies between min = 1 and max = 16 ✓, and it's below the endpoint-midpoint 8.5 — exactly as forecast, because x 2 is concave-up so it hugs the low values. Units none (pure numbers). ✓
Worked example Example 2 —
f ( x ) = − 2 x on [ 1 , 3 ]
Forecast: the whole curve sits below the axis (for x > 0 , − 2 x < 0 ). Signed area is negative, so the average must be negative. It's a straight line from − 2 to − 6 ; for a line the average is the midpoint value, so guess − 4 .
Step 1. Formula, a = 1 , b = 3 :
f avg = 3 − 1 1 ∫ 1 3 ( − 2 x ) d x .
Why this step? Same recipe — the sign of f doesn't change the procedure, only the result.
Step 2. Antiderivative of − 2 x is − x 2 :
∫ 1 3 ( − 2 x ) d x = [ − x 2 ] 1 3 = ( − 9 ) − ( − 1 ) = − 8.
Why this step? This negative number is the signed area — the region lives below the axis.
Step 3. Divide by width 2 :
f avg = 2 − 8 = − 4.
Why this step? Same reason as always — the integral − 8 is a signed area; dividing by the width b − a = 2 converts it into an average height, and because the area was negative the average comes out negative too.
Answer: f avg = − 4 .
Verify: matches the line-midpoint forecast: at x = 2 , f ( 2 ) = − 4 ✓. Negative, as required for a curve entirely below the axis. ✓
Worked example Example 3 —
f ( x ) = sin x on [ 0 , 2 π ]
Forecast: on the first half [ 0 , π ] sine is a positive hump; on the second half [ π , 2 π ] it's an identical negative hump. The two areas are mirror images. Guess the average is exactly 0 .
Figure 2 — sin x over [ 0 , 2 π ] . The green lobe on [ 0 , π ] has signed area + 2 ; the red lobe on [ π , 2 π ] has signed area − 2 . They are perfect mirror images, so they cancel and the dashed orange line marks the resulting average of exactly 0 .
Step 1. Formula, a = 0 , b = 2 π :
f avg = 2 π 1 ∫ 0 2 π sin x d x .
Why this step? We write the average-value formula with the given endpoints a = 0 , b = 2 π so the abstract recipe becomes a concrete computation we can carry out.
Step 2. Antiderivative of sin x is − cos x :
∫ 0 2 π sin x d x = [ − cos x ] 0 2 π = − cos ( 2 π ) + cos 0 = − 1 + 1 = 0.
Why this step? The positive hump (+ 2 ) and the negative hump (− 2 ) cancel exactly — look at the two shaded lobes in the figure.
Step 3. Divide by 2 π : f avg = 2 π 0 = 0.
Why this step? Dividing the signed area by the width b − a = 2 π turns the total into an average height; since the area was 0 , the average is 0 regardless of how wide the interval is.
Answer: f avg = 0 .
Verify: an average of 0 does not mean the function is 0 — it means the ups and downs balance. Compare with the parent note's [ 0 , π ] case where the average was π 2 ; here we added the mirror half and it cancelled. ✓
Worked example Example 4 —
f ( x ) = x 3 on [ − 1 , 2 ]
Forecast: on [ − 1 , 0 ] the cube is negative; on [ 0 , 2 ] it's positive and grows fast up to 8 . The positive part is much bigger, so the average is positive but not huge. Guess around 1 .
Step 1. Formula, a = − 1 , b = 2 , width = 2 − ( − 1 ) = 3 :
f avg = 3 1 ∫ − 1 2 x 3 d x .
Why this step? Compute width carefully: subtracting a negative adds . This is the classic sign trap (see the parent note's third mistake).
Step 2. Antiderivative of x 3 is 4 x 4 :
∫ − 1 2 x 3 d x = [ 4 x 4 ] − 1 2 = 4 16 − 4 1 = 4 15 .
Why this step? ( − 1 ) 4 = + 1 , not − 1 — an even power kills the sign. Watch this.
Step 3. Divide by 3 :
f avg = 3 15/4 = 12 15 = 4 5 = 1.25.
Why this step? The integral 4 15 is the signed area (positive lobe minus negative lobe); dividing by the width b − a = 3 turns that leftover area into the average height.
Answer: f avg = 4 5 = 1.25 .
Verify: positive (the big positive lobe wins), and modest — close to our forecast of 1 . It sits between min f ( − 1 ) = − 1 and max f ( 2 ) = 8 ✓. ✓
Worked example Example 5 —
f ( x ) = e x on [ − 2 , 0 ]
Forecast: e x is always positive but small when x is negative: e − 2 ≈ 0.135 up to e 0 = 1 . The curve hugs the low values (it grows, so spends more time low), so guess the average is below the midpoint-of-values ( 0.135 + 1 ) /2 ≈ 0.57 , maybe around 0.43 .
Step 1. Formula, a = − 2 , b = 0 , width = 0 − ( − 2 ) = 2 :
f avg = 2 1 ∫ − 2 0 e x d x .
Why this step? The interval is entirely negative x , but the width b − a is still positive — that's all that matters.
Step 2. Antiderivative of e x is e x (it's its own antiderivative — the whole reason e is special):
∫ − 2 0 e x d x = [ e x ] − 2 0 = e 0 − e − 2 = 1 − e − 2 .
Why this step? We used e x because it's the one function that integrates to itself, so no new pieces appear.
Step 3. Divide by 2 :
f avg = 2 1 − e − 2 = 2 1 − 0.1353 … ≈ 2 0.8647 ≈ 0.4323.
Why this step? The integral 1 − e − 2 is the area under the curve; dividing by the width b − a = 2 spreads that area evenly to give the average height.
Answer: f avg = 2 1 − e − 2 ≈ 0.432 .
Verify: between e − 2 ≈ 0.135 and 1 ✓, and below 0.57 as forecast (concave-up curve favours low values). ✓
Worked example Example 6 — average of
f ( x ) = x 2 on [ 2 , 2 + h ] as h → 0
Forecast: if you average a function over a tiny interval around x = 2 , you're basically reading its value at x = 2 . So guess the limit is f ( 2 ) = 4 .
Step 1. Write the average over [ 2 , 2 + h ] :
f avg ( h ) = h 1 ∫ 2 2 + h x 2 d x .
Why this step? Here the width is h , which we will let shrink to 0 . Plugging h = 0 directly gives 0 0 — undefined — so we need a limit , exactly the tool for "what value does this approach."
Step 2. Evaluate the integral:
∫ 2 2 + h x 2 d x = [ 3 x 3 ] 2 2 + h = 3 ( 2 + h ) 3 − 8 .
Why this step? We compute the integral first (leaving h as a symbol) so that afterwards we can algebraically cancel the troublesome h in the denominator — you cannot cancel what you have not yet written out.
Step 3. Expand ( 2 + h ) 3 = 8 + 12 h + 6 h 2 + h 3 , so the integral = 3 12 h + 6 h 2 + h 3 . Divide by h :
f avg ( h ) = 3 h 12 h + 6 h 2 + h 3 = 3 12 + 6 h + h 2 .
Why this step? Cancelling the h removes the 0/0 problem — now we can safely set h = 0 .
Step 4. Take h → 0 :
lim h → 0 f avg ( h ) = 3 12 + 0 + 0 = 4.
Why this step? Now that the expression is a clean polynomial with no division by h , letting h → 0 just substitutes h = 0 — this is the limit that captures "shrink the window to the single point x = 2 ."
Answer: the limiting average is 4 = f ( 2 ) .
Verify: exactly the forecast. This is the deep link to the Mean Value Theorem (Derivatives) / MVT for integrals: as the window collapses, the average value collapses onto the function's actual value at the point. ✓
Worked example Example 7 — average temperature over a day
The temperature (°C) in a greenhouse over a 12 -hour day is modelled by
T ( t ) = 18 + 6 sin ( 12 π t ) , 0 ≤ t ≤ 12 ,
with t in hours. What is the average temperature over the day?
Forecast: the sin term wobbles the temperature up and down around a base of 18 . Over a half-period (0 to 12 is half of sin 's 24 -hour period) the sine is a positive hump, so the average sits above 18 . Guess around 22 .
Step 1. Identify the pieces: f = T , a = 0 , b = 12 , width = 12 :
T avg = 12 1 ∫ 0 12 [ 18 + 6 sin ( 12 π t ) ] d t .
Why this step? The word "average over the day" is the average-value formula — you just had to spot a , b , f .
Step 2. Split the integral (linearity):
∫ 0 12 18 d t = 18 ⋅ 12 = 216.
For the sine part, antiderivative of sin ( k t ) is − k 1 cos ( k t ) with k = 12 π :
∫ 0 12 6 sin ( 12 π t ) d t = 6 ⋅ [ − π 12 cos ( 12 π t ) ] 0 12 = − π 72 ( cos π − cos 0 ) .
Why this step? We need the chain-rule factor π 12 because the inside is 12 π t , not just t .
Step 3. Evaluate: cos π − cos 0 = − 1 − 1 = − 2 , so the sine integral = − π 72 ( − 2 ) = π 144 .
Why this step? We plug the endpoints t = 12 and t = 0 into 12 π t , giving cos π and cos 0 ; these are the exact known values − 1 and + 1 , so the bracket becomes − 2 and the double negative flips the sign to a positive π 144 .
Step 4. Total integral = 216 + π 144 ; divide by 12 :
T avg = 12 216 + π 144 = 18 + π 12 ≈ 18 + 3.82 = 21.82 °C .
Why this step? The integral 216 + π 144 is the total "temperature-hours" accumulated; dividing by the width b − a = 12 hours spreads it evenly to give the average temperature — total ÷ length, the heart of the formula.
Answer: T avg = 18 + π 12 ≈ 21.8 °C.
Verify: above the base 18 as forecast ✓, and within the actual temperature range [ 18 , 24 ] (since sin maxes at 1 , giving 24 ) ✓. Units: °C, correct — the 12 1 has units 1/ hr and cancels the hr from d t . ✓
Worked example Example 8 — locate
c from the MVT for Integrals
For f ( x ) = x 2 on [ 1 , 4 ] (same as Example 1), the Mean Value Theorem for Integrals (MVT) promises some c ∈ [ 1 , 4 ] with f ( c ) = f avg . Find c .
Forecast: in Ex 1 we got f avg = 7 . So we need c 2 = 7 , i.e. c = 7 ≈ 2.65 . That should land inside [ 1 , 4 ] .
Step 1. We already have f avg = 7 from Example 1. Set f ( c ) equal to it:
c 2 = 7.
Why this step? The MVT for integrals says f ( c ) = f avg for some interior c — this is the equation that finds it. It exists because 7 lies between min = 1 and max = 16 , and the Intermediate Value Theorem guarantees a continuous f hits every value in between.
Step 2. Solve: c = ± 7 . Reject c = − 7 because it's outside [ 1 , 4 ] :
c = 7 ≈ 2.6458.
Why this step? Cases matter — the algebra gives two roots, but only the one in the interval is the MVT point.
Answer: c = 7 ≈ 2.65 .
Verify: 2.65 ∈ [ 1 , 4 ] ✓ and ( 7 ) 2 = 7 = f avg ✓. Geometrically: this is the x where the curve crosses the flat average-line. ✓
Recall When is the average value negative?
When the signed area is negative — i.e. the region below the axis outweighs the region above. ::: The sign of f avg is the sign of ∫ a b f d x , since b − a > 0 always.
Recall Why can the average be exactly zero even when
f is never zero on the interval?
Positive and negative signed areas cancel. ::: Example: sin x on [ 0 , 2 π ] — the two humps are mirror images, so they sum to 0 .
Recall As the interval collapses (
b − a → 0 around a point p ), what does the average approach?
The value f ( p ) . ::: The 0 0 resolves by a limit; the tiny-window average reads off the point value.
"Below the axis, below zero." Any stretch of curve under the x -axis drags the average down . Symmetric ups-and-downs → average zero .