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

3.3.99.1 Optimal result
3.3.99.2 Mathematica [A] (verified)
3.3.99.3 Rubi [C] (warning: unable to verify)
3.3.99.4 Maple [A] (verified)
3.3.99.5 Fricas [B] (verification not implemented)
3.3.99.6 Sympy [F]
3.3.99.7 Maxima [F]
3.3.99.8 Giac [F]
3.3.99.9 Mupad [B] (verification not implemented)

3.3.99.1 Optimal result

Integrand size = 21, antiderivative size = 27 \[ \int \frac {2+x}{(-1+x) \sqrt {-1+3 x+x^3}} \, dx=-\frac {2 \text {arctanh}\left (\frac {\sqrt {3} x}{\sqrt {-1+3 x+x^3}}\right )}{\sqrt {3}} \]

output
-2/3*arctanh(3^(1/2)*x/(x^3+3*x-1)^(1/2))*3^(1/2)
 
3.3.99.2 Mathematica [A] (verified)

Time = 0.21 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.00 \[ \int \frac {2+x}{(-1+x) \sqrt {-1+3 x+x^3}} \, dx=-\frac {2 \text {arctanh}\left (\frac {\sqrt {3} x}{\sqrt {-1+3 x+x^3}}\right )}{\sqrt {3}} \]

input
Integrate[(2 + x)/((-1 + x)*Sqrt[-1 + 3*x + x^3]),x]
 
output
(-2*ArcTanh[(Sqrt[3]*x)/Sqrt[-1 + 3*x + x^3]])/Sqrt[3]
 
3.3.99.3 Rubi [C] (warning: unable to verify)

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

Time = 3.73 (sec) , antiderivative size = 1340, normalized size of antiderivative = 49.63, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.095, Rules used = {7293, 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}{(x-1) \sqrt {x^3+3 x-1}} \, dx\)

\(\Big \downarrow \) 7293

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

\(\Big \downarrow \) 2009

\(\displaystyle \frac {2 i 2^{5/6} \sqrt {\frac {x-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+\sqrt [3]{\frac {2}{1+\sqrt {5}}}}{\frac {6}{\sqrt [3]{1+\sqrt {5}}}-3 \sqrt [3]{2 \left (1+\sqrt {5}\right )}-i \sqrt [6]{2} \sqrt {3 \left (4+2 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+\sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}\right )}}} \sqrt {x^2-\left (\sqrt [3]{\frac {2}{1+\sqrt {5}}}-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}\right ) x+\left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}+\left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+1} \operatorname {EllipticF}\left (\arcsin \left (\sqrt {\frac {i \left (-2 x-i \sqrt {6+3 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+3 \left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}}-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+\sqrt [3]{\frac {2}{1+\sqrt {5}}}\right )}{\sqrt {6 \left (4+2 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+\sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}\right )}}}\right ),\frac {2 \sqrt [6]{2} \sqrt {3 \left (4+2 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+\sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}\right )}}{\frac {6 i}{\sqrt [3]{1+\sqrt {5}}}-3 i \sqrt [3]{2 \left (1+\sqrt {5}\right )}+\sqrt [6]{2} \sqrt {3 \left (4+2 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+\sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}\right )}}\right )}{\sqrt {x^3+3 x-1}}-\frac {3 \sqrt [6]{\frac {2}{1+\sqrt {5}}} \sqrt {6-3 \sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}+i \sqrt [6]{2} \sqrt [3]{1+\sqrt {5}} \sqrt {3 \left (4+2 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+\sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}\right )}} \sqrt {x-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+\sqrt [3]{\frac {2}{1+\sqrt {5}}}} \sqrt {1-\frac {2 \left (x-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+\sqrt [3]{\frac {2}{1+\sqrt {5}}}\right )}{3 \sqrt [3]{\frac {2}{1+\sqrt {5}}}-3 \sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}-i \sqrt {6+3 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+3 \left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}}}} \sqrt {1-\frac {2 \left (x-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+\sqrt [3]{\frac {2}{1+\sqrt {5}}}\right )}{3 \sqrt [3]{\frac {2}{1+\sqrt {5}}}-3 \sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+i \sqrt {6+3 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+3 \left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}}}} \operatorname {EllipticPi}\left (\frac {3 \sqrt [3]{\frac {2}{1+\sqrt {5}}}-3 \sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+i \sqrt {6+3 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+3 \left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}}}{2 \left (1+\sqrt [3]{\frac {2}{1+\sqrt {5}}}-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}\right )},\arcsin \left (\frac {2^{5/6} \sqrt [6]{1+\sqrt {5}} \sqrt {x-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+\sqrt [3]{\frac {2}{1+\sqrt {5}}}}}{\sqrt {6-3 \sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}+i \sqrt [6]{2} \sqrt [3]{1+\sqrt {5}} \sqrt {3 \left (4+2 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+\sqrt [3]{2} \left (1+\sqrt {5}\right )^{2/3}\right )}}}\right ),\frac {3 \sqrt [3]{\frac {2}{1+\sqrt {5}}}-3 \sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}+i \sqrt {6+3 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+3 \left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}}}{3 \sqrt [3]{\frac {2}{1+\sqrt {5}}}-3 \sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}-i \sqrt {6+3 \left (\frac {2}{1+\sqrt {5}}\right )^{2/3}+3 \left (\frac {1}{2} \left (1+\sqrt {5}\right )\right )^{2/3}}}\right )}{\left (1+\sqrt [3]{\frac {2}{1+\sqrt {5}}}-\sqrt [3]{\frac {1}{2} \left (1+\sqrt {5}\right )}\right ) \sqrt {x^3+3 x-1}}\)

