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

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

[Out]

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

________________________________________________________________________________________

Rubi [A]
time = 0.03, antiderivative size = 52, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.217, Rules used = {1986, 15, 455, 65, 209} \begin {gather*} \frac {\sqrt {-\frac {x^2}{1-x^2}} \sqrt {x^2-1} \text {ArcTan}\left (\frac {\sqrt {x^2-1}}{\sqrt {2}}\right )}{\sqrt {2} x} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 15

Int[(u_.)*((a_.)*(x_)^(n_))^(m_), x_Symbol] :> Dist[a^IntPart[m]*((a*x^n)^FracPart[m]/x^(n*FracPart[m])), Int[
u*x^(m*n), x], x] /; FreeQ[{a, m, n}, x] &&  !IntegerQ[m]

Rule 65

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[{p = Denominator[m]}, Dist[p/b, Sub
st[Int[x^(p*(m + 1) - 1)*(c - a*(d/b) + d*(x^p/b))^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] &
& NeQ[b*c - a*d, 0] && LtQ[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntLinearQ[a,
b, c, d, m, n, x]

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 455

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

Rule 1986

Int[(u_.)*((e_.)*((a_.) + (b_.)*(x_)^(n_.))^(q_.)*((c_) + (d_.)*(x_)^(n_))^(r_.))^(p_), x_Symbol] :> Dist[Simp
[(e*(a + b*x^n)^q*(c + d*x^n)^r)^p/((a + b*x^n)^(p*q)*(c + d*x^n)^(p*r))], Int[u*(a + b*x^n)^(p*q)*(c + d*x^n)
^(p*r), x], x] /; FreeQ[{a, b, c, d, e, n, p, q, r}, x]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]
time = 0.03, size = 49, normalized size = 0.94 \begin {gather*} \frac {\sqrt {\frac {x^2}{-1+x^2}} \sqrt {-1+x^2} \tan ^{-1}\left (\frac {\sqrt {-1+x^2}}{\sqrt {2}}\right )}{\sqrt {2} x} \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

Maple [A]
time = 0.20, size = 42, normalized size = 0.81

method result size
default \(\frac {\sqrt {\frac {x^{2}}{x^{2}-1}}\, \sqrt {x^{2}-1}\, \sqrt {2}\, \arctan \left (\frac {\sqrt {x^{2}-1}\, \sqrt {2}}{2}\right )}{2 x}\) \(42\)
trager \(-\frac {\RootOf \left (\textit {\_Z}^{2}+2\right ) \ln \left (\frac {\RootOf \left (\textit {\_Z}^{2}+2\right ) x^{3}+4 x^{2} \sqrt {\frac {x^{2}}{x^{2}-1}}-3 \RootOf \left (\textit {\_Z}^{2}+2\right ) x -4 \sqrt {\frac {x^{2}}{x^{2}-1}}}{x \left (x^{2}+1\right )}\right )}{4}\) \(74\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*(x^2/(x^2-1))^(1/2)/x*(x^2-1)^(1/2)*2^(1/2)*arctan(1/2*(x^2-1)^(1/2)*2^(1/2))

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]
time = 0.34, size = 32, normalized size = 0.62 \begin {gather*} \frac {1}{2} \, \sqrt {2} \arctan \left (\frac {\sqrt {2} {\left (x^{2} - 1\right )} \sqrt {\frac {x^{2}}{x^{2} - 1}}}{2 \, x}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*sqrt(2)*arctan(1/2*sqrt(2)*(x^2 - 1)*sqrt(x^2/(x^2 - 1))/x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\sqrt {\frac {x^{2}}{x^{2} - 1}}}{x^{2} + 1}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Giac [C] Result contains complex when optimal does not.
time = 3.97, size = 40, normalized size = 0.77 \begin {gather*} \frac {1}{2} \, \sqrt {2} \arctan \left (\frac {1}{2} \, \sqrt {2} \sqrt {x^{2} - 1}\right ) \mathrm {sgn}\left (x^{2} - 1\right ) \mathrm {sgn}\left (x\right ) + \frac {1}{2} \, \sqrt {2} \arctan \left (\frac {1}{2} i \, \sqrt {2}\right ) \mathrm {sgn}\left (x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*sqrt(2)*arctan(1/2*sqrt(2)*sqrt(x^2 - 1))*sgn(x^2 - 1)*sgn(x) + 1/2*sqrt(2)*arctan(1/2*I*sqrt(2))*sgn(x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} \int \frac {\sqrt {\frac {x^2}{x^2-1}}}{x^2+1} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________