\(\int \frac {x^2}{2-(1+x^2)^4} \, dx\) [387]
Optimal result
Integrand size = 17, antiderivative size = 157 \[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=\frac {i \sqrt {1-i \sqrt [4]{2}} \arctan \left (\frac {x}{\sqrt {1-i \sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {i \sqrt {1+i \sqrt [4]{2}} \arctan \left (\frac {x}{\sqrt {1+i \sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {\sqrt {1+\sqrt [4]{2}} \arctan \left (\frac {x}{\sqrt {1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}}+\frac {\sqrt {-1+\sqrt [4]{2}} \text {arctanh}\left (\frac {x}{\sqrt {-1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}}
\]
[Out]
1/8*I*arctan(x/(1-I*2^(1/4))^(1/2))*(1-I*2^(1/4))^(1/2)*2^(1/4)-1/8*I*arctan(x/(1+I*2^(1/4))^(1/2))*(1+I*2^(1/
4))^(1/2)*2^(1/4)+1/8*arctanh(x/(-1+2^(1/4))^(1/2))*(-1+2^(1/4))^(1/2)*2^(1/4)-1/8*arctan(x/(1+2^(1/4))^(1/2))
*(1+2^(1/4))^(1/2)*2^(1/4)
Rubi [A] (verified)
Time = 0.14 (sec) , antiderivative size = 157, normalized size of antiderivative = 1.00, number of
steps used = 8, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.294, Rules used = {6872, 212, 209, 1997, 211}
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=\frac {i \sqrt {1-i \sqrt [4]{2}} \arctan \left (\frac {x}{\sqrt {1-i \sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {i \sqrt {1+i \sqrt [4]{2}} \arctan \left (\frac {x}{\sqrt {1+i \sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {\sqrt {1+\sqrt [4]{2}} \arctan \left (\frac {x}{\sqrt {1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}}+\frac {\sqrt {\sqrt [4]{2}-1} \text {arctanh}\left (\frac {x}{\sqrt {\sqrt [4]{2}-1}}\right )}{4\ 2^{3/4}}
\]
[In]
Int[x^2/(2 - (1 + x^2)^4),x]
[Out]
((I/4)*Sqrt[1 - I*2^(1/4)]*ArcTan[x/Sqrt[1 - I*2^(1/4)]])/2^(3/4) - ((I/4)*Sqrt[1 + I*2^(1/4)]*ArcTan[x/Sqrt[1
+ I*2^(1/4)]])/2^(3/4) - (Sqrt[1 + 2^(1/4)]*ArcTan[x/Sqrt[1 + 2^(1/4)]])/(4*2^(3/4)) + (Sqrt[-1 + 2^(1/4)]*Ar
cTanh[x/Sqrt[-1 + 2^(1/4)]])/(4*2^(3/4))
Rule 209
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*ArcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /;
FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])
Rule 211
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/Rt[a/b, 2]], x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]
Rule 212
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))*ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x]
/; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])
Rule 1997
Int[(u_)^(p_), x_Symbol] :> Int[ExpandToSum[u, x]^p, x] /; FreeQ[p, x] && BinomialQ[u, x] && !BinomialMatchQ[
u, x]
Rule 6872
Int[(v_)/((a_) + (b_.)*(u_)^(n_.)), x_Symbol] :> Int[ExpandIntegrand[PolynomialInSubst[v, u, x]/(a + b*x^n), x
] /. x -> u, x] /; FreeQ[{a, b}, x] && IGtQ[n, 0] && PolynomialInQ[v, u, x]
Rubi steps \begin{align*}
\text {integral}& = \int \left (\frac {-\sqrt [4]{2}+\sqrt {2}}{8 \left (-1+\sqrt [4]{2}-x^2\right )}+\frac {-\sqrt [4]{2}-\sqrt {2}}{8 \left (1+\sqrt [4]{2}+x^2\right )}+\frac {-\sqrt [4]{2}-i \sqrt {2}}{8 \left (\sqrt [4]{2}-i \left (1+x^2\right )\right )}+\frac {-\sqrt [4]{2}+i \sqrt {2}}{8 \left (\sqrt [4]{2}+i \left (1+x^2\right )\right )}\right ) \, dx \\ & = -\frac {\left (1-\sqrt [4]{2}\right ) \int \frac {1}{-1+\sqrt [4]{2}-x^2} \, dx}{4\ 2^{3/4}}-\frac {\left (1-i \sqrt [4]{2}\right ) \int \frac {1}{\sqrt [4]{2}+i \left (1+x^2\right )} \, dx}{4\ 2^{3/4}}-\frac {\left (1+i \sqrt [4]{2}\right ) \int \frac {1}{\sqrt [4]{2}-i \left (1+x^2\right )} \, dx}{4\ 2^{3/4}}-\frac {\left (1+\sqrt [4]{2}\right ) \int \frac {1}{1+\sqrt [4]{2}+x^2} \, dx}{4\ 2^{3/4}} \\ & = -\frac {\sqrt {1+\sqrt [4]{2}} \tan ^{-1}\left (\frac {x}{\sqrt {1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}}+\frac {\sqrt {-1+\sqrt [4]{2}} \tanh ^{-1}\left (\frac {x}{\sqrt {-1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {\left (1-i \sqrt [4]{2}\right ) \int \frac {1}{i+\sqrt [4]{2}+i x^2} \, dx}{4\ 2^{3/4}}-\frac {\left (1+i \sqrt [4]{2}\right ) \int \frac {1}{-i+\sqrt [4]{2}-i x^2} \, dx}{4\ 2^{3/4}} \\ & = \frac {i \sqrt {1-i \sqrt [4]{2}} \tan ^{-1}\left (\frac {x}{\sqrt {1-i \sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {i \sqrt {1+i \sqrt [4]{2}} \tan ^{-1}\left (\frac {x}{\sqrt {1+i \sqrt [4]{2}}}\right )}{4\ 2^{3/4}}-\frac {\sqrt {1+\sqrt [4]{2}} \tan ^{-1}\left (\frac {x}{\sqrt {1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}}+\frac {\sqrt {-1+\sqrt [4]{2}} \tanh ^{-1}\left (\frac {x}{\sqrt {-1+\sqrt [4]{2}}}\right )}{4\ 2^{3/4}} \\
\end{align*}
Mathematica [C] (verified)
Result contains higher order function than in optimal. Order 9 vs. order 3 in optimal.
Time = 0.01 (sec) , antiderivative size = 61, normalized size of antiderivative = 0.39
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=-\frac {1}{8} \text {RootSum}\left [-1+4 \text {$\#$1}^2+6 \text {$\#$1}^4+4 \text {$\#$1}^6+\text {$\#$1}^8\&,\frac {\log (x-\text {$\#$1}) \text {$\#$1}}{1+3 \text {$\#$1}^2+3 \text {$\#$1}^4+\text {$\#$1}^6}\&\right ]
\]
[In]
Integrate[x^2/(2 - (1 + x^2)^4),x]
[Out]
-1/8*RootSum[-1 + 4*#1^2 + 6*#1^4 + 4*#1^6 + #1^8 & , (Log[x - #1]*#1)/(1 + 3*#1^2 + 3*#1^4 + #1^6) & ]
Maple [C] (verified)
Result contains higher order function than in optimal. Order 9 vs. order 3.
Time = 0.07 (sec) , antiderivative size = 54, normalized size of antiderivative = 0.34
| | |
method | result | size |
| | |
default |
\(-\frac {\left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (\textit {\_Z}^{8}+4 \textit {\_Z}^{6}+6 \textit {\_Z}^{4}+4 \textit {\_Z}^{2}-1\right )}{\sum }\frac {\textit {\_R}^{2} \ln \left (x -\textit {\_R} \right )}{\textit {\_R}^{7}+3 \textit {\_R}^{5}+3 \textit {\_R}^{3}+\textit {\_R}}\right )}{8}\) |
\(54\) |
risch |
\(-\frac {\left (\munderset {\textit {\_R} =\operatorname {RootOf}\left (\textit {\_Z}^{8}+4 \textit {\_Z}^{6}+6 \textit {\_Z}^{4}+4 \textit {\_Z}^{2}-1\right )}{\sum }\frac {\textit {\_R}^{2} \ln \left (x -\textit {\_R} \right )}{\textit {\_R}^{7}+3 \textit {\_R}^{5}+3 \textit {\_R}^{3}+\textit {\_R}}\right )}{8}\) |
\(54\) |
| | |
|
|
|
[In]
int(x^2/(2-(x^2+1)^4),x,method=_RETURNVERBOSE)
[Out]
-1/8*sum(_R^2/(_R^7+3*_R^5+3*_R^3+_R)*ln(x-_R),_R=RootOf(_Z^8+4*_Z^6+6*_Z^4+4*_Z^2-1))
Fricas [B] (verification not implemented)
Leaf count of result is larger than twice the leaf count of optimal. 1506 vs. \(2 (97) = 194\).
Time = 1.02 (sec) , antiderivative size = 1506, normalized size of antiderivative = 9.59
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=\text {Too large to display}
\]
[In]
integrate(x^2/(2-(x^2+1)^4),x, algorithm="fricas")
[Out]
-1/16*sqrt(2)*sqrt(1/2*sqrt(2) + sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)
) - 3/16*(2^(3/4) - sqrt(2))^2 + 1))*log(1/4*((sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4) - sqrt(2))^2 +
sqrt(2)*(2^(3/4) + sqrt(2))^2 - (sqrt(2)*(2^(3/4) + sqrt(2))^2 - 4*sqrt(2))*(2^(3/4) - sqrt(2)) + 4*sqrt(-3/16
*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1)*((sqrt(
2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4) - sqrt(2)) - sqrt(2)*(2^(3/4) + sqrt(2)) - 4*sqrt(2)) - 4*sqrt(2)*(
2^(3/4) + sqrt(2)) + 4*sqrt(2))*sqrt(1/2*sqrt(2) + sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*
(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1)) + 6*x) + 1/16*sqrt(2)*sqrt(1/2*sqrt(2) + sqrt(-3/16*(2^
(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1))*log(-1/4*(
(sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4) - sqrt(2))^2 + sqrt(2)*(2^(3/4) + sqrt(2))^2 - (sqrt(2)*(2^(3
/4) + sqrt(2))^2 - 4*sqrt(2))*(2^(3/4) - sqrt(2)) + 4*sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2
))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1)*((sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4) - s
qrt(2)) - sqrt(2)*(2^(3/4) + sqrt(2)) - 4*sqrt(2)) - 4*sqrt(2)*(2^(3/4) + sqrt(2)) + 4*sqrt(2))*sqrt(1/2*sqrt(
2) + sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))
^2 + 1)) + 6*x) - 1/16*sqrt(2)*sqrt(1/2*sqrt(2) - sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(
2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1))*log(1/4*((sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4
) - sqrt(2))^2 + sqrt(2)*(2^(3/4) + sqrt(2))^2 - (sqrt(2)*(2^(3/4) + sqrt(2))^2 - 4*sqrt(2))*(2^(3/4) - sqrt(2
)) - 4*sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2
))^2 + 1)*((sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4) - sqrt(2)) - sqrt(2)*(2^(3/4) + sqrt(2)) - 4*sqrt(
2)) - 4*sqrt(2)*(2^(3/4) + sqrt(2)) + 4*sqrt(2))*sqrt(1/2*sqrt(2) - sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^
(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1)) + 6*x) + 1/16*sqrt(2)*sqrt(1/2*sqrt(2)
- sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2
+ 1))*log(-1/4*((sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt(2))*(2^(3/4) - sqrt(2))^2 + sqrt(2)*(2^(3/4) + sqrt(2))^2
- (sqrt(2)*(2^(3/4) + sqrt(2))^2 - 4*sqrt(2))*(2^(3/4) - sqrt(2)) - 4*sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*
(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2^(3/4) - sqrt(2))^2 + 1)*((sqrt(2)*(2^(3/4) + sqrt(2)) + sqrt
(2))*(2^(3/4) - sqrt(2)) - sqrt(2)*(2^(3/4) + sqrt(2)) - 4*sqrt(2)) - 4*sqrt(2)*(2^(3/4) + sqrt(2)) + 4*sqrt(2
))*sqrt(1/2*sqrt(2) - sqrt(-3/16*(2^(3/4) + sqrt(2))^2 + 1/8*(2^(3/4) + sqrt(2))*(2^(3/4) - sqrt(2)) - 3/16*(2
^(3/4) - sqrt(2))^2 + 1)) + 6*x) + 1/16*sqrt(2^(3/4) - sqrt(2))*log(1/4*((2^(3/4) + sqrt(2))^3 + (2^(3/4) + sq
rt(2) + 1)*(2^(3/4) - sqrt(2))^2 - ((2^(3/4) + sqrt(2))^2 - 4)*(2^(3/4) - sqrt(2)) - 4*2^(3/4) - 4*sqrt(2) - 6
)*sqrt(2^(3/4) - sqrt(2)) + 3*x) - 1/16*sqrt(2^(3/4) - sqrt(2))*log(-1/4*((2^(3/4) + sqrt(2))^3 + (2^(3/4) + s
qrt(2) + 1)*(2^(3/4) - sqrt(2))^2 - ((2^(3/4) + sqrt(2))^2 - 4)*(2^(3/4) - sqrt(2)) - 4*2^(3/4) - 4*sqrt(2) -
6)*sqrt(2^(3/4) - sqrt(2)) + 3*x) - sqrt(-1/256*2^(3/4) - 1/256*sqrt(2))*log(4*((2^(3/4) + sqrt(2))^3 - (2^(3/
4) + sqrt(2))^2 - 10)*sqrt(-1/256*2^(3/4) - 1/256*sqrt(2)) + 3*x) + sqrt(-1/256*2^(3/4) - 1/256*sqrt(2))*log(-
4*((2^(3/4) + sqrt(2))^3 - (2^(3/4) + sqrt(2))^2 - 10)*sqrt(-1/256*2^(3/4) - 1/256*sqrt(2)) + 3*x)
Sympy [A] (verification not implemented)
Time = 0.12 (sec) , antiderivative size = 41, normalized size of antiderivative = 0.26
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=- \operatorname {RootSum} {\left (1073741824 t^{8} - 65536 t^{4} + 1024 t^{2} - 1, \left ( t \mapsto t \log {\left (- \frac {67108864 t^{7}}{3} - \frac {262144 t^{5}}{3} - \frac {40 t}{3} + x \right )} \right )\right )}
\]
[In]
integrate(x**2/(2-(x**2+1)**4),x)
[Out]
-RootSum(1073741824*_t**8 - 65536*_t**4 + 1024*_t**2 - 1, Lambda(_t, _t*log(-67108864*_t**7/3 - 262144*_t**5/3
- 40*_t/3 + x)))
Maxima [F]
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=\int { -\frac {x^{2}}{{\left (x^{2} + 1\right )}^{4} - 2} \,d x }
\]
[In]
integrate(x^2/(2-(x^2+1)^4),x, algorithm="maxima")
[Out]
-integrate(x^2/((x^2 + 1)^4 - 2), x)
Giac [F]
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=\int { -\frac {x^{2}}{{\left (x^{2} + 1\right )}^{4} - 2} \,d x }
\]
[In]
integrate(x^2/(2-(x^2+1)^4),x, algorithm="giac")
[Out]
integrate(-x^2/((x^2 + 1)^4 - 2), x)
Mupad [B] (verification not implemented)
Time = 9.91 (sec) , antiderivative size = 144, normalized size of antiderivative = 0.92
\[
\int \frac {x^2}{2-\left (1+x^2\right )^4} \, dx=\sum _{k=1}^8\ln \left (-\mathrm {root}\left (z^8-\frac {z^4}{16384}+\frac {z^2}{1048576}-\frac {1}{1073741824},z,k\right )\,\left (56\,x-\mathrm {root}\left (z^8-\frac {z^4}{16384}+\frac {z^2}{1048576}-\frac {1}{1073741824},z,k\right )\,\left (\mathrm {root}\left (z^8-\frac {z^4}{16384}+\frac {z^2}{1048576}-\frac {1}{1073741824},z,k\right )\,\left (4096\,x-{\mathrm {root}\left (z^8-\frac {z^4}{16384}+\frac {z^2}{1048576}-\frac {1}{1073741824},z,k\right )}^2\,\left (262144\,x+{\mathrm {root}\left (z^8-\frac {z^4}{16384}+\frac {z^2}{1048576}-\frac {1}{1073741824},z,k\right )}^2\,x\,67108864\right )\right )+256\right )\right )-1\right )\,\mathrm {root}\left (z^8-\frac {z^4}{16384}+\frac {z^2}{1048576}-\frac {1}{1073741824},z,k\right )
\]
[In]
int(-x^2/((x^2 + 1)^4 - 2),x)
[Out]
symsum(log(- root(z^8 - z^4/16384 + z^2/1048576 - 1/1073741824, z, k)*(56*x - root(z^8 - z^4/16384 + z^2/10485
76 - 1/1073741824, z, k)*(root(z^8 - z^4/16384 + z^2/1048576 - 1/1073741824, z, k)*(4096*x - root(z^8 - z^4/16
384 + z^2/1048576 - 1/1073741824, z, k)^2*(262144*x + 67108864*root(z^8 - z^4/16384 + z^2/1048576 - 1/10737418
24, z, k)^2*x)) + 256)) - 1)*root(z^8 - z^4/16384 + z^2/1048576 - 1/1073741824, z, k), k, 1, 8)