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

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

[Out]

-x + x^2/2 + Log[1 + x]

_______________________________________________________________________________________

Rubi [A]  time = 0.0154363, antiderivative size = 15, 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{x^2}{2}-x+\log (x+1) \]

Antiderivative was successfully verified.

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

[Out]

-x + x^2/2 + Log[1 + x]

_______________________________________________________________________________________

Rubi in Sympy [F]  time = 0., size = 0, normalized size = 0. \[ - x + \log{\left (x + 1 \right )} + \int x\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

-x + log(x + 1) + Integral(x, x)

_______________________________________________________________________________________

Mathematica [A]  time = 0.00422826, size = 19, normalized size = 1.27 \[ \frac{1}{2} (x+1)^2-2 (x+1)+\log (x+1) \]

Antiderivative was successfully verified.

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

[Out]

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

_______________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Maxima [A]  time = 1.35955, size = 18, normalized size = 1.2 \[ \frac{1}{2} \, x^{2} - x + \log \left (x + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Fricas [A]  time = 0.194772, size = 18, normalized size = 1.2 \[ \frac{1}{2} \, x^{2} - x + \log \left (x + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Sympy [A]  time = 0.055608, size = 10, normalized size = 0.67 \[ \frac{x^{2}}{2} - x + \log{\left (x + 1 \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.208186, size = 19, normalized size = 1.27 \[ \frac{1}{2} \, x^{2} - x +{\rm ln}\left ({\left | x + 1 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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