# Integration by parts I(n-2)

1. Aug 21, 2007

### t_n_p

The problem statement, all variables and given/known data

Hi, I'm trying to solve

in terms of I(n-2) but I'm not exactly sure where to start/what to do :uhh:

2. Aug 21, 2007

### HallsofIvy

Staff Emeritus
You titled this "integration" by parts. Doesn't that give you a hint where to start?

Since it is much easier to differentiate a power of a function than to integrate, the choice of u= sinn(x) and dv= sin(x) seems simplest.

Since the problem says "in terms of I(n-2)" I suspect you will need to do it twice.

3. Aug 21, 2007

### Gib Z

Dido what Halls said, with tiny corrections:

$$u= \sin^{n-1} x, dv = \sin x dx$$ is what he might have meant.

4. Aug 21, 2007

### genneth

Bad mentor! Giving wrong hints, tut tut...

Hints: only perform by parts once; getting $$I(n)$$ again on the right hand side is no bad thing; remember that for trig problems you'll usually need to use trig identities at some point.

5. Aug 21, 2007

### HallsofIvy

Staff Emeritus
I was thinking right- my fingers hit the wrong keys!

(and it is "ditto", not "dido"!)

Last edited: Aug 21, 2007
6. Aug 21, 2007

### t_n_p

How would I diff u?

7. Aug 21, 2007

### Gib Z

Use the chain rule?

8. Aug 21, 2007

### t_n_p

Let u = (n-1) hence y=[sin(x)]^(u)
then du/dn = 1

but again, unsure how to get dy/du now..

9. Aug 21, 2007

### Gib Z

Instead, try letting u = sin x when differentiating :)

10. Aug 21, 2007

### genneth

$$\frac{d}{dx}\left(\sin^{n-1}(x)\right) = \left((n-2)\sin^{n-2}(x)\right) \left(\cos(x)\right)$$

Btw, you can't really do integration without being able to do differentiation like the back of your hand -- more practise at that would be helpful.

Last edited: Aug 21, 2007
11. Aug 21, 2007

### t_n_p

I made a mistake before when doing chain rule. To prevent confusion, I will initially let f(x)=[sin(x)]^(n-1) and g'(x)=sinx

Then I use chain rule,
now I let u = sinx, hence f(x) = u^(n-1)

dy/du=(n-1)(u^(n-2))
and du/dx = cos(x)

hence dy/dx= (n-1)(sinx^(n-2))(cosx)?

12. Aug 21, 2007

### t_n_p

Can you please explain how you got that/what steps did I do wrong above?

13. Aug 21, 2007

### genneth

You got it right -- I got it wrong -- looks like I need more practice...

14. Aug 21, 2007

### Gib Z

*in imitation of Mr. Burns on the Simpsons* Excellent..

15. Aug 21, 2007

### t_n_p

coolio!
I sub all the relevant values into the "magical integration by parts formula", but the second part seems awfully tedious..

Can (n-1) be taken out as a constant, leaving just the sin and cos terms for me to integrate by parts again?

16. Aug 21, 2007

### Gib Z

Yes it can, but also it wants you to express cos^2 x as 1-sin^2 x, get the original integral "I" on both sides :)

17. Aug 21, 2007

### t_n_p

ah ok!
After converting (cosx)^2 using the trig identity I get..

Where to from there?

18. Aug 21, 2007

### learningphysics

careful. you can't separate it like that:

$$\int{f(x)*g(x)dx}\ne\int{f(x)dx}*\int{g(x)dx}$$

keep the $$sin^{n-2}x$$ inside the integral, and multiply it out by $$-1+sin^2x$$

19. Aug 21, 2007

### t_n_p

ah ok, you mean expand to give..

but then what?

20. Aug 21, 2007

### learningphysics

Remember... your right side right now just has $$\int{vdu}$$... but it's supposed to be $$uv - \int{vdu}$$

To continue... remember that sums within integrals can be separated out into separate integrals (unlike products)... once that's done, you can substitute your I(n-2)... and use algebra to solve for $$\int{sin^n(x)dx}$$