← Back to learning objective

Midpoint Riemann sum for f(x) = |x - 2| with n = 4

Consider the function f(x)=∣x−2∣f(x) = |x - 2| on the interval [0,4][0, 4].

Partition [0,4][0, 4] into n=4n = 4 subintervals of equal width, and use the midpoint of each subinterval to approximate the area between f(x)=∣x−2∣f(x) = |x-2| and the xx-axis on [0,4][0,4].

Midpoint Riemann sum for f(x) = |x - 2| with n = 4 graph

Compute the midpoint sum M4M_4 for this function on [0,4][0,4].

Hint

First find Δx=4−04\Delta x = \frac{4-0}{4}, list the four subintervals, and identify the midpoint of each one. Then evaluate ff at each midpoint and add up f(midpoint)⋅Δxf(\text{midpoint}) \cdot \Delta x for all four rectangles.

Step-by-step solution

With n=4n = 4 subintervals on [0,4][0,4], the width is Δx=4−04=1\Delta x = \frac{4-0}{4} = 1. The subintervals are [0,1],[1,2],[2,3],[3,4][0,1], [1,2], [2,3], [3,4], with midpoints 0.5,1.5,2.5,3.50.5, 1.5, 2.5, 3.5 respectively.

Evaluating f(x)=∣x−2∣f(x) = |x-2| at each midpoint gives f(0.5)=1.5f(0.5) = 1.5, f(1.5)=0.5f(1.5) = 0.5, f(2.5)=0.5f(2.5) = 0.5, f(3.5)=1.5f(3.5) = 1.5. The midpoint sum is M4=Δx[f(0.5)+f(1.5)+f(2.5)+f(3.5)]=1⋅(1.5+0.5+0.5+1.5)=4M_4 = \Delta x \left[f(0.5) + f(1.5) + f(2.5) + f(3.5)\right] = 1 \cdot (1.5 + 0.5 + 0.5 + 1.5) = 4.

Comparing midpoint heights used in the sum

Hint
Step-by-step solution

Yes. The midpoints zero point five and three point five both gave height one point five, and the midpoints one point five and two point five both gave height zero point five. This happens because the graph of absolute value of x minus two is symmetric about x equals two, so midpoints equally spaced from the vertex produce matching heights.

Related problems

Practice similar Calculus problems interactively.

Start Closing the Gap