Optimal. Leaf size=79 \[ -\frac{3}{4} \log \left (\sqrt [3]{(x-1) \left (q+x^2-2 x\right )}-x+1\right )+\frac{1}{2} \sqrt{3} \tan ^{-1}\left (\frac{2 (x-1)}{\sqrt{3} \sqrt [3]{(x-1) \left (q+x^2-2 x\right )}}+\frac{1}{\sqrt{3}}\right )+\frac{1}{4} \log (1-x) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0978022, antiderivative size = 145, normalized size of antiderivative = 1.84, number of steps used = 5, number of rules used = 5, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.312, Rules used = {2067, 2011, 329, 275, 239} \[ \frac{\sqrt{3} \sqrt [3]{x-1} \sqrt [3]{q+(x-1)^2-1} \tan ^{-1}\left (\frac{\frac{2 (x-1)^{2/3}}{\sqrt [3]{q+(x-1)^2-1}}+1}{\sqrt{3}}\right )}{2 \sqrt [3]{(x-1)^3-(1-q) (x-1)}}-\frac{3 \sqrt [3]{x-1} \sqrt [3]{q+(x-1)^2-1} \log \left ((x-1)^{2/3}-\sqrt [3]{q+(x-1)^2-1}\right )}{4 \sqrt [3]{(x-1)^3-(1-q) (x-1)}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2067
Rule 2011
Rule 329
Rule 275
Rule 239
Rubi steps
\begin{align*} \int \frac{1}{\sqrt [3]{(-1+x) \left (q-2 x+x^2\right )}} \, dx &=\operatorname{Subst}\left (\int \frac{1}{\sqrt [3]{-(1-q) x+x^3}} \, dx,x,-1+x\right )\\ &=\frac{\left (\sqrt [3]{-1+q+(-1+x)^2} \sqrt [3]{-1+x}\right ) \operatorname{Subst}\left (\int \frac{1}{\sqrt [3]{x} \sqrt [3]{-1+q+x^2}} \, dx,x,-1+x\right )}{\sqrt [3]{(-1+q) (-1+x)+(-1+x)^3}}\\ &=\frac{\left (3 \sqrt [3]{-1+q+(-1+x)^2} \sqrt [3]{-1+x}\right ) \operatorname{Subst}\left (\int \frac{x}{\sqrt [3]{-1+q+x^6}} \, dx,x,\sqrt [3]{-1+x}\right )}{\sqrt [3]{(-1+q) (-1+x)+(-1+x)^3}}\\ &=\frac{\left (3 \sqrt [3]{-1+q+(-1+x)^2} \sqrt [3]{-1+x}\right ) \operatorname{Subst}\left (\int \frac{1}{\sqrt [3]{-1+q+x^3}} \, dx,x,(-1+x)^{2/3}\right )}{2 \sqrt [3]{(-1+q) (-1+x)+(-1+x)^3}}\\ &=\frac{\sqrt{3} \sqrt [3]{-1+q+(-1+x)^2} \sqrt [3]{-1+x} \tan ^{-1}\left (\frac{1+\frac{2 (-1+x)^{2/3}}{\sqrt [3]{q-(2-x) x}}}{\sqrt{3}}\right )}{2 \sqrt [3]{(1-q) (1-x)+(-1+x)^3}}-\frac{3 \sqrt [3]{-1+q+(-1+x)^2} \sqrt [3]{-1+x} \log \left ((-1+x)^{2/3}-\sqrt [3]{q-(2-x) x}\right )}{4 \sqrt [3]{(1-q) (1-x)+(-1+x)^3}}\\ \end{align*}
Mathematica [A] time = 0.166759, size = 140, normalized size = 1.77 \[ \frac{\sqrt [3]{x-1} \sqrt [3]{q+(x-2) x} \left (-2 \log \left (1-\frac{(x-1)^{2/3}}{\sqrt [3]{q+(x-2) x}}\right )+\log \left (\frac{(x-1)^{4/3}}{(q+(x-2) x)^{2/3}}+\frac{(x-1)^{2/3}}{\sqrt [3]{q+(x-2) x}}+1\right )+2 \sqrt{3} \tan ^{-1}\left (\frac{\frac{2 (x-1)^{2/3}}{\sqrt [3]{q+(x-2) x}}+1}{\sqrt{3}}\right )\right )}{4 \sqrt [3]{(x-1) (q+(x-2) x)}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F] time = 0.012, size = 0, normalized size = 0. \begin{align*} \int{\frac{1}{\sqrt [3]{ \left ( -1+x \right ) \left ({x}^{2}+q-2\,x \right ) }}}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{1}{\left ({\left (x^{2} + q - 2 \, x\right )}{\left (x - 1\right )}\right )^{\frac{1}{3}}}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 12.361, size = 1866, normalized size = 23.62 \begin{align*} \text{result too large to display} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{1}{\left ({\left (x^{2} + q - 2 \, x\right )}{\left (x - 1\right )}\right )^{\frac{1}{3}}}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]