input
Int[(2 + x)/((-1 + x)*Sqrt[-1 + 3*x + x^3]),x]
 
output
((2*I)*2^(5/6)*Sqrt[((2/(1 + Sqrt[5]))^(1/3) - ((1 + Sqrt[5])/2)^(1/3) + x 
)/(6/(1 + Sqrt[5])^(1/3) - 3*(2*(1 + Sqrt[5]))^(1/3) - I*2^(1/6)*Sqrt[3*(4 
 + 2*(2/(1 + Sqrt[5]))^(2/3) + 2^(1/3)*(1 + Sqrt[5])^(2/3))])]*Sqrt[1 + (2 
/(1 + Sqrt[5]))^(2/3) + ((1 + Sqrt[5])/2)^(2/3) - ((2/(1 + Sqrt[5]))^(1/3) 
 - ((1 + Sqrt[5])/2)^(1/3))*x + x^2]*EllipticF[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])]*EllipticPi[(3*(2/(1 + Sqrt[5]))^(1/3) - 3*((1 + Sqrt[5]...
 

3.3.99.3.1 Defintions of rubi rules used

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

rule 7293
Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v] 
]
 
3.3.99.4 Maple [A] (verified)

Time = 2.25 (sec) , antiderivative size = 25, normalized size of antiderivative = 0.93

method result size
default \(-\frac {2 \sqrt {3}\, \operatorname {arctanh}\left (\frac {\sqrt {x^{3}+3 x -1}\, \sqrt {3}}{3 x}\right )}{3}\) \(25\)
pseudoelliptic \(-\frac {2 \sqrt {3}\, \operatorname {arctanh}\left (\frac {\sqrt {x^{3}+3 x -1}\, \sqrt {3}}{3 x}\right )}{3}\) \(25\)
trager \(\frac {\operatorname {RootOf}\left (\textit {\_Z}^{2}-3\right ) \ln \left (-\frac {\operatorname {RootOf}\left (\textit {\_Z}^{2}-3\right ) x^{3}+3 \operatorname {RootOf}\left (\textit {\_Z}^{2}-3\right ) x^{2}+3 \operatorname {RootOf}\left (\textit {\_Z}^{2}-3\right ) x -6 \sqrt {x^{3}+3 x -1}\, x -\operatorname {RootOf}\left (\textit {\_Z}^{2}-3\right )}{\left (x -1\right )^{3}}\right )}{3}\) \(69\)
elliptic \(\text {Expression too large to display}\) \(1075\)

input
int((x+2)/(x-1)/(x^3+3*x-1)^(1/2),x,method=_RETURNVERBOSE)
 
output
-2/3*3^(1/2)*arctanh(1/3*(x^3+3*x-1)^(1/2)/x*3^(1/2))
 
3.3.99.5 Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 97 vs. \(2 (21) = 42\).

Time = 0.27 (sec) , antiderivative size = 97, normalized size of antiderivative = 3.59 \[ \int \frac {2+x}{(-1+x) \sqrt {-1+3 x+x^3}} \, dx=\frac {1}{6} \, \sqrt {3} \log \left (\frac {x^{6} + 18 \, x^{5} + 15 \, x^{4} + 52 \, x^{3} - 4 \, \sqrt {3} {\left (x^{4} + 3 \, x^{3} + 3 \, x^{2} - x\right )} \sqrt {x^{3} + 3 \, x - 1} - 9 \, x^{2} - 6 \, x + 1}{x^{6} - 6 \, x^{5} + 15 \, x^{4} - 20 \, x^{3} + 15 \, x^{2} - 6 \, x + 1}\right ) \]

input
integrate((2+x)/(-1+x)/(x^3+3*x-1)^(1/2),x, algorithm="fricas")
 
output
1/6*sqrt(3)*log((x^6 + 18*x^5 + 15*x^4 + 52*x^3 - 4*sqrt(3)*(x^4 + 3*x^3 + 
 3*x^2 - x)*sqrt(x^3 + 3*x - 1) - 9*x^2 - 6*x + 1)/(x^6 - 6*x^5 + 15*x^4 - 
 20*x^3 + 15*x^2 - 6*x + 1))
 
3.3.99.6 Sympy [F]

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

input
integrate((2+x)/(-1+x)/(x**3+3*x-1)**(1/2),x)
 
output
Integral((x + 2)/((x - 1)*sqrt(x**3 + 3*x - 1)), x)
 
3.3.99.7 Maxima [F]

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

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

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

input
integrate((2+x)/(-1+x)/(x^3+3*x-1)^(1/2),x, algorithm="giac")
 
output
integrate((x + 2)/(sqrt(x^3 + 3*x - 1)*(x - 1)), x)
 
3.3.99.9 Mupad [B] (verification not implemented)

Time = 6.23 (sec) , antiderivative size = 1872, normalized size of antiderivative = 69.33 \[ \int \frac {2+x}{(-1+x) \sqrt {-1+3 x+x^3}} \, dx=\text {Too large to display} \]

input
int((x + 2)/((x - 1)*(3*x + x^3 - 1)^(1/2)),x)
 
output
(2*(-(x + 1/(5^(1/2)/2 + 1/2)^(1/3) - (5^(1/2)/2 + 1/2)^(1/3))/((3^(1/2)*( 
1/(5^(1/2)/2 + 1/2)^(1/3) + (5^(1/2)/2 + 1/2)^(1/3))*1i)/2 - 3/(2*(5^(1/2) 
/2 + 1/2)^(1/3)) + (3*(5^(1/2)/2 + 1/2)^(1/3))/2))^(1/2)*ellipticF(asin((( 
x + (3^(1/2)*(1/(5^(1/2)/2 + 1/2)^(1/3) + (5^(1/2)/2 + 1/2)^(1/3))*1i)/2 - 
 1/(2*(5^(1/2)/2 + 1/2)^(1/3)) + (5^(1/2)/2 + 1/2)^(1/3)/2)/((3^(1/2)*(1/( 
5^(1/2)/2 + 1/2)^(1/3) + (5^(1/2)/2 + 1/2)^(1/3))*1i)/2 - 3/(2*(5^(1/2)/2 
+ 1/2)^(1/3)) + (3*(5^(1/2)/2 + 1/2)^(1/3))/2))^(1/2)), -(3^(1/2)*((3^(1/2 
)*(1/(5^(1/2)/2 + 1/2)^(1/3) + (5^(1/2)/2 + 1/2)^(1/3))*1i)/2 - 3/(2*(5^(1 
/2)/2 + 1/2)^(1/3)) + (3*(5^(1/2)/2 + 1/2)^(1/3))/2)*1i)/(3*(1/(5^(1/2)/2 
+ 1/2)^(1/3) + (5^(1/2)/2 + 1/2)^(1/3))))*((x + (3^(1/2)*(1/(5^(1/2)/2 + 1 
/2)^(1/3) + (5^(1/2)/2 + 1/2)^(1/3))*1i)/2 - 1/(2*(5^(1/2)/2 + 1/2)^(1/3)) 
 + (5^(1/2)/2 + 1/2)^(1/3)/2)/((3^(1/2)*(1/(5^(1/2)/2 + 1/2)^(1/3) + (5^(1 
/2)/2 + 1/2)^(1/3))*1i)/2 - 3/(2*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