3.30.69 \(\int \frac {(-2+x) (1-x+x^2)}{x^3 (-1+x+x^2) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx\) [2969]

3.30.69.1 Optimal result
3.30.69.2 Mathematica [A] (verified)
3.30.69.3 Rubi [F]
3.30.69.4 Maple [F]
3.30.69.5 Fricas [B] (verification not implemented)
3.30.69.6 Sympy [F(-1)]
3.30.69.7 Maxima [F]
3.30.69.8 Giac [F]
3.30.69.9 Mupad [F(-1)]

3.30.69.1 Optimal result

Integrand size = 50, antiderivative size = 370 \[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=\frac {\left (-1+x-3 x^2\right ) \left (\frac {1-x+2 x^2}{1-x+3 x^2}\right )^{2/3}}{x^2}-2\ 2^{2/3} \sqrt [6]{3} \arctan \left (\frac {1}{\sqrt {3}}+\frac {2\ 2^{2/3} \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}}{3^{5/6}}\right )+\frac {7 \arctan \left (\frac {1}{\sqrt {3}}+\frac {2 \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}}{\sqrt {3}}\right )}{\sqrt {3}}+\frac {7}{3} \log \left (-1+\sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}\right )-\frac {2\ 2^{2/3} \log \left (-3+6^{2/3} \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}\right )}{\sqrt [3]{3}}-\frac {7}{6} \log \left (1+\sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}+\left (\frac {1-x+2 x^2}{1-x+3 x^2}\right )^{2/3}\right )+\frac {2^{2/3} \log \left (3+6^{2/3} \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}+2 \sqrt [3]{6} \left (\frac {1-x+2 x^2}{1-x+3 x^2}\right )^{2/3}\right )}{\sqrt [3]{3}} \]

output
(-3*x^2+x-1)*((2*x^2-x+1)/(3*x^2-x+1))^(2/3)/x^2-2*2^(2/3)*3^(1/6)*arctan( 
1/3*3^(1/2)+2/3*2^(2/3)*((2*x^2-x+1)/(3*x^2-x+1))^(1/3)*3^(1/6))+7/3*arcta 
n(1/3*3^(1/2)+2/3*((2*x^2-x+1)/(3*x^2-x+1))^(1/3)*3^(1/2))*3^(1/2)+7/3*ln( 
-1+((2*x^2-x+1)/(3*x^2-x+1))^(1/3))-2/3*2^(2/3)*ln(-3+6^(2/3)*((2*x^2-x+1) 
/(3*x^2-x+1))^(1/3))*3^(2/3)-7/6*ln(1+((2*x^2-x+1)/(3*x^2-x+1))^(1/3)+((2* 
x^2-x+1)/(3*x^2-x+1))^(2/3))+1/3*2^(2/3)*ln(3+6^(2/3)*((2*x^2-x+1)/(3*x^2- 
x+1))^(1/3)+2*6^(1/3)*((2*x^2-x+1)/(3*x^2-x+1))^(2/3))*3^(2/3)
 
3.30.69.2 Mathematica [A] (verified)

