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

Optimal result
Mathematica [A] (verified)
Rubi [C] (warning: unable to verify)
Maple [A] (verified)
Fricas [A] (verification not implemented)
Sympy [F]
Maxima [F]
Giac [F]
Mupad [F(-1)]
Reduce [F]

Optimal result

Integrand size = 27, antiderivative size = 93 \[ \int \frac {1+x^2}{\left (-1+x+x^2\right ) \sqrt [3]{-x^2+x^4}} \, dx=-\sqrt {3} \arctan \left (\frac {\sqrt {3} x}{-x+2 \sqrt [3]{-x^2+x^4}}\right )-\log \left (x+\sqrt [3]{-x^2+x^4}\right )+\frac {1}{2} \log \left (x^2-x \sqrt [3]{-x^2+x^4}+\left (-x^2+x^4\right )^{2/3}\right ) \] Output:

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

Mathematica [A] (verified)

Time = 1.01 (sec) , antiderivative size = 120, normalized size of antiderivative = 1.29 \[ \int \frac {1+x^2}{\left (-1+x+x^2\right ) \sqrt [3]{-x^2+x^4}} \, dx=\frac {x^{2/3} \sqrt [3]{-1+x^2} \left (2 \sqrt {3} \arctan \left (\frac {\sqrt {3} \sqrt [3]{x}}{\sqrt [3]{x}-2 \sqrt [3]{-1+x^2}}\right )-2 \log \left (\sqrt [3]{x}+\sqrt [3]{-1+x^2}\right )+\log \left (x^{2/3}-\sqrt [3]{x} \sqrt [3]{-1+x^2}+\left (-1+x^2\right )^{2/3}\right )\right )}{2 \sqrt [3]{x^2 \left (-1+x^2\right )}} \] Input:

Integrate[(1 + x^2)/((-1 + x + x^2)*(-x^2 + x^4)^(1/3)),x]
 

Output:

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

Rubi [C] (warning: unable to verify)

Result contains higher order function than in optimal. Order 6 vs. order 3 in optimal.

Time = 1.04 (sec) , antiderivative size = 332, normalized size of antiderivative = 3.57, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.185, Rules used = {2467, 25, 2035, 7279, 2009}

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+1}{\left (x^2+x-1\right ) \sqrt [3]{x^4-x^2}} \, dx\)

\(\Big \downarrow \) 2467

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

\(\Big \downarrow \) 25

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

\(\Big \downarrow \) 2035

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

\(\Big \downarrow \) 7279

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

\(\Big \downarrow \) 2009

\(\displaystyle -\frac {3 x^{2/3} \sqrt [3]{x^2-1} \left (\frac {\sqrt [3]{1-x^2} \sqrt [3]{x} \operatorname {AppellF1}\left (\frac {1}{6},\frac {1}{3},1,\frac {7}{6},x^2,\frac {2 x^2}{3-\sqrt {5}}\right )}{\sqrt [3]{x^2-1}}+\frac {\sqrt [3]{1-x^2} \sqrt [3]{x} \operatorname {AppellF1}\left (\frac {1}{6},1,\frac {1}{3},\frac {7}{6},\frac {2 x^2}{3+\sqrt {5}},x^2\right )}{\sqrt [3]{x^2-1}}-\frac {\left (1-\sqrt {5}\right ) \sqrt [3]{1-x^2} x^{4/3} \operatorname {AppellF1}\left (\frac {2}{3},\frac {1}{3},1,\frac {5}{3},x^2,\frac {2 x^2}{3-\sqrt {5}}\right )}{4 \left (3-\sqrt {5}\right ) \sqrt [3]{x^2-1}}-\frac {\left (1+\sqrt {5}\right ) \sqrt [3]{1-x^2} x^{4/3} \operatorname {AppellF1}\left (\frac {2}{3},\frac {1}{3},1,\frac {5}{3},x^2,\frac {2 x^2}{3+\sqrt {5}}\right )}{4 \left (3+\sqrt {5}\right ) \sqrt [3]{x^2-1}}-\frac {\sqrt [3]{1-x^2} \sqrt [3]{x} \operatorname {Hypergeometric2F1}\left (\frac {1}{6},\frac {1}{3},\frac {7}{6},x^2\right )}{\sqrt [3]{x^2-1}}\right )}{\sqrt [3]{x^4-x^2}}\)

Input:

Int[(1 + x^2)/((-1 + x + x^2)*(-x^2 + x^4)^(1/3)),x]
 

Output:

(-3*x^(2/3)*(-1 + x^2)^(1/3)*((x^(1/3)*(1 - x^2)^(1/3)*AppellF1[1/6, 1/3, 
1, 7/6, x^2, (2*x^2)/(3 - Sqrt[5])])/(-1 + x^2)^(1/3) + (x^(1/3)*(1 - x^2) 
^(1/3)*AppellF1[1/6, 1, 1/3, 7/6, (2*x^2)/(3 + Sqrt[5]), x^2])/(-1 + x^2)^ 
(1/3) - ((1 - Sqrt[5])*x^(4/3)*(1 - x^2)^(1/3)*AppellF1[2/3, 1/3, 1, 5/3, 
x^2, (2*x^2)/(3 - Sqrt[5])])/(4*(3 - Sqrt[5])*(-1 + x^2)^(1/3)) - ((1 + Sq 
rt[5])*x^(4/3)*(1 - x^2)^(1/3)*AppellF1[2/3, 1/3, 1, 5/3, x^2, (2*x^2)/(3 
+ Sqrt[5])])/(4*(3 + Sqrt[5])*(-1 + x^2)^(1/3)) - (x^(1/3)*(1 - x^2)^(1/3) 
*Hypergeometric2F1[1/6, 1/3, 7/6, x^2])/(-1 + x^2)^(1/3)))/(-x^2 + x^4)^(1 
/3)
 

Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

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

