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

   Optimal result
   Rubi [F]
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [F(-1)]
   Maxima [F]
   Giac [F]
   Mupad [F(-1)]

Optimal result

Integrand size = 39, antiderivative size = 100 \[ \int \frac {\left (-1+3 x^4\right ) \sqrt {1+x+2 x^4+x^5+x^8}}{x^2 \left (4+x+4 x^4\right )} \, dx=\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{4 x}-\frac {1}{8} \sqrt {3} \arctan \left (\frac {\sqrt {3} \sqrt {1+x+2 x^4+x^5+x^8}}{1+x+x^4}\right )+\frac {1}{8} \text {arctanh}\left (\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{1+x+x^4}\right ) \]

[Out]

1/4*(x^8+x^5+2*x^4+x+1)^(1/2)/x-1/8*3^(1/2)*arctan(3^(1/2)*(x^8+x^5+2*x^4+x+1)^(1/2)/(x^4+x+1))+1/8*arctanh((x
^8+x^5+2*x^4+x+1)^(1/2)/(x^4+x+1))

Rubi [F]

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

[In]

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

[Out]

-1/4*Defer[Int][Sqrt[1 + x + 2*x^4 + x^5 + x^8]/x^2, x] + Defer[Int][Sqrt[1 + x + 2*x^4 + x^5 + x^8]/x, x]/16
+ Defer[Int][Sqrt[1 + x + 2*x^4 + x^5 + x^8]/(-4 - x - 4*x^4), x]/16 + 4*Defer[Int][(x^2*Sqrt[1 + x + 2*x^4 +
x^5 + x^8])/(4 + x + 4*x^4), x] - Defer[Int][(x^3*Sqrt[1 + x + 2*x^4 + x^5 + x^8])/(4 + x + 4*x^4), x]/4

Rubi steps \begin{align*} \text {integral}& = \int \left (-\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{4 x^2}+\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{16 x}+\frac {\left (-1+64 x^2-4 x^3\right ) \sqrt {1+x+2 x^4+x^5+x^8}}{16 \left (4+x+4 x^4\right )}\right ) \, dx \\ & = \frac {1}{16} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{x} \, dx+\frac {1}{16} \int \frac {\left (-1+64 x^2-4 x^3\right ) \sqrt {1+x+2 x^4+x^5+x^8}}{4+x+4 x^4} \, dx-\frac {1}{4} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{x^2} \, dx \\ & = \frac {1}{16} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{x} \, dx+\frac {1}{16} \int \left (\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{-4-x-4 x^4}+\frac {64 x^2 \sqrt {1+x+2 x^4+x^5+x^8}}{4+x+4 x^4}-\frac {4 x^3 \sqrt {1+x+2 x^4+x^5+x^8}}{4+x+4 x^4}\right ) \, dx-\frac {1}{4} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{x^2} \, dx \\ & = \frac {1}{16} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{x} \, dx+\frac {1}{16} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{-4-x-4 x^4} \, dx-\frac {1}{4} \int \frac {\sqrt {1+x+2 x^4+x^5+x^8}}{x^2} \, dx-\frac {1}{4} \int \frac {x^3 \sqrt {1+x+2 x^4+x^5+x^8}}{4+x+4 x^4} \, dx+4 \int \frac {x^2 \sqrt {1+x+2 x^4+x^5+x^8}}{4+x+4 x^4} \, dx \\ \end{align*}

Mathematica [A] (verified)

Time = 0.23 (sec) , antiderivative size = 100, normalized size of antiderivative = 1.00 \[ \int \frac {\left (-1+3 x^4\right ) \sqrt {1+x+2 x^4+x^5+x^8}}{x^2 \left (4+x+4 x^4\right )} \, dx=\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{4 x}-\frac {1}{8} \sqrt {3} \arctan \left (\frac {\sqrt {3} \sqrt {1+x+2 x^4+x^5+x^8}}{1+x+x^4}\right )+\frac {1}{8} \text {arctanh}\left (\frac {\sqrt {1+x+2 x^4+x^5+x^8}}{1+x+x^4}\right ) \]

