3.194 \(\int \frac{x^2}{(1+x)^3} \, dx\)

Optimal. Leaf size=21 \[ \frac{2}{x+1}-\frac{1}{2 (x+1)^2}+\log (x+1) \]

[Out]

-1/(2*(1 + x)^2) + 2/(1 + x) + Log[1 + x]

_______________________________________________________________________________________

Rubi [A]  time = 0.0186345, antiderivative size = 21, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 9, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.111 \[ \frac{2}{x+1}-\frac{1}{2 (x+1)^2}+\log (x+1) \]

Antiderivative was successfully verified.

[In]  Int[x^2/(1 + x)^3,x]

[Out]

-1/(2*(1 + x)^2) + 2/(1 + x) + Log[1 + x]

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 1.5072, size = 17, normalized size = 0.81 \[ \log{\left (x + 1 \right )} + \frac{2}{x + 1} - \frac{1}{2 \left (x + 1\right )^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(x**2/(1+x)**3,x)

[Out]

log(x + 1) + 2/(x + 1) - 1/(2*(x + 1)**2)

_______________________________________________________________________________________

Mathematica [A]  time = 0.0139596, size = 21, normalized size = 1. \[ \frac{2}{x+1}-\frac{1}{2 (x+1)^2}+\log (x+1) \]

Antiderivative was successfully verified.

[In]  Integrate[x^2/(1 + x)^3,x]

[Out]

-1/(2*(1 + x)^2) + 2/(1 + x) + Log[1 + x]

_______________________________________________________________________________________

Maple [A]  time = 0.007, size = 20, normalized size = 1. \[ -{\frac{1}{2\, \left ( 1+x \right ) ^{2}}}+2\, \left ( 1+x \right ) ^{-1}+\ln \left ( 1+x \right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(x^2/(1+x)^3,x)

[Out]

-1/2/(1+x)^2+2/(1+x)+ln(1+x)

_______________________________________________________________________________________

Maxima [A]  time = 1.36583, size = 30, normalized size = 1.43 \[ \frac{4 \, x + 3}{2 \,{\left (x^{2} + 2 \, x + 1\right )}} + \log \left (x + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x^2/(x + 1)^3,x, algorithm="maxima")

[Out]

1/2*(4*x + 3)/(x^2 + 2*x + 1) + log(x + 1)

_______________________________________________________________________________________

Fricas [A]  time = 0.189447, size = 42, normalized size = 2. \[ \frac{2 \,{\left (x^{2} + 2 \, x + 1\right )} \log \left (x + 1\right ) + 4 \, x + 3}{2 \,{\left (x^{2} + 2 \, x + 1\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x^2/(x + 1)^3,x, algorithm="fricas")

[Out]

1/2*(2*(x^2 + 2*x + 1)*log(x + 1) + 4*x + 3)/(x^2 + 2*x + 1)

_______________________________________________________________________________________

Sympy [A]  time = 0.092839, size = 19, normalized size = 0.9 \[ \frac{4 x + 3}{2 x^{2} + 4 x + 2} + \log{\left (x + 1 \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x**2/(1+x)**3,x)

[Out]

(4*x + 3)/(2*x**2 + 4*x + 2) + log(x + 1)

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.208517, size = 24, normalized size = 1.14 \[ \frac{4 \, x + 3}{2 \,{\left (x + 1\right )}^{2}} +{\rm ln}\left ({\left | x + 1 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x^2/(x + 1)^3,x, algorithm="giac")

[Out]

1/2*(4*x + 3)/(x + 1)^2 + ln(abs(x + 1))