How do you evaluate the integral int e^-xcosx?
1 Answer
int \ e^(-x) \cosx \ dx = 1/2(e^(-x)sinx - e^(-x)cosx) + C
Explanation:
Let:
I = int \ e^(-x) \cosx \ dx
We can use integration by parts:
Let
{ (u,=cosx, => (du)/dx,=-sinx), ((dv)/dx,=e^(-x), => v,=-e^x ) :}
Then plugging into the IBP formula:
int \ (u)((dv)/dx) \ dx = (u)(v) - int \ (v)((du)/dx) \ dx
gives us
int \ (cosx)(e^(-x)) \ dx = (cosx)(-e^(-x)) - int \ (-e^(-x))(-sinx) \ dx
:. I = -e^(-x)cosx - int \ e^(-x) \ sinx \ dx .... [A]
At first it appears as if we have made no progress, as now the second integral is similar to
Let
{ (u,=sinx, => (du)/dx,=cosx), ((dv)/dx,=e^(-x), => v,=-e^(-x) ) :}
Then plugging into the IBP formula, gives us:
int \ (sinx)(e^(-x)) \ dx = (sinx)(-e^(-x)) - int \ (-e^(-x))(cosx) \ dx
:. int \ e^(-x) \ sinx \ dx = -e^(-x)sinx + I
Inserting this result into [A] we get:
I = -e^(-x)cosx + e^(-x)sinx - I + A
:. 2I = e^(-x)sinx - e^(-x)cosx + A
:. \ \ I = 1/2(e^(-x)sinx - e^(-x)cosx) + C