[In]

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

[Out]

Sqrt[1 + x + 2*x^4 + x^5 + x^8]/(4*x) - (Sqrt[3]*ArcTan[(Sqrt[3]*Sqrt[1 + x + 2*x^4 + x^5 + x^8])/(1 + x + x^4
)])/8 + ArcTanh[Sqrt[1 + x + 2*x^4 + x^5 + x^8]/(1 + x + x^4)]/8

Maple [A] (verified)

Time = 1.08 (sec) , antiderivative size = 96, normalized size of antiderivative = 0.96

method result size
pseudoelliptic \(\frac {-\sqrt {3}\, \arctan \left (\frac {\left (2 x^{4}-x +2\right ) \sqrt {3}}{6 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}}\right ) x +\ln \left (\frac {2 x^{4}+2 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}+x +2}{x}\right ) x +4 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}}{16 x}\) \(96\)
risch \(\frac {\sqrt {x^{8}+x^{5}+2 x^{4}+x +1}}{4 x}+\frac {\ln \left (-\frac {2 x^{4}+2 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}+x +2}{x}\right )}{16}-\frac {\operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right ) \ln \left (\frac {2 \operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right ) x^{4}-\operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right ) x +2 \operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right )-6 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}}{4 x^{4}+x +4}\right )}{16}\) \(124\)
trager \(\frac {\sqrt {x^{8}+x^{5}+2 x^{4}+x +1}}{4 x}-\frac {\ln \left (-\frac {-2 x^{4}+2 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}-x -2}{x}\right )}{16}+\frac {\operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right ) \ln \left (-\frac {2 \operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right ) x^{4}-\operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right ) x +2 \operatorname {RootOf}\left (\textit {\_Z}^{2}+3\right )+6 \sqrt {x^{8}+x^{5}+2 x^{4}+x +1}}{4 x^{4}+x +4}\right )}{16}\) \(127\)

[In]

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

[Out]

1/16*(-3^(1/2)*arctan(1/6*(2*x^4-x+2)*3^(1/2)/(x^8+x^5+2*x^4+x+1)^(1/2))*x+ln((2*x^4+2*(x^8+x^5+2*x^4+x+1)^(1/
2)+x+2)/x)*x+4*(x^8+x^5+2*x^4+x+1)^(1/2))/x

Fricas [A] (verification not implemented)

none

Time = 1.17 (sec) , antiderivative size = 94, normalized size of antiderivative = 0.94 \[ \int \frac {\left (-1+3 x^4\right ) \sqrt {1+x+2 x^4+x^5+x^8}}{x^2 \left (4+x+4 x^4\right )} \, dx=-\frac {\sqrt {3} x \arctan \left (\frac {\sqrt {3} {\left (2 \, x^{4} - x + 2\right )}}{6 \, \sqrt {x^{8} + x^{5} + 2 \, x^{4} + x + 1}}\right ) + x \log \left (\frac {2 \, x^{4} + x - 2 \, \sqrt {x^{8} + x^{5} + 2 \, x^{4} + x + 1} + 2}{x}\right ) - 4 \, \sqrt {x^{8} + x^{5} + 2 \, x^{4} + x + 1}}{16 \, x} \]

[In]

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

[Out]

-1/16*(sqrt(3)*x*arctan(1/6*sqrt(3)*(2*x^4 - x + 2)/sqrt(x^8 + x^5 + 2*x^4 + x + 1)) + x*log((2*x^4 + x - 2*sq
rt(x^8 + x^5 + 2*x^4 + x + 1) + 2)/x) - 4*sqrt(x^8 + x^5 + 2*x^4 + x + 1))/x

Sympy [F(-1)]

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

[In]

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

[Out]

Timed out

Maxima [F]

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

[In]

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

[Out]

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

Giac [F]

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

[In]

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

[Out]

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

Mupad [F(-1)]

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

[In]

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

[Out]

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