# How do you integrate int e^xcos(2x) by parts?

Jan 14, 2017

$\int {e}^{x} \cos \left(2 x\right) \mathrm{dx} = \frac{1}{5} \left({e}^{x} \cos 2 x + 2 {e}^{x} \sin 2 x\right) + C$

#### Explanation:

As $d \left({e}^{x}\right) = {e}^{x} \mathrm{dx}$ we can integrate by parts as:

$\int {e}^{x} \cos \left(2 x\right) \mathrm{dx} = \int \cos \left(2 x\right) d \left({e}^{x}\right) = {e}^{x} \cos 2 x + 2 \int {e}^{x} \sin \left(2 x\right) \mathrm{dx}$

We integrate the resulting integral by parts again:

$\int {e}^{x} \sin \left(2 x\right) \mathrm{dx} = \int \sin \left(2 x\right) d \left({e}^{x}\right) = {e}^{x} \sin 2 x - 2 \int {e}^{x} \cos \left(2 x\right) \mathrm{dx}$

So if we name:

$I = \int {e}^{x} \cos \left(2 x\right) \mathrm{dx}$

we get the following equation:

$I = {e}^{x} \cos 2 x + 2 {e}^{x} \sin 2 x - 4 I$

and solving for $I$:

$I = \frac{1}{5} \left({e}^{x} \cos 2 x + 2 {e}^{x} \sin 2 x\right)$

so that:

$\int {e}^{x} \cos \left(2 x\right) \mathrm{dx} = \frac{1}{5} \left({e}^{x} \cos 2 x + 2 {e}^{x} \sin 2 x\right) + C$