Time = 3.59 (sec) , antiderivative size = 504, normalized size of antiderivative = 1.36 \[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=-\frac {6 \sqrt [3]{1-x+3 x^2}-6 x \sqrt [3]{1-x+3 x^2}+12 x^2 \sqrt [3]{1-x+3 x^2}+14 \sqrt {3} x^2 \sqrt [3]{1-x+2 x^2} \arctan \left (\frac {1+\frac {2 \sqrt [3]{1-x+3 x^2}}{\sqrt [3]{1-x+2 x^2}}}{\sqrt {3}}\right )-12\ 2^{2/3} \sqrt [6]{3} x^2 \sqrt [3]{1-x+2 x^2} \arctan \left (\frac {1+\frac {\sqrt [3]{6-6 x+18 x^2}}{\sqrt [3]{1-x+2 x^2}}}{\sqrt {3}}\right )-14 x^2 \sqrt [3]{1-x+2 x^2} \log \left (-1+\frac {\sqrt [3]{1-x+3 x^2}}{\sqrt [3]{1-x+2 x^2}}\right )+7 x^2 \sqrt [3]{1-x+2 x^2} \log \left (1+\frac {\sqrt [3]{1-x+3 x^2}}{\sqrt [3]{1-x+2 x^2}}+\frac {\left (1-x+3 x^2\right )^{2/3}}{\left (1-x+2 x^2\right )^{2/3}}\right )+4\ 6^{2/3} x^2 \sqrt [3]{1-x+2 x^2} \log \left (-2+\frac {\sqrt [3]{6-6 x+18 x^2}}{\sqrt [3]{1-x+2 x^2}}\right )-2\ 6^{2/3} x^2 \sqrt [3]{1-x+2 x^2} \log \left (4+\frac {2 \sqrt [3]{6-6 x+18 x^2}}{\sqrt [3]{1-x+2 x^2}}+\frac {\left (6-6 x+18 x^2\right )^{2/3}}{\left (1-x+2 x^2\right )^{2/3}}\right )}{6 x^2 \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}} \sqrt [3]{1-x+3 x^2}} \]

input
Integrate[((-2 + x)*(1 - x + x^2))/(x^3*(-1 + x + x^2)*((1 - x + 2*x^2)/(1 
 - x + 3*x^2))^(1/3)),x]
 
output
-1/6*(6*(1 - x + 3*x^2)^(1/3) - 6*x*(1 - x + 3*x^2)^(1/3) + 12*x^2*(1 - x 
+ 3*x^2)^(1/3) + 14*Sqrt[3]*x^2*(1 - x + 2*x^2)^(1/3)*ArcTan[(1 + (2*(1 - 
x + 3*x^2)^(1/3))/(1 - x + 2*x^2)^(1/3))/Sqrt[3]] - 12*2^(2/3)*3^(1/6)*x^2 
*(1 - x + 2*x^2)^(1/3)*ArcTan[(1 + (6 - 6*x + 18*x^2)^(1/3)/(1 - x + 2*x^2 
)^(1/3))/Sqrt[3]] - 14*x^2*(1 - x + 2*x^2)^(1/3)*Log[-1 + (1 - x + 3*x^2)^ 
(1/3)/(1 - x + 2*x^2)^(1/3)] + 7*x^2*(1 - x + 2*x^2)^(1/3)*Log[1 + (1 - x 
+ 3*x^2)^(1/3)/(1 - x + 2*x^2)^(1/3) + (1 - x + 3*x^2)^(2/3)/(1 - x + 2*x^ 
2)^(2/3)] + 4*6^(2/3)*x^2*(1 - x + 2*x^2)^(1/3)*Log[-2 + (6 - 6*x + 18*x^2 
)^(1/3)/(1 - x + 2*x^2)^(1/3)] - 2*6^(2/3)*x^2*(1 - x + 2*x^2)^(1/3)*Log[4 
 + (2*(6 - 6*x + 18*x^2)^(1/3))/(1 - x + 2*x^2)^(1/3) + (6 - 6*x + 18*x^2) 
^(2/3)/(1 - x + 2*x^2)^(2/3)])/(x^2*((1 - x + 2*x^2)/(1 - x + 3*x^2))^(1/3 
)*(1 - x + 3*x^2)^(1/3))
 
3.30.69.3 Rubi [F]

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {(x-2) \left (x^2-x+1\right )}{x^3 \left (x^2+x-1\right ) \sqrt [3]{\frac {2 x^2-x+1}{3 x^2-x+1}}} \, dx\)

\(\Big \downarrow \) 7270

\(\displaystyle \frac {\sqrt [3]{2 x^2-x+1} \int \frac {(2-x) \left (x^2-x+1\right ) \sqrt [3]{3 x^2-x+1}}{x^3 \left (-x^2-x+1\right ) \sqrt [3]{2 x^2-x+1}}dx}{\sqrt [3]{\frac {2 x^2-x+1}{3 x^2-x+1}} \sqrt [3]{3 x^2-x+1}}\)

