Integrand size = 26, antiderivative size = 103 \[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=-\frac {1}{6} \sqrt {-15+14 \sqrt {3}} \arctan \left (\frac {\sqrt {3+2 \sqrt {3}} \sqrt {1+x^3}}{1-x+x^2}\right )-\frac {1}{6} \sqrt {15+14 \sqrt {3}} \text {arctanh}\left (\frac {\sqrt {-3+2 \sqrt {3}} \sqrt {1+x^3}}{1-x+x^2}\right ) \] Output:
-1/6*(-15+14*3^(1/2))^(1/2)*arctan((3+2*3^(1/2))^(1/2)*(x^3+1)^(1/2)/(x^2- x+1))-1/6*(15+14*3^(1/2))^(1/2)*arctanh((-3+2*3^(1/2))^(1/2)*(x^3+1)^(1/2) /(x^2-x+1))
Time = 1.58 (sec) , antiderivative size = 103, normalized size of antiderivative = 1.00 \[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=-\frac {1}{6} \sqrt {-15+14 \sqrt {3}} \arctan \left (\frac {\sqrt {3+2 \sqrt {3}} \sqrt {1+x^3}}{1-x+x^2}\right )-\frac {1}{6} \sqrt {15+14 \sqrt {3}} \text {arctanh}\left (\frac {\sqrt {-3+2 \sqrt {3}} \sqrt {1+x^3}}{1-x+x^2}\right ) \] Input:
Integrate[(3 + x + x^2)/((-2 + 2*x + x^2)*Sqrt[1 + x^3]),x]
Output:
-1/6*(Sqrt[-15 + 14*Sqrt[3]]*ArcTan[(Sqrt[3 + 2*Sqrt[3]]*Sqrt[1 + x^3])/(1 - x + x^2)]) - (Sqrt[15 + 14*Sqrt[3]]*ArcTanh[(Sqrt[-3 + 2*Sqrt[3]]*Sqrt[ 1 + x^3])/(1 - x + x^2)])/6
Result contains higher order function than in optimal. Order 4 vs. order 3 in optimal.
Time = 0.90 (sec) , antiderivative size = 406, normalized size of antiderivative = 3.94, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.077, 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+x+3}{\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 {5-x}{\left (x^2+2 x-2\right ) \sqrt {x^3+1}}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {\sqrt {38+21 \sqrt {3}} (x+1) \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 )}{2\ 3^{3/4} \sqrt {\frac {x+1}{\left (x+\sqrt {3}+1\right )^2}} \sqrt {x^3+1}}-\frac {\sqrt {14+5 \sqrt {3}} (x+1) \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 )}{2\ 3^{3/4} \sqrt {\frac {x+1}{\left (x+\sqrt {3}+1\right )^2}} \sqrt {x^3+1}}+\frac {2 \sqrt {2+\sqrt {3}} (x+1) \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 {x+1}{\left (x+\sqrt {3}+1\right )^2}} \sqrt {x^3+1}}-\frac {1}{6} \sqrt {14 \sqrt {3}-15} \arctan \left (\frac {\sqrt {3+2 \sqrt {3}} (x+1)}{\sqrt {x^3+1}}\right )-\frac {1}{6} \sqrt {15+14 \sqrt {3}} \text {arctanh}\left (\frac {\sqrt {2 \sqrt {3}-3} (x+1)}{\sqrt {x^3+1}}\right )\) |
Input:
Int[(3 + x + x^2)/((-2 + 2*x + x^2)*Sqrt[1 + x^3]),x]
Output:
-1/6*(Sqrt[-15 + 14*Sqrt[3]]*ArcTan[(Sqrt[3 + 2*Sqrt[3]]*(1 + x))/Sqrt[1 + x^3]]) - (Sqrt[15 + 14*Sqrt[3]]*ArcTanh[(Sqrt[-3 + 2*Sqrt[3]]*(1 + x))/Sq rt[1 + x^3]])/6 + (2*Sqrt[2 + Sqrt[3]]*(1 + x)*Sqrt[(1 - x + x^2)/(1 + Sqr t[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]*Sqrt[1 + x^3]) - (Sq rt[14 + 5*Sqrt[3]]*(1 + x)*Sqrt[(1 - x + x^2)/(1 + Sqrt[3] + x)^2]*Ellipti cF[ArcSin[(1 - Sqrt[3] + x)/(1 + Sqrt[3] + x)], -7 - 4*Sqrt[3]])/(2*3^(3/4 )*Sqrt[(1 + x)/(1 + Sqrt[3] + x)^2]*Sqrt[1 + x^3]) - (Sqrt[38 + 21*Sqrt[3] ]*(1 + x)*Sqrt[(1 - x + x^2)/(1 + Sqrt[3] + x)^2]*EllipticF[ArcSin[(1 - Sq rt[3] + x)/(1 + Sqrt[3] + x)], -7 - 4*Sqrt[3]])/(2*3^(3/4)*Sqrt[(1 + x)/(1 + Sqrt[3] + x)^2]*Sqrt[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 9 vs. order 3.
Time = 3.34 (sec) , antiderivative size = 594, normalized size of antiderivative = 5.77
method | result | size |
trager | \(\frac {\operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right ) \ln \left (\frac {3888 \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right ) \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{4} x^{2}-7776 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{4} x \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right )-8280 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right ) x^{2}+10512 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right ) x +44352 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} \sqrt {x^{3}+1}-6048 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right )+4147 \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right ) x^{2}-286 \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right ) x -44352 \sqrt {x^{3}+1}+8008 \operatorname {RootOf}\left (\textit {\_Z}^{2}+36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2}-30\right )}{{\left (36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} x -29 x +28\right )}^{2}}\right )}{12}-\frac {\operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right ) \ln \left (-\frac {3888 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{5} x^{2}-7776 x \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{5}+1800 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{3} x^{2}+2448 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{3} x +6048 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{3}+7392 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} \sqrt {x^{3}+1}-53 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right ) x^{2}+3074 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right ) x +2968 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )+1232 \sqrt {x^{3}+1}}{{\left (36 \operatorname {RootOf}\left (432 \textit {\_Z}^{4}-360 \textit {\_Z}^{2}-121\right )^{2} x -x -28\right )}^{2}}\right )}{2}\) | \(594\) |
default | \(\text {Expression too large to display}\) | \(1501\) |
elliptic | \(\text {Expression too large to display}\) | \(1706\) |
Input:
int((x^2+x+3)/(x^2+2*x-2)/(x^3+1)^(1/2),x,method=_RETURNVERBOSE)
Output:
1/12*RootOf(_Z^2+36*RootOf(432*_Z^4-360*_Z^2-121)^2-30)*ln((3888*RootOf(_Z ^2+36*RootOf(432*_Z^4-360*_Z^2-121)^2-30)*RootOf(432*_Z^4-360*_Z^2-121)^4* x^2-7776*RootOf(432*_Z^4-360*_Z^2-121)^4*x*RootOf(_Z^2+36*RootOf(432*_Z^4- 360*_Z^2-121)^2-30)-8280*RootOf(432*_Z^4-360*_Z^2-121)^2*RootOf(_Z^2+36*Ro otOf(432*_Z^4-360*_Z^2-121)^2-30)*x^2+10512*RootOf(432*_Z^4-360*_Z^2-121)^ 2*RootOf(_Z^2+36*RootOf(432*_Z^4-360*_Z^2-121)^2-30)*x+44352*RootOf(432*_Z ^4-360*_Z^2-121)^2*(x^3+1)^(1/2)-6048*RootOf(432*_Z^4-360*_Z^2-121)^2*Root Of(_Z^2+36*RootOf(432*_Z^4-360*_Z^2-121)^2-30)+4147*RootOf(_Z^2+36*RootOf( 432*_Z^4-360*_Z^2-121)^2-30)*x^2-286*RootOf(_Z^2+36*RootOf(432*_Z^4-360*_Z ^2-121)^2-30)*x-44352*(x^3+1)^(1/2)+8008*RootOf(_Z^2+36*RootOf(432*_Z^4-36 0*_Z^2-121)^2-30))/(36*RootOf(432*_Z^4-360*_Z^2-121)^2*x-29*x+28)^2)-1/2*R ootOf(432*_Z^4-360*_Z^2-121)*ln(-(3888*RootOf(432*_Z^4-360*_Z^2-121)^5*x^2 -7776*x*RootOf(432*_Z^4-360*_Z^2-121)^5+1800*RootOf(432*_Z^4-360*_Z^2-121) ^3*x^2+2448*RootOf(432*_Z^4-360*_Z^2-121)^3*x+6048*RootOf(432*_Z^4-360*_Z^ 2-121)^3+7392*RootOf(432*_Z^4-360*_Z^2-121)^2*(x^3+1)^(1/2)-53*RootOf(432* _Z^4-360*_Z^2-121)*x^2+3074*RootOf(432*_Z^4-360*_Z^2-121)*x+2968*RootOf(43 2*_Z^4-360*_Z^2-121)+1232*(x^3+1)^(1/2))/(36*RootOf(432*_Z^4-360*_Z^2-121) ^2*x-x-28)^2)
Leaf count of result is larger than twice the leaf count of optimal. 256 vs. \(2 (79) = 158\).
Time = 0.15 (sec) , antiderivative size = 256, normalized size of antiderivative = 2.49 \[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=-\frac {1}{12} \, \sqrt {14 \, \sqrt {3} - 15} \arctan \left (-\frac {{\left (6 \, x^{2} - \sqrt {3} {\left (x^{2} + 8 \, x + 10\right )} - 18 \, x - 6\right )} \sqrt {14 \, \sqrt {3} - 15}}{66 \, \sqrt {x^{3} + 1}}\right ) + \frac {1}{24} \, \sqrt {14 \, \sqrt {3} + 15} \log \left (\frac {11 \, x^{4} - 22 \, x^{3} + 66 \, x^{2} + 2 \, \sqrt {x^{3} + 1} {\left (4 \, x^{2} - \sqrt {3} {\left (3 \, x^{2} - 2 \, x + 4\right )} - 10 \, x - 2\right )} \sqrt {14 \, \sqrt {3} + 15} + 44 \, \sqrt {3} {\left (x^{3} + 1\right )} + 44 \, x + 44}{x^{4} + 4 \, x^{3} - 8 \, x + 4}\right ) - \frac {1}{24} \, \sqrt {14 \, \sqrt {3} + 15} \log \left (\frac {11 \, x^{4} - 22 \, x^{3} + 66 \, x^{2} - 2 \, \sqrt {x^{3} + 1} {\left (4 \, x^{2} - \sqrt {3} {\left (3 \, x^{2} - 2 \, x + 4\right )} - 10 \, x - 2\right )} \sqrt {14 \, \sqrt {3} + 15} + 44 \, \sqrt {3} {\left (x^{3} + 1\right )} + 44 \, x + 44}{x^{4} + 4 \, x^{3} - 8 \, x + 4}\right ) \] Input:
integrate((x^2+x+3)/(x^2+2*x-2)/(x^3+1)^(1/2),x, algorithm="fricas")
Output:
-1/12*sqrt(14*sqrt(3) - 15)*arctan(-1/66*(6*x^2 - sqrt(3)*(x^2 + 8*x + 10) - 18*x - 6)*sqrt(14*sqrt(3) - 15)/sqrt(x^3 + 1)) + 1/24*sqrt(14*sqrt(3) + 15)*log((11*x^4 - 22*x^3 + 66*x^2 + 2*sqrt(x^3 + 1)*(4*x^2 - sqrt(3)*(3*x ^2 - 2*x + 4) - 10*x - 2)*sqrt(14*sqrt(3) + 15) + 44*sqrt(3)*(x^3 + 1) + 4 4*x + 44)/(x^4 + 4*x^3 - 8*x + 4)) - 1/24*sqrt(14*sqrt(3) + 15)*log((11*x^ 4 - 22*x^3 + 66*x^2 - 2*sqrt(x^3 + 1)*(4*x^2 - sqrt(3)*(3*x^2 - 2*x + 4) - 10*x - 2)*sqrt(14*sqrt(3) + 15) + 44*sqrt(3)*(x^3 + 1) + 44*x + 44)/(x^4 + 4*x^3 - 8*x + 4))
\[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=\int \frac {x^{2} + x + 3}{\sqrt {\left (x + 1\right ) \left (x^{2} - x + 1\right )} \left (x^{2} + 2 x - 2\right )}\, dx \] Input:
integrate((x**2+x+3)/(x**2+2*x-2)/(x**3+1)**(1/2),x)
Output:
Integral((x**2 + x + 3)/(sqrt((x + 1)*(x**2 - x + 1))*(x**2 + 2*x - 2)), x )
\[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=\int { \frac {x^{2} + x + 3}{\sqrt {x^{3} + 1} {\left (x^{2} + 2 \, x - 2\right )}} \,d x } \] Input:
integrate((x^2+x+3)/(x^2+2*x-2)/(x^3+1)^(1/2),x, algorithm="maxima")
Output:
integrate((x^2 + x + 3)/(sqrt(x^3 + 1)*(x^2 + 2*x - 2)), x)
\[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=\int { \frac {x^{2} + x + 3}{\sqrt {x^{3} + 1} {\left (x^{2} + 2 \, x - 2\right )}} \,d x } \] Input:
integrate((x^2+x+3)/(x^2+2*x-2)/(x^3+1)^(1/2),x, algorithm="giac")
Output:
integrate((x^2 + x + 3)/(sqrt(x^3 + 1)*(x^2 + 2*x - 2)), x)
Time = 0.09 (sec) , antiderivative size = 505, normalized size of antiderivative = 4.90 \[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx =\text {Too large to display} \] Input:
int((x + x^2 + 3)/((x^3 + 1)^(1/2)*(2*x + x^2 - 2)),x)
Output:
(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 + 1)/((3^(1/2)*1i)/2 + 3/2))^(1/2)*(((3^(1/2)*1i)/2 - x + 1/ 2)/((3^(1/2)*1i)/2 + 3/2))^(1/2)*ellipticF(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)))/(x^3 - x*( ((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) + 1) - ((3^(1/2)*1i)/2 - 1/2 )*((3^(1/2)*1i)/2 + 1/2))^(1/2) + (((3^(1/2)*1i)/2 + 3/2)*((x + (3^(1/2)*1 i)/2 - 1/2)/((3^(1/2)*1i)/2 - 3/2))^(1/2)*((x + 1)/((3^(1/2)*1i)/2 + 3/2)) ^(1/2)*(3^(1/2) - 6)*(((3^(1/2)*1i)/2 - x + 1/2)/((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*(x^3 - x*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) + 1) - ((3^(1/2) *1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2))^(1/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 + 1)/((3^(1/2)* 1i)/2 + 3/2))^(1/2)*(3^(1/2) + 6)*(((3^(1/2)*1i)/2 - x + 1/2)/((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*(x^3 - x*(((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2) + 1) - ((3^(1/2)*1i)/2 - 1/2)*((3^(1/2)*1i)/2 + 1/2))^(1/2))
\[ \int \frac {3+x+x^2}{\left (-2+2 x+x^2\right ) \sqrt {1+x^3}} \, dx=3 \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 +\int \frac {\sqrt {x^{3}+1}\, x}{x^{5}+2 x^{4}-2 x^{3}+x^{2}+2 x -2}d x \] Input:
int((x^2+x+3)/(x^2+2*x-2)/(x^3+1)^(1/2),x)
Output:
3*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) + int((sq rt(x**3 + 1)*x)/(x**5 + 2*x**4 - 2*x**3 + x**2 + 2*x - 2),x)