# Integration by parts

1. Jun 11, 2009

### Shaybay92

1. The problem statement, all variables and given/known data

I have attempted and failed solving the following integration:

Integrate : e^(-x) cos x dx
2. Relevant equations
I tried using the integration by parts rule:

uv - (integral) v (du/dx) dx

3. The attempt at a solution

I let u = e^(-x) and dv/dx = cos x

therefore (du/dx) = -e^(-x) and v = sin x

e^(-x)sinx - (integral)-e^(-x)sinx dx

This does not seem to cancel out anything and just keeps cycling through e and sin/cos

2. Jun 11, 2009

### diazona

Integrate by parts twice, and you will come up with an equation you can solve for the integral you want.

3. Jun 11, 2009

### Cyosis

Alternatively you could write the integral as $\text{Re}(\int e^{-x}e^{i x} dx )$.

4. Jun 11, 2009

### Shaybay92

I just end up with having to integrate exactly what I began with!

After doing parts twice i get

-e-xcosx - $$\int$$ e-x cosx dx

5. Jun 11, 2009

### Cyosis

Where did the first term, e^(-x)sinx, from the first partial integration go? Now define $I=\int e^{-x}\cos x dx$. You will then get an equation I= (some stuff)-I, we want to know I therefore solve for I!