\(\Big \downarrow \) 7279

\(\displaystyle \frac {\sqrt [3]{2 x^2-x+1} \int \left (-\frac {2 \sqrt [3]{3 x^2-x+1} (2 x+1)}{\left (x^2+x-1\right ) \sqrt [3]{2 x^2-x+1}}+\frac {4 \sqrt [3]{3 x^2-x+1}}{x \sqrt [3]{2 x^2-x+1}}-\frac {\sqrt [3]{3 x^2-x+1}}{x^2 \sqrt [3]{2 x^2-x+1}}+\frac {2 \sqrt [3]{3 x^2-x+1}}{x^3 \sqrt [3]{2 x^2-x+1}}\right )dx}{\sqrt [3]{\frac {2 x^2-x+1}{3 x^2-x+1}} \sqrt [3]{3 x^2-x+1}}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {\sqrt [3]{2 x^2-x+1} \left (-\int \frac {\sqrt [3]{3 x^2-x+1}}{x^2 \sqrt [3]{2 x^2-x+1}}dx+4 \int \frac {\sqrt [3]{3 x^2-x+1}}{x \sqrt [3]{2 x^2-x+1}}dx-4 \int \frac {\sqrt [3]{3 x^2-x+1}}{\left (2 x-\sqrt {5}+1\right ) \sqrt [3]{2 x^2-x+1}}dx-4 \int \frac {\sqrt [3]{3 x^2-x+1}}{\left (2 x+\sqrt {5}+1\right ) \sqrt [3]{2 x^2-x+1}}dx+2 \int \frac {\sqrt [3]{3 x^2-x+1}}{x^3 \sqrt [3]{2 x^2-x+1}}dx\right )}{\sqrt [3]{\frac {2 x^2-x+1}{3 x^2-x+1}} \sqrt [3]{3 x^2-x+1}}\)

input
Int[((-2 + x)*(1 - x + x^2))/(x^3*(-1 + x + x^2)*((1 - x + 2*x^2)/(1 - x + 
 3*x^2))^(1/3)),x]
 
output
$Aborted
 

3.30.69.3.1 Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 7270
Int[(u_.)*((a_.)*(v_)^(m_.)*(w_)^(n_.))^(p_), x_Symbol] :> Simp[a^IntPart[p 
]*((a*v^m*w^n)^FracPart[p]/(v^(m*FracPart[p])*w^(n*FracPart[p])))   Int[u*v 
^(m*p)*w^(n*p), x], x] /; FreeQ[{a, m, n, p}, x] &&  !IntegerQ[p] &&  !Free 
Q[v, x] &&  !FreeQ[w, x]
 

rule 7279
Int[(u_)/((a_.) + (b_.)*(x_)^(n_.) + (c_.)*(x_)^(n2_.)), x_Symbol] :> With[ 
{v = RationalFunctionExpand[u/(a + b*x^n + c*x^(2*n)), x]}, Int[v, x] /; Su 
mQ[v]] /; FreeQ[{a, b, c}, x] && EqQ[n2, 2*n] && IGtQ[n, 0]
 
3.30.69.4 Maple [F]

\[\int \frac {\left (-2+x \right ) \left (x^{2}-x +1\right )}{x^{3} \left (x^{2}+x -1\right ) \left (\frac {2 x^{2}-x +1}{3 x^{2}-x +1}\right )^{\frac {1}{3}}}d x\]

input
int((-2+x)*(x^2-x+1)/x^3/(x^2+x-1)/((2*x^2-x+1)/(3*x^2-x+1))^(1/3),x)
 
output
int((-2+x)*(x^2-x+1)/x^3/(x^2+x-1)/((2*x^2-x+1)/(3*x^2-x+1))^(1/3),x)
 
3.30.69.5 Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 735 vs. \(2 (326) = 652\).

