← Back to all lessons
Class 12Calculus12:06Published 26 Oct 2024

Definite Integrals of Modulus Functions (Exercise 7.10)

Learn how to evaluate definite integrals that contain a modulus (absolute value) by splitting the interval where the inside of the modulus changes sign, using property P2 from Exercise 7.10.

This lesson works through three definite integrals with absolute values from Exercise 7.10. The key idea is to find the point where the expression inside the modulus changes sign, split the integral there using the property that an integral from a to b equals the integral from a to c plus the integral from c to b, and rewrite each piece without the modulus. After integrating both pieces and applying the limits, the answers come out to 29, 9, and 5. A faster shortcut formula for one of the questions is also shown.

What you'll learn

  • Splitting a definite integral at the point where the expression inside the modulus changes sign
  • Rewriting an absolute value as two cases so the modulus can be removed before integrating
  • Applying the property that an integral over a whole interval is the sum of the integrals over its parts
  • Using a quick shortcut formula for the integral of an absolute value

Lesson chapters

0:00Property P2 for splitting integrals
0:19Question 5: integral of |x + 2| from -5 to 5
3:57Question 6: integral of |x - 5| from 2 to 8
8:21Question 5 again using the shortcut formula
9:32Question 18: integral of |x - 1| from 0 to 4

Lesson notes

This lesson evaluates definite integrals containing a modulus by splitting the interval at the point where the inside of the absolute value changes sign, using property P2 from Exercise 7.10. Three questions are worked in full, and one is also solved with a shortcut formula.

The splitting property (P2)

The core tool is the property that an integral over an interval equals the sum of the integrals over its two parts, where cc lies between aa and bb:

abf(x)dx=acf(x)dx+cbf(x)dx\int_a^b f(x)\,dx = \int_a^c f(x)\,dx + \int_c^b f(x)\,dx

For a modulus, we choose cc to be the point where the expression inside changes sign, and use the definition

u={uu0uu<0|u| = \begin{cases} u & u \ge 0 \\ -u & u < 0 \end{cases}

Question 5: 55x+2dx\int_{-5}^{5} |x + 2|\,dx

Here x+20x + 2 \ge 0 when x2x \ge -2 and x+2<0x + 2 < 0 when x<2x < -2, so the sign changes at c=2c = -2. Split there:

55x+2dx=52(x+2)dx+25(x+2)dx\int_{-5}^{5} |x+2|\,dx = \int_{-5}^{-2} -(x+2)\,dx + \int_{-2}^{5} (x+2)\,dx

Left piece

52(x+2)dx=[(x22+2x)]52=[(24)(25210)]=92\int_{-5}^{-2} -(x+2)\,dx = \left[-\left(\tfrac{x^2}{2} + 2x\right)\right]_{-5}^{-2} = -\Big[(2 - 4) - (\tfrac{25}{2} - 10)\Big] = \tfrac{9}{2}

Right piece

25(x+2)dx=[x22+2x]25=(252+10)(24)=492\int_{-2}^{5} (x+2)\,dx = \left[\tfrac{x^2}{2} + 2x\right]_{-2}^{5} = (\tfrac{25}{2} + 10) - (2 - 4) = \tfrac{49}{2}

Adding the two pieces:

92+492=582=29\tfrac{9}{2} + \tfrac{49}{2} = \tfrac{58}{2} = 29

Question 6: 28x5dx\int_{2}^{8} |x - 5|\,dx

Now x50x - 5 \ge 0 when x5x \ge 5 and x5<0x - 5 < 0 when x<5x < 5, so c=5c = 5, which lies between 22 and 88. Split there:

28x5dx=25(x5)dx+58(x5)dx\int_{2}^{8} |x-5|\,dx = \int_{2}^{5} -(x-5)\,dx + \int_{5}^{8} (x-5)\,dx

Left piece

25(x5)dx=[(x225x)]25=[(25225)(210)]=92\int_{2}^{5} -(x-5)\,dx = \left[-\left(\tfrac{x^2}{2} - 5x\right)\right]_{2}^{5} = -\Big[(\tfrac{25}{2} - 25) - (2 - 10)\Big] = \tfrac{9}{2}

Right piece

58(x5)dx=[x225x]58=(3240)(25225)=92\int_{5}^{8} (x-5)\,dx = \left[\tfrac{x^2}{2} - 5x\right]_{5}^{8} = (32 - 40) - (\tfrac{25}{2} - 25) = \tfrac{9}{2}

Adding the pieces:

92+92=9\tfrac{9}{2} + \tfrac{9}{2} = 9

Question 5 again, using a shortcut

The same integral can be done with the formula

udu=uu2\int |u|\,du = \frac{u\,|u|}{2}

Applied to x+2|x+2|:

55x+2dx=[(x+2)x+22]55=772(3)32=492+92=29\int_{-5}^{5} |x+2|\,dx = \left[\frac{(x+2)\,|x+2|}{2}\right]_{-5}^{5} = \frac{7 \cdot 7}{2} - \frac{(-3)\cdot 3}{2} = \tfrac{49}{2} + \tfrac{9}{2} = 29

which matches the answer found by splitting.

Question 18: 04x1dx\int_{0}^{4} |x - 1|\,dx

Here x10x - 1 \ge 0 when x1x \ge 1 and x1<0x - 1 < 0 when x<1x < 1, so c=1c = 1. Split there:

04x1dx=01(x1)dx+14(x1)dx\int_{0}^{4} |x-1|\,dx = \int_{0}^{1} -(x-1)\,dx + \int_{1}^{4} (x-1)\,dx

Left piece

01(x1)dx=[(x22x)]01=[(121)0]=12\int_{0}^{1} -(x-1)\,dx = \left[-\left(\tfrac{x^2}{2} - x\right)\right]_{0}^{1} = -\big[(\tfrac{1}{2} - 1) - 0\big] = \tfrac{1}{2}

Right piece

14(x1)dx=[x22x]14=(84)(121)=92\int_{1}^{4} (x-1)\,dx = \left[\tfrac{x^2}{2} - x\right]_{1}^{4} = (8 - 4) - (\tfrac{1}{2} - 1) = \tfrac{9}{2}

Adding the pieces:

12+92=102=5\tfrac{1}{2} + \tfrac{9}{2} = \tfrac{10}{2} = 5

Key takeaways

  • To integrate a modulus, split the interval at the point cc where the inside changes sign, and use ab=ac+cb\int_a^b = \int_a^c + \int_c^b.
  • On each piece, replace u|u| by uu where u0u \ge 0 and by u-u where u<0u < 0, then integrate as normal.
  • For a simple linear inside, the shortcut udu=uu2\int |u|\,du = \tfrac{u\,|u|}{2} gives the same result more quickly.