3.43 \(\int \frac {1}{1+4 x^2+x^4} \, dx\)

Optimal. Leaf size=67 \[ \frac {\tan ^{-1}\left (\frac {x}{\sqrt {2-\sqrt {3}}}\right )}{2 \sqrt {3 \left (2-\sqrt {3}\right )}}-\frac {\tan ^{-1}\left (\frac {x}{\sqrt {2+\sqrt {3}}}\right )}{2 \sqrt {3 \left (2+\sqrt {3}\right )}} \]

[Out]

1/2*arctan(x/(1/2*6^(1/2)-1/2*2^(1/2)))/(3/2*2^(1/2)-1/2*6^(1/2))-1/2*arctan(x/(1/2*6^(1/2)+1/2*2^(1/2)))/(3/2
*2^(1/2)+1/2*6^(1/2))

________________________________________________________________________________________

Rubi [A]  time = 0.01, antiderivative size = 67, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {1093, 203} \[ \frac {\tan ^{-1}\left (\frac {x}{\sqrt {2-\sqrt {3}}}\right )}{2 \sqrt {3 \left (2-\sqrt {3}\right )}}-\frac {\tan ^{-1}\left (\frac {x}{\sqrt {2+\sqrt {3}}}\right )}{2 \sqrt {3 \left (2+\sqrt {3}\right )}} \]

Antiderivative was successfully verified.

[In]

Int[(1 + 4*x^2 + x^4)^(-1),x]

[Out]

ArcTan[x/Sqrt[2 - Sqrt[3]]]/(2*Sqrt[3*(2 - Sqrt[3])]) - ArcTan[x/Sqrt[2 + Sqrt[3]]]/(2*Sqrt[3*(2 + Sqrt[3])])