Time = 10.48 (sec) , antiderivative size = 735, normalized size of antiderivative = 1.99 \[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=-\frac {2 \cdot 3^{\frac {2}{3}} \left (-4\right )^{\frac {1}{3}} x^{2} \log \left (-\frac {24 \cdot 3^{\frac {2}{3}} \left (-4\right )^{\frac {1}{3}} {\left (39 \, x^{4} - 28 \, x^{3} + 33 \, x^{2} - 10 \, x + 5\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {2}{3}} - 3^{\frac {1}{3}} \left (-4\right )^{\frac {2}{3}} {\left (649 \, x^{4} - 538 \, x^{3} + 647 \, x^{2} - 218 \, x + 109\right )} - 36 \, {\left (75 \, x^{4} - 58 \, x^{3} + 69 \, x^{2} - 22 \, x + 11\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}}}{x^{4} + 2 \, x^{3} - x^{2} - 2 \, x + 1}\right ) - 4 \cdot 3^{\frac {2}{3}} \left (-4\right )^{\frac {1}{3}} x^{2} \log \left (-\frac {9 \cdot 3^{\frac {1}{3}} \left (-4\right )^{\frac {2}{3}} {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}} + 3^{\frac {2}{3}} \left (-4\right )^{\frac {1}{3}} {\left (x^{2} + x - 1\right )} - 36 \, {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {2}{3}}}{x^{2} + x - 1}\right ) + 12 \cdot 3^{\frac {1}{6}} \left (-4\right )^{\frac {1}{3}} x^{2} \arctan \left (\frac {3^{\frac {1}{6}} {\left (12 \cdot 3^{\frac {2}{3}} \left (-4\right )^{\frac {2}{3}} {\left (39 \, x^{6} + 11 \, x^{5} - 34 \, x^{4} + 51 \, x^{3} - 38 \, x^{2} + 15 \, x - 5\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {2}{3}} + 18 \, \left (-4\right )^{\frac {1}{3}} {\left (1947 \, x^{6} - 2263 \, x^{5} + 3128 \, x^{4} - 1839 \, x^{3} + 1192 \, x^{2} - 327 \, x + 109\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}} - 3^{\frac {1}{3}} {\left (16199 \, x^{6} - 20631 \, x^{5} + 29268 \, x^{4} - 18463 \, x^{3} + 12204 \, x^{2} - 3567 \, x + 1189\right )}\right )}}{3 \, {\left (17497 \, x^{6} - 20409 \, x^{5} + 28188 \, x^{4} - 16529 \, x^{3} + 10692 \, x^{2} - 2913 \, x + 971\right )}}\right ) + 42 \, \sqrt {3} x^{2} \arctan \left (\frac {26407150 \, \sqrt {3} {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {2}{3}} + 15172108 \, \sqrt {3} {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}} + \sqrt {3} {\left (47470762 \, x^{2} - 20789629 \, x + 20789629\right )}}{29760814 \, x^{2} - 16852563 \, x + 16852563}\right ) - 21 \, x^{2} \log \left (\frac {x^{2} + 3 \, {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {2}{3}} - 3 \, {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}}}{x^{2}}\right ) + 18 \, {\left (3 \, x^{2} - x + 1\right )} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {2}{3}}}{18 \, x^{2}} \]

input
integrate((-2+x)*(x^2-x+1)/x^3/(x^2+x-1)/((2*x^2-x+1)/(3*x^2-x+1))^(1/3),x 
, algorithm="fricas")
 
