3.3.28 \(\int \frac {x^2}{\sqrt {-1+x}} \, dx\) [228]

Optimal. Leaf size=32 \[ 2 \sqrt {-1+x}+\frac {4}{3} (-1+x)^{3/2}+\frac {2}{5} (-1+x)^{5/2} \]

[Out]

4/3*(-1+x)^(3/2)+2/5*(-1+x)^(5/2)+2*(-1+x)^(1/2)

________________________________________________________________________________________

Rubi [A]
time = 0.00, antiderivative size = 32, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 1, integrand size = 11, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {45} \begin {gather*} \frac {2}{5} (x-1)^{5/2}+\frac {4}{3} (x-1)^{3/2}+2 \sqrt {x-1} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[x^2/Sqrt[-1 + x],x]

[Out]

2*Sqrt[-1 + x] + (4*(-1 + x)^(3/2))/3 + (2*(-1 + x)^(5/2))/5

Rule 45

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin {align*} \int \frac {x^2}{\sqrt {-1+x}} \, dx &=\int \left (\frac {1}{\sqrt {-1+x}}+2 \sqrt {-1+x}+(-1+x)^{3/2}\right ) \, dx\\ &=2 \sqrt {-1+x}+\frac {4}{3} (-1+x)^{3/2}+\frac {2}{5} (-1+x)^{5/2}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 21, normalized size = 0.66 \begin {gather*} \frac {2}{15} \sqrt {-1+x} \left (8+4 x+3 x^2\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[x^2/Sqrt[-1 + x],x]

[Out]

(2*Sqrt[-1 + x]*(8 + 4*x + 3*x^2))/15

________________________________________________________________________________________

Mathics [C] Result contains higher order function than in optimal. Order 9 vs. order 2 in optimal.
time = 2.33, size = 56, normalized size = 1.75 \begin {gather*} \text {Piecewise}\left [\left \{\left \{\frac {2 \left (8+4 x+3 x^2\right ) \sqrt {-1+x}}{15},\text {Abs}\left [x\right ]>1\right \}\right \},\frac {I 8 x \sqrt {1-x}}{15}+\frac {I 2 x^2 \sqrt {1-x}}{5}+\frac {I 16 \sqrt {1-x}}{15}\right ] \end {gather*}

Warning: Unable to verify antiderivative.

[In]

mathics('Integrate[x^2/Sqrt[-1 + x],x]')

[Out]

Piecewise[{{2 (8 + 4 x + 3 x ^ 2) Sqrt[-1 + x] / 15, Abs[x] > 1}}, I 8 x Sqrt[1 - x] / 15 + I 2 x ^ 2 Sqrt[1 -
 x] / 5 + I 16 Sqrt[1 - x] / 15]

________________________________________________________________________________________

Maple [A]
time = 0.05, size = 23, normalized size = 0.72

method result size
trager \(\left (\frac {2}{5} x^{2}+\frac {8}{15} x +\frac {16}{15}\right ) \sqrt {-1+x}\) \(17\)
gosper \(\frac {2 \sqrt {-1+x}\, \left (3 x^{2}+4 x +8\right )}{15}\) \(18\)
risch \(\frac {2 \sqrt {-1+x}\, \left (3 x^{2}+4 x +8\right )}{15}\) \(18\)
derivativedivides \(\frac {4 \left (-1+x \right )^{\frac {3}{2}}}{3}+\frac {2 \left (-1+x \right )^{\frac {5}{2}}}{5}+2 \sqrt {-1+x}\) \(23\)
default \(\frac {4 \left (-1+x \right )^{\frac {3}{2}}}{3}+\frac {2 \left (-1+x \right )^{\frac {5}{2}}}{5}+2 \sqrt {-1+x}\) \(23\)
meijerg \(-\frac {\sqrt {-\mathrm {signum}\left (-1+x \right )}\, \left (-\frac {16 \sqrt {\pi }}{15}+\frac {\sqrt {\pi }\, \left (6 x^{2}+8 x +16\right ) \sqrt {1-x}}{15}\right )}{\sqrt {\pi }\, \sqrt {\mathrm {signum}\left (-1+x \right )}}\) \(48\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2/(-1+x)^(1/2),x,method=_RETURNVERBOSE)

[Out]

4/3*(-1+x)^(3/2)+2/5*(-1+x)^(5/2)+2*(-1+x)^(1/2)

________________________________________________________________________________________

Maxima [A]
time = 0.28, size = 22, normalized size = 0.69 \begin {gather*} \frac {2}{5} \, {\left (x - 1\right )}^{\frac {5}{2}} + \frac {4}{3} \, {\left (x - 1\right )}^{\frac {3}{2}} + 2 \, \sqrt {x - 1} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2/(-1+x)^(1/2),x, algorithm="maxima")

[Out]

2/5*(x - 1)^(5/2) + 4/3*(x - 1)^(3/2) + 2*sqrt(x - 1)

________________________________________________________________________________________

Fricas [A]
time = 0.34, size = 17, normalized size = 0.53 \begin {gather*} \frac {2}{15} \, {\left (3 \, x^{2} + 4 \, x + 8\right )} \sqrt {x - 1} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2/(-1+x)^(1/2),x, algorithm="fricas")

[Out]

2/15*(3*x^2 + 4*x + 8)*sqrt(x - 1)

________________________________________________________________________________________

Sympy [A]
time = 0.61, size = 76, normalized size = 2.38 \begin {gather*} \begin {cases} \frac {2 x^{2} \sqrt {x - 1}}{5} + \frac {8 x \sqrt {x - 1}}{15} + \frac {16 \sqrt {x - 1}}{15} & \text {for}\: \left |{x}\right | > 1 \\\frac {2 i x^{2} \sqrt {1 - x}}{5} + \frac {8 i x \sqrt {1 - x}}{15} + \frac {16 i \sqrt {1 - x}}{15} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**2/(-1+x)**(1/2),x)

[Out]

Piecewise((2*x**2*sqrt(x - 1)/5 + 8*x*sqrt(x - 1)/15 + 16*sqrt(x - 1)/15, Abs(x) > 1), (2*I*x**2*sqrt(1 - x)/5
 + 8*I*x*sqrt(1 - x)/15 + 16*I*sqrt(1 - x)/15, True))

________________________________________________________________________________________

Giac [A]
time = 0.00, size = 39, normalized size = 1.22 \begin {gather*} 2 \left (\frac {1}{5} \sqrt {x-1} \left (x-1\right )^{2}+\frac {2}{3} \sqrt {x-1} \left (x-1\right )+\sqrt {x-1}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2/(-1+x)^(1/2),x)

[Out]

2/5*(x - 1)^(5/2) + 4/3*(x - 1)^(3/2) + 2*sqrt(x - 1)

________________________________________________________________________________________

Mupad [B]
time = 0.03, size = 19, normalized size = 0.59 \begin {gather*} \frac {2\,\sqrt {x-1}\,\left (10\,x+3\,{\left (x-1\right )}^2+5\right )}{15} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2/(x - 1)^(1/2),x)

[Out]

(2*(x - 1)^(1/2)*(10*x + 3*(x - 1)^2 + 5))/15

________________________________________________________________________________________