rule 2035
Int[(Fx_)*(x_)^(m_), x_Symbol] :> With[{k = Denominator[m]}, Simp[k   Subst 
[Int[x^(k*(m + 1) - 1)*SubstPower[Fx, x, k], x], x, x^(1/k)], x]] /; Fracti 
onQ[m] && AlgebraicFunctionQ[Fx, x]
 

rule 2467
Int[(Fx_.)*(Px_)^(p_), x_Symbol] :> With[{r = Expon[Px, x, Min]}, Simp[Px^F 
racPart[p]/(x^(r*FracPart[p])*ExpandToSum[Px/x^r, x]^FracPart[p])   Int[x^( 
p*r)*ExpandToSum[Px/x^r, x]^p*Fx, x], x] /; IGtQ[r, 0]] /; FreeQ[p, x] && P 
olyQ[Px, x] &&  !IntegerQ[p] &&  !MonomialQ[Px, x] &&  !PolyQ[Fx, 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]
 
Maple [A] (verified)

Time = 2.07 (sec) , antiderivative size = 87, normalized size of antiderivative = 0.94

method result size
pseudoelliptic \(\frac {\ln \left (\frac {x^{2}-x \left (x^{4}-x^{2}\right )^{\frac {1}{3}}+\left (x^{4}-x^{2}\right )^{\frac {2}{3}}}{x^{2}}\right )}{2}-\sqrt {3}\, \arctan \left (\frac {\left (-2 \left (x^{4}-x^{2}\right )^{\frac {1}{3}}+x \right ) \sqrt {3}}{3 x}\right )-\ln \left (\frac {x +\left (x^{4}-x^{2}\right )^{\frac {1}{3}}}{x}\right )\) \(87\)
trager \(-\ln \left (-\frac {370 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right )^{2} x^{3}-555 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right )^{2} x^{2}-862 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) x^{3}-370 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right )^{2} x -1356 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) \left (x^{4}-x^{2}\right )^{\frac {2}{3}}-2346 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) \left (x^{4}-x^{2}\right )^{\frac {1}{3}} x -2 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) x^{2}-744 x^{3}+862 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) x -1980 \left (x^{4}-x^{2}\right )^{\frac {2}{3}}+2712 x \left (x^{4}-x^{2}\right )^{\frac {1}{3}}+248 x^{2}+744 x}{x \left (x^{2}+x -1\right )}\right )+\frac {\operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) \ln \left (-\frac {62 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right )^{2} x^{3}-93 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right )^{2} x^{2}+432 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) x^{3}-62 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right )^{2} x +678 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) \left (x^{4}-x^{2}\right )^{\frac {2}{3}}-495 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) \left (x^{4}-x^{2}\right )^{\frac {1}{3}} x -431 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) x^{2}+370 x^{3}-432 \operatorname {RootOf}\left (\textit {\_Z}^{2}-2 \textit {\_Z} +4\right ) x -2346 \left (x^{4}-x^{2}\right )^{\frac {2}{3}}-1356 x \left (x^{4}-x^{2}\right )^{\frac {1}{3}}+740 x^{2}-370 x}{x \left (x^{2}+x -1\right )}\right )}{2}\) \(387\)

Input:

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

Output:

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

Fricas [A] (verification not implemented)

Time = 0.62 (sec) , antiderivative size = 130, normalized size of antiderivative = 1.40 \[ \int \frac {1+x^2}{\left (-1+x+x^2\right ) \sqrt [3]{-x^2+x^4}} \, dx=-\sqrt {3} \arctan \left (-\frac {128537192 \, \sqrt {3} {\left (x^{4} - x^{2}\right )}^{\frac {1}{3}} x + \sqrt {3} {\left (1454911 \, x^{3} - 69864736 \, x^{2} - 1454911 \, x\right )} - 14102102 \, \sqrt {3} {\left (x^{4} - x^{2}\right )}^{\frac {2}{3}}}{226981 \, x^{3} + 171879616 \, x^{2} - 226981 \, x}\right ) - \frac {1}{2} \, \log \left (\frac {x^{3} + x^{2} + 3 \, {\left (x^{4} - x^{2}\right )}^{\frac {1}{3}} x - x + 3 \, {\left (x^{4} - x^{2}\right )}^{\frac {2}{3}}}{x^{3} + x^{2} - x}\right ) \] Input:

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

Output:

-sqrt(3)*arctan(-(128537192*sqrt(3)*(x^4 - x^2)^(1/3)*x + sqrt(3)*(1454911 
*x^3 - 69864736*x^2 - 1454911*x) - 14102102*sqrt(3)*(x^4 - x^2)^(2/3))/(22 
6981*x^3 + 171879616*x^2 - 226981*x)) - 1/2*log((x^3 + x^2 + 3*(x^4 - x^2) 
^(1/3)*x - x + 3*(x^4 - x^2)^(2/3))/(x^3 + x^2 - x))
 

Sympy [F]

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

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

Output:

Integral((x**2 + 1)/((x**2*(x - 1)*(x + 1))**(1/3)*(x**2 + x - 1)), x)
 

Maxima [F]

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

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

Output:

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

Giac [F]

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

integrate((x^2+1)/(x^2+x-1)/(x^4-x^2)^(1/3),x, algorithm="giac")
 

Output:

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

Mupad [F(-1)]

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

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

Output:

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

Reduce [F]

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

int((x^2+1)/(x^2+x-1)/(x^4-x^2)^(1/3),x)
 

Output:

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