output
-1/18*(2*3^(2/3)*(-4)^(1/3)*x^2*log(-(24*3^(2/3)*(-4)^(1/3)*(39*x^4 - 28*x 
^3 + 33*x^2 - 10*x + 5)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(2/3) - 3^(1/3)* 
(-4)^(2/3)*(649*x^4 - 538*x^3 + 647*x^2 - 218*x + 109) - 36*(75*x^4 - 58*x 
^3 + 69*x^2 - 22*x + 11)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(1/3))/(x^4 + 2 
*x^3 - x^2 - 2*x + 1)) - 4*3^(2/3)*(-4)^(1/3)*x^2*log(-(9*3^(1/3)*(-4)^(2/ 
3)*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(1/3) + 3^(2/3)*(-4)^ 
(1/3)*(x^2 + x - 1) - 36*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1)) 
^(2/3))/(x^2 + x - 1)) + 12*3^(1/6)*(-4)^(1/3)*x^2*arctan(1/3*3^(1/6)*(12* 
3^(2/3)*(-4)^(2/3)*(39*x^6 + 11*x^5 - 34*x^4 + 51*x^3 - 38*x^2 + 15*x - 5) 
*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(2/3) + 18*(-4)^(1/3)*(1947*x^6 - 2263* 
x^5 + 3128*x^4 - 1839*x^3 + 1192*x^2 - 327*x + 109)*((2*x^2 - x + 1)/(3*x^ 
2 - x + 1))^(1/3) - 3^(1/3)*(16199*x^6 - 20631*x^5 + 29268*x^4 - 18463*x^3 
 + 12204*x^2 - 3567*x + 1189))/(17497*x^6 - 20409*x^5 + 28188*x^4 - 16529* 
x^3 + 10692*x^2 - 2913*x + 971)) + 42*sqrt(3)*x^2*arctan((26407150*sqrt(3) 
*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(2/3) + 15172108*sqrt(3 
)*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(1/3) + sqrt(3)*(47470 
762*x^2 - 20789629*x + 20789629))/(29760814*x^2 - 16852563*x + 16852563)) 
- 21*x^2*log((x^2 + 3*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(2 
/3) - 3*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(1/3))/x^2) + 18 
*(3*x^2 - x + 1)*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(2/3))/x^2
 
3.30.69.6 Sympy [F(-1)]

Timed out. \[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=\text {Timed out} \]

input
integrate((-2+x)*(x**2-x+1)/x**3/(x**2+x-1)/((2*x**2-x+1)/(3*x**2-x+1))**( 
1/3),x)
 
output
Timed out
 
3.30.69.7 Maxima [F]

\[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=\int { \frac {{\left (x^{2} - x + 1\right )} {\left (x - 2\right )}}{{\left (x^{2} + x - 1\right )} x^{3} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}}} \,d x } \]

input
integrate((-2+x)*(x^2-x+1)/x^3/(x^2+x-1)/((2*x^2-x+1)/(3*x^2-x+1))^(1/3),x 
, algorithm="maxima")
 
output
integrate((x^2 - x + 1)*(x - 2)/((x^2 + x - 1)*x^3*((2*x^2 - x + 1)/(3*x^2 
 - x + 1))^(1/3)), x)
 
3.30.69.8 Giac [F]

\[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=\int { \frac {{\left (x^{2} - x + 1\right )} {\left (x - 2\right )}}{{\left (x^{2} + x - 1\right )} x^{3} \left (\frac {2 \, x^{2} - x + 1}{3 \, x^{2} - x + 1}\right )^{\frac {1}{3}}} \,d x } \]

input
integrate((-2+x)*(x^2-x+1)/x^3/(x^2+x-1)/((2*x^2-x+1)/(3*x^2-x+1))^(1/3),x 
, algorithm="giac")
 
output
integrate((x^2 - x + 1)*(x - 2)/((x^2 + x - 1)*x^3*((2*x^2 - x + 1)/(3*x^2 
 - x + 1))^(1/3)), x)
 
3.30.69.9 Mupad [F(-1)]

Timed out. \[ \int \frac {(-2+x) \left (1-x+x^2\right )}{x^3 \left (-1+x+x^2\right ) \sqrt [3]{\frac {1-x+2 x^2}{1-x+3 x^2}}} \, dx=\int \frac {\left (x-2\right )\,\left (x^2-x+1\right )}{x^3\,{\left (\frac {2\,x^2-x+1}{3\,x^2-x+1}\right )}^{1/3}\,\left (x^2+x-1\right )} \,d x \]

input
int(((x - 2)*(x^2 - x + 1))/(x^3*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(1/3)*( 
x + x^2 - 1)),x)
 
output
int(((x - 2)*(x^2 - x + 1))/(x^3*((2*x^2 - x + 1)/(3*x^2 - x + 1))^(1/3)*( 
x + x^2 - 1)), x)