Integrand size = 25, antiderivative size = 89 \[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=-\frac {\sqrt {2} \arctan \left (\frac {\sqrt {-3+2 \sqrt {3}} \sqrt {-1+x^3}}{1+x+x^2}\right )}{3^{3/4}}-\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {3+2 \sqrt {3}} \sqrt {-1+x^3}}{1+x+x^2}\right )}{3^{3/4}} \] Output:
-1/3*2^(1/2)*arctan((-3+2*3^(1/2))^(1/2)*(x^3-1)^(1/2)/(x^2+x+1))*3^(1/4)- 1/3*2^(1/2)*arctanh((3+2*3^(1/2))^(1/2)*(x^3-1)^(1/2)/(x^2+x+1))*3^(1/4)
Time = 1.50 (sec) , antiderivative size = 77, normalized size of antiderivative = 0.87 \[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=-\frac {\sqrt {2} \left (\arctan \left (\frac {\sqrt {-3+2 \sqrt {3}} \sqrt {-1+x^3}}{1+x+x^2}\right )+\text {arctanh}\left (\frac {\sqrt {3+2 \sqrt {3}} \sqrt {-1+x^3}}{1+x+x^2}\right )\right )}{3^{3/4}} \] Input:
Integrate[(2 + x^2)/((-2 - 2*x + x^2)*Sqrt[-1 + x^3]),x]
Output:
-((Sqrt[2]*(ArcTan[(Sqrt[-3 + 2*Sqrt[3]]*Sqrt[-1 + x^3])/(1 + x + x^2)] + ArcTanh[(Sqrt[3 + 2*Sqrt[3]]*Sqrt[-1 + x^3])/(1 + x + x^2)]))/3^(3/4))
Result contains higher order function than in optimal. Order 4 vs. order 3 in optimal.
Time = 1.04 (sec) , antiderivative size = 433, normalized size of antiderivative = 4.87, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.080, Rules used = {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+2}{\left (x^2-2 x-2\right ) \sqrt {x^3-1}} \, dx\) |
\(\Big \downarrow \) 7279 |
\(\displaystyle \int \left (\frac {1}{\sqrt {x^3-1}}+\frac {2 (x+2)}{\left (x^2-2 x-2\right ) \sqrt {x^3-1}}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {2 \sqrt {2-\sqrt {3}} (1-x) \sqrt {\frac {x^2+x+1}{\left (-x-\sqrt {3}+1\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {-x+\sqrt {3}+1}{-x-\sqrt {3}+1}\right ),-7+4 \sqrt {3}\right )}{\sqrt [4]{3} \sqrt {-\frac {1-x}{\left (-x-\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}+\frac {\sqrt {2 \left (7-4 \sqrt {3}\right )} (1-x) \sqrt {\frac {x^2+x+1}{\left (-x-\sqrt {3}+1\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {-x+\sqrt {3}+1}{-x-\sqrt {3}+1}\right ),-7+4 \sqrt {3}\right )}{3^{3/4} \sqrt {-\frac {1-x}{\left (-x-\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}+\frac {\sqrt {2} (1-x) \sqrt {\frac {x^2+x+1}{\left (-x-\sqrt {3}+1\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {-x+\sqrt {3}+1}{-x-\sqrt {3}+1}\right ),-7+4 \sqrt {3}\right )}{3^{3/4} \sqrt {-\frac {1-x}{\left (-x-\sqrt {3}+1\right )^2}} \sqrt {x^3-1}}+\frac {\sqrt {2} \arctan \left (\frac {\sqrt {2 \sqrt {3}-3} (1-x)}{\sqrt {x^3-1}}\right )}{3^{3/4}}+\frac {\sqrt {2} \text {arctanh}\left (\frac {\sqrt {3+2 \sqrt {3}} (1-x)}{\sqrt {x^3-1}}\right )}{3^{3/4}}\) |
Input:
Int[(2 + x^2)/((-2 - 2*x + x^2)*Sqrt[-1 + x^3]),x]
Output:
(Sqrt[2]*ArcTan[(Sqrt[-3 + 2*Sqrt[3]]*(1 - x))/Sqrt[-1 + x^3]])/3^(3/4) + (Sqrt[2]*ArcTanh[(Sqrt[3 + 2*Sqrt[3]]*(1 - x))/Sqrt[-1 + x^3]])/3^(3/4) + (Sqrt[2]*(1 - x)*Sqrt[(1 + x + x^2)/(1 - Sqrt[3] - x)^2]*EllipticF[ArcSin[ (1 + Sqrt[3] - x)/(1 - Sqrt[3] - x)], -7 + 4*Sqrt[3]])/(3^(3/4)*Sqrt[-((1 - x)/(1 - Sqrt[3] - x)^2)]*Sqrt[-1 + x^3]) + (Sqrt[2*(7 - 4*Sqrt[3])]*(1 - x)*Sqrt[(1 + x + x^2)/(1 - Sqrt[3] - x)^2]*EllipticF[ArcSin[(1 + Sqrt[3] - x)/(1 - Sqrt[3] - x)], -7 + 4*Sqrt[3]])/(3^(3/4)*Sqrt[-((1 - x)/(1 - Sqr t[3] - x)^2)]*Sqrt[-1 + x^3]) - (2*Sqrt[2 - Sqrt[3]]*(1 - x)*Sqrt[(1 + x + x^2)/(1 - Sqrt[3] - x)^2]*EllipticF[ArcSin[(1 + Sqrt[3] - x)/(1 - Sqrt[3] - x)], -7 + 4*Sqrt[3]])/(3^(1/4)*Sqrt[-((1 - x)/(1 - Sqrt[3] - x)^2)]*Sqr t[-1 + x^3])
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]
Result contains higher order function than in optimal. Order 4 vs. order 3.
Time = 1.48 (sec) , antiderivative size = 1516, normalized size of antiderivative = 17.03
method | result | size |
default | \(\text {Expression too large to display}\) | \(1516\) |
elliptic | \(\text {Expression too large to display}\) | \(1725\) |
Input:
int((x^2+2)/(x^2-2*x-2)/(x^3-1)^(1/2),x,method=_RETURNVERBOSE)
Output:
2*(-3/2-1/2*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/2*I*3^(1/2))*x)^(1/2)*(1/(-1/2* I*3^(1/2)+3/2)*x+1/2/(-1/2*I*3^(1/2)+3/2)-1/2*I/(-1/2*I*3^(1/2)+3/2)*3^(1/ 2))^(1/2)*(1/(3/2+1/2*I*3^(1/2))*x+1/2/(3/2+1/2*I*3^(1/2))+1/2*I/(3/2+1/2* I*3^(1/2))*3^(1/2))^(1/2)/(x^3-1)^(1/2)*EllipticPi(((-1+x)/(-3/2-1/2*I*3^( 1/2)))^(1/2),-1/3*(3/2+1/2*I*3^(1/2))*3^(1/2),((3/2+1/2*I*3^(1/2))/(-1/2*I *3^(1/2)+3/2))^(1/2))*3^(1/2)+(-1/(-3/2-1/2*I*3^(1/2))+1/(-3/2-1/2*I*3^...
Leaf count of result is larger than twice the leaf count of optimal. 212 vs. \(2 (69) = 138\).
Time = 0.14 (sec) , antiderivative size = 212, normalized size of antiderivative = 2.38 \[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=\frac {1}{2} \, \left (\frac {4}{27}\right )^{\frac {1}{4}} \arctan \left (\frac {3 \, {\left (3 \, \left (\frac {4}{27}\right )^{\frac {3}{4}} {\left (x^{2} - 2 \, x + 4\right )} + 2 \, \left (\frac {4}{27}\right )^{\frac {1}{4}} {\left (x^{2} + 2 \, x\right )}\right )}}{8 \, \sqrt {x^{3} - 1}}\right ) - \frac {1}{4} \, \left (\frac {4}{27}\right )^{\frac {1}{4}} \log \left (\frac {2 \, x^{4} + 4 \, x^{3} + 12 \, x^{2} + 24 \, \sqrt {\frac {1}{3}} {\left (x^{3} - 1\right )} + 3 \, \sqrt {x^{3} - 1} {\left (9 \, \left (\frac {4}{27}\right )^{\frac {3}{4}} {\left (x^{2} + 2\right )} + 2 \, \left (\frac {4}{27}\right )^{\frac {1}{4}} {\left (x^{2} + 4 \, x - 2\right )}\right )} - 8 \, x + 8}{x^{4} - 4 \, x^{3} + 8 \, x + 4}\right ) + \frac {1}{4} \, \left (\frac {4}{27}\right )^{\frac {1}{4}} \log \left (\frac {2 \, x^{4} + 4 \, x^{3} + 12 \, x^{2} + 24 \, \sqrt {\frac {1}{3}} {\left (x^{3} - 1\right )} - 3 \, \sqrt {x^{3} - 1} {\left (9 \, \left (\frac {4}{27}\right )^{\frac {3}{4}} {\left (x^{2} + 2\right )} + 2 \, \left (\frac {4}{27}\right )^{\frac {1}{4}} {\left (x^{2} + 4 \, x - 2\right )}\right )} - 8 \, x + 8}{x^{4} - 4 \, x^{3} + 8 \, x + 4}\right ) \] Input:
integrate((x^2+2)/(x^2-2*x-2)/(x^3-1)^(1/2),x, algorithm="fricas")
Output:
1/2*(4/27)^(1/4)*arctan(3/8*(3*(4/27)^(3/4)*(x^2 - 2*x + 4) + 2*(4/27)^(1/ 4)*(x^2 + 2*x))/sqrt(x^3 - 1)) - 1/4*(4/27)^(1/4)*log((2*x^4 + 4*x^3 + 12* x^2 + 24*sqrt(1/3)*(x^3 - 1) + 3*sqrt(x^3 - 1)*(9*(4/27)^(3/4)*(x^2 + 2) + 2*(4/27)^(1/4)*(x^2 + 4*x - 2)) - 8*x + 8)/(x^4 - 4*x^3 + 8*x + 4)) + 1/4 *(4/27)^(1/4)*log((2*x^4 + 4*x^3 + 12*x^2 + 24*sqrt(1/3)*(x^3 - 1) - 3*sqr t(x^3 - 1)*(9*(4/27)^(3/4)*(x^2 + 2) + 2*(4/27)^(1/4)*(x^2 + 4*x - 2)) - 8 *x + 8)/(x^4 - 4*x^3 + 8*x + 4))
\[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=\int \frac {x^{2} + 2}{\sqrt {\left (x - 1\right ) \left (x^{2} + x + 1\right )} \left (x^{2} - 2 x - 2\right )}\, dx \] Input:
integrate((x**2+2)/(x**2-2*x-2)/(x**3-1)**(1/2),x)
Output:
Integral((x**2 + 2)/(sqrt((x - 1)*(x**2 + x + 1))*(x**2 - 2*x - 2)), x)
\[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=\int { \frac {x^{2} + 2}{\sqrt {x^{3} - 1} {\left (x^{2} - 2 \, x - 2\right )}} \,d x } \] Input:
integrate((x^2+2)/(x^2-2*x-2)/(x^3-1)^(1/2),x, algorithm="maxima")
Output:
integrate((x^2 + 2)/(sqrt(x^3 - 1)*(x^2 - 2*x - 2)), x)
\[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=\int { \frac {x^{2} + 2}{\sqrt {x^{3} - 1} {\left (x^{2} - 2 \, x - 2\right )}} \,d x } \] Input:
integrate((x^2+2)/(x^2-2*x-2)/(x^3-1)^(1/2),x, algorithm="giac")
Output:
integrate((x^2 + 2)/(sqrt(x^3 - 1)*(x^2 - 2*x - 2)), x)
Time = 9.64 (sec) , antiderivative size = 509, normalized size of antiderivative = 5.72 \[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx =\text {Too large to display} \] Input:
int(-(x^2 + 2)/((x^3 - 1)^(1/2)*(2*x - x^2 + 2)),x)
Output:
((2*3^(1/2) + 6)*((3^(1/2)*1i)/2 + 3/2)*(-(x - (3^(1/2)*1i)/2 + 1/2)/((3^( 1/2)*1i)/2 - 3/2))^(1/2)*((x + (3^(1/2)*1i)/2 + 1/2)/((3^(1/2)*1i)/2 + 3/2 ))^(1/2)*(-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)*ellipticPi(-(3^(1/2)*((3^ (1/2)*1i)/2 + 3/2))/3, asin((-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)), -((3 ^(1/2)*1i)/2 + 3/2)/((3^(1/2)*1i)/2 - 3/2)))/(3*(((3^(1/2)*1i)/2 - 1/2)*(( 3^(1/2)*1i)/2 + 1/2) - x*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) + 1) + x^3)^(1/2)) - ((2*3^(1/2) - 6)*((3^(1/2)*1i)/2 + 3/2)*(-(x - (3^(1/2) *1i)/2 + 1/2)/((3^(1/2)*1i)/2 - 3/2))^(1/2)*((x + (3^(1/2)*1i)/2 + 1/2)/(( 3^(1/2)*1i)/2 + 3/2))^(1/2)*(-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)*ellipt icPi((3^(1/2)*((3^(1/2)*1i)/2 + 3/2))/3, asin((-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)), -((3^(1/2)*1i)/2 + 3/2)/((3^(1/2)*1i)/2 - 3/2)))/(3*(((3^(1/ 2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) - x*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/ 2)*1i)/2 + 1/2) + 1) + x^3)^(1/2)) - (2*((3^(1/2)*1i)/2 + 3/2)*(-(x - (3^( 1/2)*1i)/2 + 1/2)/((3^(1/2)*1i)/2 - 3/2))^(1/2)*((x + (3^(1/2)*1i)/2 + 1/2 )/((3^(1/2)*1i)/2 + 3/2))^(1/2)*(-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)*el lipticF(asin((-(x - 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)), -((3^(1/2)*1i)/2 + 3/2)/((3^(1/2)*1i)/2 - 3/2)))/(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/ 2) - x*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) + 1) + x^3)^(1/2)
\[ \int \frac {2+x^2}{\left (-2-2 x+x^2\right ) \sqrt {-1+x^3}} \, dx=2 \left (\int \frac {\sqrt {x^{3}-1}}{x^{5}-2 x^{4}-2 x^{3}-x^{2}+2 x +2}d x \right )+\int \frac {\sqrt {x^{3}-1}\, x^{2}}{x^{5}-2 x^{4}-2 x^{3}-x^{2}+2 x +2}d x \] Input:
int((x^2+2)/(x^2-2*x-2)/(x^3-1)^(1/2),x)
Output:
2*int(sqrt(x**3 - 1)/(x**5 - 2*x**4 - 2*x**3 - x**2 + 2*x + 2),x) + int((s qrt(x**3 - 1)*x**2)/(x**5 - 2*x**4 - 2*x**3 - x**2 + 2*x + 2),x)