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

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

Optimal result

Integrand size = 20, antiderivative size = 9 \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {1}{\sqrt {1+\frac {1}{x^2}}} \]

[Out]

1/(1+1/x^2)^(1/2)

Rubi [A] (verified)

Time = 0.00 (sec) , antiderivative size = 9, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {25, 267} \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {1}{\sqrt {\frac {1}{x^2}+1}} \]

[In]

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

[Out]

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

Rule 25

Int[(u_.)*((a_) + (b_.)*(x_)^(n_.))^(m_.)*((c_) + (d_.)*(x_)^(q_.))^(p_.), x_Symbol] :> Dist[(d/a)^p, Int[u*((
a + b*x^n)^(m + p)/x^(n*p)), x], x] /; FreeQ[{a, b, c, d, m, n}, x] && EqQ[q, -n] && IntegerQ[p] && EqQ[a*c -
b*d, 0] &&  !(IntegerQ[m] && NegQ[n])

Rule 267

Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(a + b*x^n)^(p + 1)/(b*n*(p + 1)), x] /; FreeQ
[{a, b, m, n, p}, x] && EqQ[m, n - 1] && NeQ[p, -1]

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

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(20\) vs. \(2(9)=18\).

Time = 0.00 (sec) , antiderivative size = 20, normalized size of antiderivative = 2.22 \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {\sqrt {1+\frac {1}{x^2}} x^2}{1+x^2} \]

[In]

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

[Out]

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

Maple [A] (verified)

Time = 1.00 (sec) , antiderivative size = 12, normalized size of antiderivative = 1.33

method result size
gosper \(\frac {1}{\sqrt {\frac {x^{2}+1}{x^{2}}}}\) \(12\)
default \(\frac {1}{\sqrt {\frac {x^{2}+1}{x^{2}}}}\) \(12\)
risch \(\frac {1}{\sqrt {\frac {x^{2}+1}{x^{2}}}}\) \(12\)
trager \(\frac {x^{2} \sqrt {-\frac {-x^{2}-1}{x^{2}}}}{x^{2}+1}\) \(26\)

[In]

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

[Out]

1/((x^2+1)/x^2)^(1/2)

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 28 vs. \(2 (7) = 14\).

Time = 0.27 (sec) , antiderivative size = 28, normalized size of antiderivative = 3.11 \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {x^{2} \sqrt {\frac {x^{2} + 1}{x^{2}}} + x^{2} + 1}{x^{2} + 1} \]

[In]

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

[Out]

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

Sympy [A] (verification not implemented)

Time = 1.40 (sec) , antiderivative size = 10, normalized size of antiderivative = 1.11 \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {1}{\sqrt {1 + \frac {1}{x^{2}}}} \]

[In]

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

[Out]

1/sqrt(1 + x**(-2))

Maxima [F]

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

[In]

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

[Out]

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

Giac [A] (verification not implemented)

none

Time = 0.38 (sec) , antiderivative size = 13, normalized size of antiderivative = 1.44 \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {x}{\sqrt {x^{2} + 1} \mathrm {sgn}\left (x\right )} \]

[In]

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

[Out]

x/(sqrt(x^2 + 1)*sgn(x))

Mupad [B] (verification not implemented)

Time = 18.37 (sec) , antiderivative size = 18, normalized size of antiderivative = 2.00 \[ \int \frac {1}{\sqrt {1+\frac {1}{x^2}} x \left (1+x^2\right )} \, dx=\frac {x^2\,\sqrt {\frac {1}{x^2}+1}}{x^2+1} \]

[In]

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

[Out]

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