1. ## Evaluate the Integral

Evaluate the Integral from -pi/2 to pi of 20 * abs cos(x) dx ? I got the answer -20 but it seems to be incorrect. Can anyone provide an explanation?

2. ## Re: Evaluate the Integral

Originally Posted by sic
Evaluate the Integral from -pi/2 to pi of 20 * abs cos(x) dx ? I got the answer -20 but it seems to be incorrect. Can anyone provide an explanation?
well let's take a look

$$\int_{-\frac{\pi}{2}}^{\pi}20\left|\cos(x)\right|dx =$$

$$20\int_{-\frac{\pi}{2}}^{\frac{\pi}{2}}\cos(x)dx -20\int_{\frac{\pi}{2}}^{\pi}\cos(x)dx$$

see if you can complete it

3. ## Re: Evaluate the Integral

Originally Posted by sic
Evaluate the Integral from -pi/2 to pi of 20 * abs cos(x) dx ? I got the answer -20 but it seems to be incorrect. Can anyone provide an explanation?
$\displaystyle\int_{ - {2^{ - 1}}\pi }^\pi {20\left| {\cos (x)} \right|dx} = \int_{ - {2^{ - 1}}\pi }^{{2^{ - 2}}\pi } {20\cos (x)dx} - \int_{{2^{ - 1}}\pi }^\pi {20 {\cos (x)} dx}$

RECALL that $\cos(x)$ is an even function. So what is that first integral?

4. ## Re: Evaluate the Integral

cos(pi/2) and cos(-pi/2) = 0 so the first integral would be 0? Then for the second integral cos(pi) = -1 and cos (pi/2) = 0 so it would be -20? 0 - (-20) = 20?

5. ## Re: Evaluate the Integral

Originally Posted by sic
cos(pi/2) and cos(-pi/2) = 0 so the first integral would be 0? Then for the second integral cos(pi) = -1 and cos (pi/2) = 0 so it would be -20? 0 - (-20) = 20?
It has nothing to do with that because $\int {\cos (x)dx = \sin (x) + c}$

6. ## Re: Evaluate the Integral

I found out what I did wrong, the derivative of cos(x) = sin(x) and then sin (pi/2) = 1 and sin (-pi/2) = -1 so sin(pi/2) - sin (-pi/2) = 2 and 20*2 = 40 while the next term sin (pi) =0 and sin (pi/2) = 1 so 0-1 = -1 and 20*-1 = -20. After that, by subtracting the two terms, 40- (-20) = 60.

But how do you know where to split the integral?Are there any definitions as to how to split an abs( ) integral?

7. ## Re: Evaluate the Integral

Plato and romsek split the integral at pi/2 since cos(x) crosses the x-axis there. So abs(cos(x)) = cos(x) before that and abs(cos(x)) = -cos(x) after that. That's typical for integrals of functions containing absolute values.

- Hollywood