\(\int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx\) [843]

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

Optimal result

Integrand size = 46, antiderivative size = 63 \[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=-\frac {2 \sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {x+\sqrt {1+x^2}}}-2 \text {arctanh}\left (\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}\right ) \]

[Out]

-2*(1+(x+(x^2+1)^(1/2))^(1/2))^(1/2)/(x+(x^2+1)^(1/2))^(1/2)-2*arctanh((1+(x+(x^2+1)^(1/2))^(1/2))^(1/2))

Rubi [F]

\[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=\int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx \]

[In]

Int[Sqrt[1 + Sqrt[x + Sqrt[1 + x^2]]]/(Sqrt[1 + x^2]*Sqrt[x + Sqrt[1 + x^2]]),x]

[Out]

Defer[Int][Sqrt[1 + Sqrt[x + Sqrt[1 + x^2]]]/(Sqrt[1 + x^2]*Sqrt[x + Sqrt[1 + x^2]]), x]

Rubi steps \begin{align*} \text {integral}& = \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx \\ \end{align*}

Mathematica [A] (verified)

Time = 0.11 (sec) , antiderivative size = 63, normalized size of antiderivative = 1.00 \[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=-\frac {2 \sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {x+\sqrt {1+x^2}}}-2 \text {arctanh}\left (\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}\right ) \]

[In]

Integrate[Sqrt[1 + Sqrt[x + Sqrt[1 + x^2]]]/(Sqrt[1 + x^2]*Sqrt[x + Sqrt[1 + x^2]]),x]

[Out]

(-2*Sqrt[1 + Sqrt[x + Sqrt[1 + x^2]]])/Sqrt[x + Sqrt[1 + x^2]] - 2*ArcTanh[Sqrt[1 + Sqrt[x + Sqrt[1 + x^2]]]]

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(134\) vs. \(2(47)=94\).

Time = 0.86 (sec) , antiderivative size = 135, normalized size of antiderivative = 2.14

method result size
derivativedivides \(-\frac {\sqrt {\left (1+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}\right ) \sqrt {x +\sqrt {x^{2}+1}}}\, \left (2 \sqrt {\frac {1}{x +\sqrt {x^{2}+1}}+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}}+\ln \left (\frac {1}{2}+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}+\sqrt {\frac {1}{x +\sqrt {x^{2}+1}}+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}}\right )\right )}{\sqrt {x +\sqrt {x^{2}+1}}\, \sqrt {\frac {1+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}}{\sqrt {x +\sqrt {x^{2}+1}}}}}\) \(135\)
default \(-\frac {\sqrt {\left (1+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}\right ) \sqrt {x +\sqrt {x^{2}+1}}}\, \left (2 \sqrt {\frac {1}{x +\sqrt {x^{2}+1}}+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}}+\ln \left (\frac {1}{2}+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}+\sqrt {\frac {1}{x +\sqrt {x^{2}+1}}+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}}\right )\right )}{\sqrt {x +\sqrt {x^{2}+1}}\, \sqrt {\frac {1+\frac {1}{\sqrt {x +\sqrt {x^{2}+1}}}}{\sqrt {x +\sqrt {x^{2}+1}}}}}\) \(135\)

[In]

int((1+(x+(x^2+1)^(1/2))^(1/2))^(1/2)/(x^2+1)^(1/2)/(x+(x^2+1)^(1/2))^(1/2),x,method=_RETURNVERBOSE)

[Out]

-((1+1/(x+(x^2+1)^(1/2))^(1/2))*(x+(x^2+1)^(1/2))^(1/2))^(1/2)/(x+(x^2+1)^(1/2))^(1/2)*(2*(1/(x+(x^2+1)^(1/2))
+1/(x+(x^2+1)^(1/2))^(1/2))^(1/2)+ln(1/2+1/(x+(x^2+1)^(1/2))^(1/2)+(1/(x+(x^2+1)^(1/2))+1/(x+(x^2+1)^(1/2))^(1
/2))^(1/2)))/((1+1/(x+(x^2+1)^(1/2))^(1/2))/(x+(x^2+1)^(1/2))^(1/2))^(1/2)

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 78, normalized size of antiderivative = 1.24 \[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=2 \, \sqrt {x + \sqrt {x^{2} + 1}} {\left (x - \sqrt {x^{2} + 1}\right )} \sqrt {\sqrt {x + \sqrt {x^{2} + 1}} + 1} - \log \left (\sqrt {\sqrt {x + \sqrt {x^{2} + 1}} + 1} + 1\right ) + \log \left (\sqrt {\sqrt {x + \sqrt {x^{2} + 1}} + 1} - 1\right ) \]

[In]

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

[Out]

2*sqrt(x + sqrt(x^2 + 1))*(x - sqrt(x^2 + 1))*sqrt(sqrt(x + sqrt(x^2 + 1)) + 1) - log(sqrt(sqrt(x + sqrt(x^2 +
 1)) + 1) + 1) + log(sqrt(sqrt(x + sqrt(x^2 + 1)) + 1) - 1)

Sympy [F]

\[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=\int \frac {\sqrt {\sqrt {x + \sqrt {x^{2} + 1}} + 1}}{\sqrt {x + \sqrt {x^{2} + 1}} \sqrt {x^{2} + 1}}\, dx \]

[In]

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

[Out]

Integral(sqrt(sqrt(x + sqrt(x**2 + 1)) + 1)/(sqrt(x + sqrt(x**2 + 1))*sqrt(x**2 + 1)), x)

Maxima [F]

\[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=\int { \frac {\sqrt {\sqrt {x + \sqrt {x^{2} + 1}} + 1}}{\sqrt {x^{2} + 1} \sqrt {x + \sqrt {x^{2} + 1}}} \,d x } \]

[In]

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

[Out]

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

Giac [F(-1)]

Timed out. \[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=\text {Timed out} \]

[In]

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

[Out]

Timed out

Mupad [B] (verification not implemented)

Time = 6.65 (sec) , antiderivative size = 121, normalized size of antiderivative = 1.92 \[ \int \frac {\sqrt {1+\sqrt {x+\sqrt {1+x^2}}}}{\sqrt {1+x^2} \sqrt {x+\sqrt {1+x^2}}} \, dx=-\frac {2\,\sqrt {\sqrt {x+\sqrt {x^2+1}}+1}}{\sqrt {x+\sqrt {x^2+1}}}-\frac {\ln \left (\sqrt {\frac {1}{x+\sqrt {x^2+1}}+\frac {1}{\sqrt {x+\sqrt {x^2+1}}}}+\frac {1}{\sqrt {x+\sqrt {x^2+1}}}+\frac {1}{2}\right )\,\sqrt {\sqrt {x+\sqrt {x^2+1}}+1}}{\sqrt {x+\sqrt {x^2+1}}\,\sqrt {\frac {1}{x+\sqrt {x^2+1}}+\frac {1}{\sqrt {x+\sqrt {x^2+1}}}}} \]

[In]

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

[Out]

- (2*((x + (x^2 + 1)^(1/2))^(1/2) + 1)^(1/2))/(x + (x^2 + 1)^(1/2))^(1/2) - (log((1/(x + (x^2 + 1)^(1/2)) + 1/
(x + (x^2 + 1)^(1/2))^(1/2))^(1/2) + 1/(x + (x^2 + 1)^(1/2))^(1/2) + 1/2)*((x + (x^2 + 1)^(1/2))^(1/2) + 1)^(1
/2))/((x + (x^2 + 1)^(1/2))^(1/2)*(1/(x + (x^2 + 1)^(1/2)) + 1/(x + (x^2 + 1)^(1/2))^(1/2))^(1/2))