# Maths - integration

1. May 14, 2004

### denian

integrate
$$\int\frac{\sin^2 x}{e^x} = \int\frac{1}{2e^x} - \frac{\cos2x}{2e^x} dx = - \frac{1}{2}e^{-x} - \frac{1}{2}\int\frac{\cos 2x}{e^x} dx$$
im trying to use the integration by parts method, but seems like im stuck there, doesnt reach the answer :-

$$-\frac{e^{-x}}{2} + \frac{e^{-x}}{10} ( cos 2x - 2 sin 2x ) + c$$

Last edited: May 14, 2004
2. May 14, 2004

### Dr Transport

write $$\cos(2x) = \frac{e^{2ix}+e^{-2ix}}{2}$$ then integrate......is should work out.

3. May 14, 2004

### denian

i never come across that formula. can u explain?

4. May 14, 2004

### denian

ok..... i already know how to prove it. but may i know how u come across that formula?

5. May 14, 2004

### Dr Transport

it is the expansion of the trigonometric functions in terms of complex exponentials......

6. May 14, 2004

It's known as the Euler Formula.
http://mathworld.wolfram.com/EulerFormula.html

$$e^{i\theta} = \cos{\theta} + i\sin{\theta}$$

And, using the even/oddness of cos/sin,

$$e^{-i\theta} = \cos{\theta} - i\sin{\theta}$$

Which can then be combined to solve for either the sine or cosine.

Last edited: May 14, 2004
7. May 14, 2004

I wouldn't expect that he'd be required to know anything about complex numbers for this...

8. May 15, 2004

### denian

yeah, it doesnt. anyways thanks for the suggestion.

Last edited: May 15, 2004
9. May 15, 2004

### denian

bump bmp bump

Last edited: May 15, 2004
10. May 17, 2004

### Shahil

Just outta interest, how do u integrate that? do you just integrate as per real numbers or are their any special complex techniques?

11. May 17, 2004

### Dr Transport

just integrate with respect to $$x$$, the complex number $$i$$ is a constant.....

12. May 17, 2004

### TMcCloskey

Repeated application of integration-by-parts is the suggested route. Denian set up the problem correctly, now just needs to proceed carefully:

Let the last integral represent $I_1$, ie,

$$I_1 = \frac{1}{2}\int\frac{\cos 2x}{e^x} dx$$

and select

$$u = \cos 2x$$

$$dv = e^{-x} dx$$

Then

$$2I_1 = \int u dv = uv - \int v du$$

$$2I_1 = -e^{-x} \cos 2x - 2 \int e^{-x} sin 2x dx$$

Now repeat this process with the last integral in expression for I1, ie, let

$$I_2 = \int e^{-x} sin 2x dx$$

Calculate via integration-by-parts and the resulting expression for $I_2$ should yield a trailing integral which you'll reconize as a multiple of $I_1$. Substitute "$I_1$" for this integral and collect terms to solve for "$I_1$". Substitute this into the original expression and your done.

13. May 17, 2004

### NateTG

$$\int\frac{\sin(x)^2}{e^x} dx =$$
$$\int e^{-x} \sin(x)^2 dx$$
Now
$$u=-x$$
$$du=-dx$$
and
$$(\sin(x))^2=(-\sin(-x)^2=(\sin(-x))^2$$
so
$$-\int e^u \sin(u)^2 du =$$
$$-(e^u \sin(u)^2 - \int e^{u} 2 \sin(u) \cos(u) du)=$$
$$-(e^u \sin(u)^2 - \int e^{u} 2 \sin(2u) du)=$$
$$-(e^u \sin(u)^2 + e^{u} \cos(2u) + \int e^{u} \cos(2u))=$$
$$-(e^u \sin(u)^2 + e^{u}(\cos^2(u) - \sin^2(u)) + \int e^{u} \cos(2u) du)=$$
$$-e^u \cos^2(u) - \int e^{u} \cos^2(u)du + \int e^{u} \sin^2(u) du =$$
$$-e^u \cos^2(u) - \int e^{u} du + 2 \int e^{u} \sin^2(u) du=$$
so we have
$$\int e^{u} \sin^2{u} du = e^u \cos^2(u) + \int e^{u} du - 2 \int e^{u} \sin^2{u} du$$
so
$$\int e^{u} \sin^2{u} du = \frac{e^u \cos^2(u) + e^u)}{3}$$
so
$$\int\frac{\sin(x)^2}{e^x} dx = -\int e^u \sin(u)^2 du = -\frac{e^u \cos^2(u) + e^u}{3} + C$$
$$\int\frac{\sin(x)^2}{e^x} dx = - \frac{\cos^2(x)+1}{3e^x} + C$$

Of course, you should check my work etc.

14. May 18, 2004

### Shahil

Why does my brain just decide to switch of sometimes...

Stupid, stupid, stupid! Of course i is a constant!