# Problem resolving an Integral

1. Feb 1, 2013

### SclayP

1. So, I have this integral which i'll post in a moment. The thing is that i attempted to resolve the integral by parts and i came up with a solution, but then i looked up in the internet and the way it's resolved it's very very different. I searched it on wolfram and i even have the step by step resolution but i dont know why i can't do it by parts. In Wolfram it's resolved first of all by "simple fractions"??

2.$\int 1/((1+x^2)*(x+1))\,dx$

3. Well, like i said i tried to resolve it by part choosing 1/(x^2+1) dx like dv and 1/(x+1) like u. The i integrated by part and after all the precidure i came up with the next solution; I=arctg(x)/(x+1)

Please i'd be really happy if you could help me with this. AND SORRY FOR MY ENGLISH

Last edited by a moderator: Feb 1, 2013
2. Feb 1, 2013

### jbunniii

Re: Problem resolving a Integral

Have you tried splitting the integrand into partial fractions?

3. Feb 1, 2013

### SclayP

Re: Problem resolving a Integral

Yes, I've tried but i don't come up with nothing that way. I mean, i'm clearly splitting the integrand wrong, but...can't it be resolved by parts. Why ?

Thank you.

4. Feb 1, 2013

### jbunniii

Re: Problem resolving a Integral

Integration by parts doesn't necessarily work for all integrands, even those that are a product of two functions. Over time you learn by experience what is likely to work in what case. Please show what you got when you tried partial fractions:
$$\frac{1}{(x^2 + 1)((x+1)} = \frac{?}{x^2 + 1} + \frac{?}{x + 1}$$

5. Feb 1, 2013

### jbunniii

Re: Problem resolving a Integral

P.S. Are you saying that you used integration by parts and got the right answer? If so, there is nothing wrong with that. Often there is more than one way to solve a problem. If you post your work I will check it for you.

6. Feb 1, 2013

### SclayP

Re: Problem resolving a Integral

This i how it goes:

$\frac{A}{x^2+1} + \frac{B}{x+1} = \frac{1}{(x^2+1)(x+1)}$

Then...

$A(x+1) + B(x^2+1) = 1$

So,

$Ax + A + Bx^2 + B = 1$

So now i do this,

$Ax = 0$
$Bx^2 = 0$
$A + B = 1$

And this is where i dont know how to proceed...

Thanks again.

7. Feb 1, 2013

### Dick

Re: Problem resolving a Integral

Actually it goes $\frac{Ax+B}{x^2+1} + \frac{C}{x+1} = \frac{1}{(x^2+1)(x+1)}$. Try it starting from there.

8. Feb 1, 2013

### SclayP

Re: Problem resolving a Integral

I've tried it that way and i come up with this:

$(Ax+B)(x+1) + C(x^2+1) = 1$

→ $Ax^2 + Ax + Bx + B + Cx^2 + C = 1$
→ $x^2(A +C) + x(A +B) + B + C = 1$

$A + C = 0$
$A + B = 0$
$B + C = 1$

So...

$A = -C$
$A = -B$

Then...

$-C = -B$ → $B = C$

So, the only way is that B = 1/2 and C = 1/2

I guess its ok, but i have a doubt. How did you know it was that way, i mean i would never had though it that way. Why the x multipying the A ? And well would you explain please that ?

Thanks

9. Feb 1, 2013

### Dick

Re: Problem resolving a Integral

You generally need more variables than one if the factor has power greater than one. If you don't have enough variables you won't find any solution to the partial fractions problem - as you noticed. If the factor is quadratic, like x^2+1 you need a linear function having two variables (A,B) in the numerator, like Ax+B. The same sort of thing happens if you have powers of polynomials, like (x+1)^2. See http://tutorial.math.lamar.edu/Classes/CalcII/PartialFractions.aspx

10. Feb 1, 2013

### Staff: Mentor

Re: Problem resolving a Integral

Just to expand on what Dick said
If the factor is an irreducible quadratic, like x^2+1, then ...

If the quadratic is factorable, then you factor it and write expressions such as A/(x - r) + B/(x - s).

11. Feb 1, 2013

### Dick

Re: Problem resolving a Integral

You CAN do the partial fractions formalism on reducible polynomials. E.g. (3x^2+12x+11)/((x^2+3x+2)(x+3)) can be split into (2x+3)/(x^2+3x+2)+1/(x+3). But, of course, you would be a lot better off if you recognize (x^2+3x+2)=(x+1)(x+2) and split it into 1/(x+1)+1/(x+2)+1/(x+3). It's just a lot simpler.