Rule 203

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTan[(Rt[b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 1093

Int[((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(-1), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Dist[c/q, Int[1/(b/
2 - q/2 + c*x^2), x], x] - Dist[c/q, Int[1/(b/2 + q/2 + c*x^2), x], x]] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*
a*c, 0] && PosQ[b^2 - 4*a*c]

Rubi steps

\begin {align*} \int \frac {1}{1+4 x^2+x^4} \, dx &=\frac {\int \frac {1}{2-\sqrt {3}+x^2} \, dx}{2 \sqrt {3}}-\frac {\int \frac {1}{2+\sqrt {3}+x^2} \, dx}{2 \sqrt {3}}\\ &=\frac {\tan ^{-1}\left (\frac {x}{\sqrt {2-\sqrt {3}}}\right )}{2 \sqrt {3 \left (2-\sqrt {3}\right )}}-\frac {\tan ^{-1}\left (\frac {x}{\sqrt {2+\sqrt {3}}}\right )}{2 \sqrt {3 \left (2+\sqrt {3}\right )}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 67, normalized size = 1.00 \[ \frac {\tan ^{-1}\left (\frac {x}{\sqrt {2-\sqrt {3}}}\right )}{2 \sqrt {3 \left (2-\sqrt {3}\right )}}-\frac {\tan ^{-1}\left (\frac {x}{\sqrt {2+\sqrt {3}}}\right )}{2 \sqrt {3 \left (2+\sqrt {3}\right )}} \]

Antiderivative was successfully verified.

[In]

Integrate[(1 + 4*x^2 + x^4)^(-1),x]

[Out]

ArcTan[x/Sqrt[2 - Sqrt[3]]]/(2*Sqrt[3*(2 - Sqrt[3])]) - ArcTan[x/Sqrt[2 + Sqrt[3]]]/(2*Sqrt[3*(2 + Sqrt[3])])

________________________________________________________________________________________

fricas [A]  time = 0.44, size = 87, normalized size = 1.30 \[ -\frac {1}{3} \, \sqrt {3} \sqrt {\sqrt {3} + 2} \arctan \left (-{\left (x - \sqrt {x^{2} - \sqrt {3} + 2}\right )} \sqrt {\sqrt {3} + 2}\right ) + \frac {1}{3} \, \sqrt {3} \sqrt {-\sqrt {3} + 2} \arctan \left (-x \sqrt {-\sqrt {3} + 2} + \sqrt {x^{2} + \sqrt {3} + 2} \sqrt {-\sqrt {3} + 2}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/3*sqrt(3)*sqrt(sqrt(3) + 2)*arctan(-(x - sqrt(x^2 - sqrt(3) + 2))*sqrt(sqrt(3) + 2)) + 1/3*sqrt(3)*sqrt(-sq
rt(3) + 2)*arctan(-x*sqrt(-sqrt(3) + 2) + sqrt(x^2 + sqrt(3) + 2)*sqrt(-sqrt(3) + 2))

________________________________________________________________________________________

giac [A]  time = 1.15, size = 51, normalized size = 0.76 \[ \frac {1}{12} \, {\left (\sqrt {6} - 3 \, \sqrt {2}\right )} \arctan \left (\frac {2 \, x}{\sqrt {6} + \sqrt {2}}\right ) + \frac {1}{12} \, {\left (\sqrt {6} + 3 \, \sqrt {2}\right )} \arctan \left (\frac {2 \, x}{\sqrt {6} - \sqrt {2}}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/12*(sqrt(6) - 3*sqrt(2))*arctan(2*x/(sqrt(6) + sqrt(2))) + 1/12*(sqrt(6) + 3*sqrt(2))*arctan(2*x/(sqrt(6) -
sqrt(2)))

________________________________________________________________________________________

maple [A]  time = 0.04, size = 60, normalized size = 0.90 \[ \frac {\sqrt {3}\, \arctan \left (\frac {2 x}{\sqrt {6}-\sqrt {2}}\right )}{3 \sqrt {6}-3 \sqrt {2}}-\frac {\sqrt {3}\, \arctan \left (\frac {2 x}{\sqrt {6}+\sqrt {2}}\right )}{3 \left (\sqrt {6}+\sqrt {2}\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(x^4+4*x^2+1),x)

[Out]

-1/3*3^(1/2)/(6^(1/2)+2^(1/2))*arctan(2/(6^(1/2)+2^(1/2))*x)+1/3*3^(1/2)/(6^(1/2)-2^(1/2))*arctan(2/(6^(1/2)-2
^(1/2))*x)

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {1}{x^{4} + 4 \, x^{2} + 1}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

integrate(1/(x^4 + 4*x^2 + 1), x)

________________________________________________________________________________________

mupad [B]  time = 0.20, size = 117, normalized size = 1.75 \[ 2\,\mathrm {atanh}\left (\frac {24\,x\,\sqrt {\frac {\sqrt {3}}{48}-\frac {1}{24}}}{2\,\sqrt {3}-4}-\frac {16\,\sqrt {3}\,x\,\sqrt {\frac {\sqrt {3}}{48}-\frac {1}{24}}}{2\,\sqrt {3}-4}\right )\,\sqrt {\frac {\sqrt {3}}{48}-\frac {1}{24}}-2\,\mathrm {atanh}\left (\frac {24\,x\,\sqrt {-\frac {\sqrt {3}}{48}-\frac {1}{24}}}{2\,\sqrt {3}+4}+\frac {16\,\sqrt {3}\,x\,\sqrt {-\frac {\sqrt {3}}{48}-\frac {1}{24}}}{2\,\sqrt {3}+4}\right )\,\sqrt {-\frac {\sqrt {3}}{48}-\frac {1}{24}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(4*x^2 + x^4 + 1),x)

[Out]

2*atanh((24*x*(3^(1/2)/48 - 1/24)^(1/2))/(2*3^(1/2) - 4) - (16*3^(1/2)*x*(3^(1/2)/48 - 1/24)^(1/2))/(2*3^(1/2)
 - 4))*(3^(1/2)/48 - 1/24)^(1/2) - 2*atanh((24*x*(- 3^(1/2)/48 - 1/24)^(1/2))/(2*3^(1/2) + 4) + (16*3^(1/2)*x*
(- 3^(1/2)/48 - 1/24)^(1/2))/(2*3^(1/2) + 4))*(- 3^(1/2)/48 - 1/24)^(1/2)

________________________________________________________________________________________

sympy [A]  time = 0.22, size = 92, normalized size = 1.37 \[ - 2 \sqrt {\frac {1}{24} - \frac {\sqrt {3}}{48}} \operatorname {atan}{\left (\frac {x}{\sqrt {3} \sqrt {2 - \sqrt {3}} + 2 \sqrt {2 - \sqrt {3}}} \right )} - 2 \sqrt {\frac {\sqrt {3}}{48} + \frac {1}{24}} \operatorname {atan}{\left (\frac {x}{- 2 \sqrt {\sqrt {3} + 2} + \sqrt {3} \sqrt {\sqrt {3} + 2}} \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/(x**4+4*x**2+1),x)

[Out]

-2*sqrt(1/24 - sqrt(3)/48)*atan(x/(sqrt(3)*sqrt(2 - sqrt(3)) + 2*sqrt(2 - sqrt(3)))) - 2*sqrt(sqrt(3)/48 + 1/2
4)*atan(x/(-2*sqrt(sqrt(3) + 2) + sqrt(3)*sqrt(sqrt(3) + 2)))

________________________________________________________________________________________