Evaluate the integral. $\int_{-2}^{4} f(x) dx$, where $f(x) = 2$ if $−2 \leq x \leq 0, 4 − x^2$ if $0 < x \leq 4$

9.2k Views Asked by At

Evaluate the integral. $$\int_{-2}^{4} f(x)dx$$ where $$f(x) = \begin{cases} 2 & \text{if $-2 \leq x \leq 0$}\\ 4 - x^2 & \text{if $0 < x \leq 4$} \end{cases} $$

After trying several different ways of trying to solve this problem with many different answers I would appreciate someone giving me a step by step way of solving this.

So far I've tried splitting the interval into two parts -2 to 0, and 0 to 4. I've also tried using the fundamental theorem of Calculus part 2.

1

There are 1 best solutions below

0
On BEST ANSWER

You are correct, you split the integral into two parts and use the definition of $f(x)$: $$ \begin{split} \int_{-2}^4 f(x) \;dx &= \int_{-2}^0 f(x) \; dx + \int_0^4 f(x) \; dx \\ &=\int_{-2}^0 2 \; dx + \int_0^4 (4-x^2) \; dx \\ &= 2 \int_{-2}^0 1\; dx + \left(4x - \dfrac{x^3}{3}\right)\bigg|_0^4 \\ &= 2 \big(0-(-2)\big) + \left[ \left(4(4) - \frac{4^3}{3}\right) - \big(4(0) - 0\big) \right] \\ &= 4 - \frac{16}{3} \\ &= -\frac{4}{3} \end{split} $$