3.655 \(\int \frac{-1+x^2}{\sqrt{a-b+\frac{b}{x^2}} x^3} \, dx\)

Optimal. Leaf size=58 \[ \frac{\sqrt{a-b \left (1-\frac{1}{x^2}\right )}}{b}+\frac{\tanh ^{-1}\left (\frac{\sqrt{a-b \left (1-\frac{1}{x^2}\right )}}{\sqrt{a-b}}\right )}{\sqrt{a-b}} \]

[Out]

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

_______________________________________________________________________________________

Rubi [A]  time = 0.206537, antiderivative size = 58, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.217 \[ \frac{\sqrt{a-b \left (1-\frac{1}{x^2}\right )}}{b}+\frac{\tanh ^{-1}\left (\frac{\sqrt{a-b \left (1-\frac{1}{x^2}\right )}}{\sqrt{a-b}}\right )}{\sqrt{a-b}} \]

Antiderivative was successfully verified.

[In]  Int[(-1 + x^2)/(Sqrt[a - b + b/x^2]*x^3),x]

[Out]

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

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 8.82937, size = 39, normalized size = 0.67 \[ \frac{\operatorname{atanh}{\left (\frac{\sqrt{a - b + \frac{b}{x^{2}}}}{\sqrt{a - b}} \right )}}{\sqrt{a - b}} + \frac{\sqrt{a - b + \frac{b}{x^{2}}}}{b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((x**2-1)/x**3/(a-b+b/x**2)**(1/2),x)

[Out]

atanh(sqrt(a - b + b/x**2)/sqrt(a - b))/sqrt(a - b) + sqrt(a - b + b/x**2)/b

_______________________________________________________________________________________

Mathematica [A]  time = 0.121466, size = 109, normalized size = 1.88 \[ \frac{\sqrt{a-b} \left (a x^2-b x^2+b\right )+b x \sqrt{a x^2-b x^2+b} \log \left (\sqrt{a-b} \sqrt{a x^2-b x^2+b}+a x-b x\right )}{b x^2 \sqrt{a-b} \sqrt{a+b \left (\frac{1}{x^2}-1\right )}} \]

Antiderivative was successfully verified.

[In]  Integrate[(-1 + x^2)/(Sqrt[a - b + b/x^2]*x^3),x]

[Out]

(Sqrt[a - b]*(b + a*x^2 - b*x^2) + b*x*Sqrt[b + a*x^2 - b*x^2]*Log[a*x - b*x + S
qrt[a - b]*Sqrt[b + a*x^2 - b*x^2]])/(Sqrt[a - b]*b*Sqrt[a + b*(-1 + x^(-2))]*x^
2)

_______________________________________________________________________________________

Maple [B]  time = 0.027, size = 102, normalized size = 1.8 \[{\frac{1}{b{x}^{2}}\sqrt{a{x}^{2}-b{x}^{2}+b} \left ( \ln \left ( \sqrt{a-b}x+\sqrt{a{x}^{2}-b{x}^{2}+b} \right ) xb+\sqrt{a{x}^{2}-b{x}^{2}+b}\sqrt{a-b} \right ){\frac{1}{\sqrt{{\frac{a{x}^{2}-b{x}^{2}+b}{{x}^{2}}}}}}{\frac{1}{\sqrt{a-b}}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((x^2-1)/x^3/(a-b+b/x^2)^(1/2),x)

[Out]

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

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \text{Exception raised: ValueError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 - 1)/(sqrt(a - b + b/x^2)*x^3),x, algorithm="maxima")

[Out]

Exception raised: ValueError

_______________________________________________________________________________________

Fricas [A]  time = 0.283279, size = 1, normalized size = 0.02 \[ \left [\frac{\sqrt{a - b} b \log \left (-2 \,{\left (a - b\right )} x^{2} \sqrt{\frac{{\left (a - b\right )} x^{2} + b}{x^{2}}} -{\left (2 \,{\left (a - b\right )} x^{2} + b\right )} \sqrt{a - b}\right ) + 2 \,{\left (a - b\right )} \sqrt{\frac{{\left (a - b\right )} x^{2} + b}{x^{2}}}}{2 \,{\left (a b - b^{2}\right )}}, -\frac{\sqrt{-a + b} b \arctan \left (\frac{\sqrt{-a + b}}{\sqrt{\frac{{\left (a - b\right )} x^{2} + b}{x^{2}}}}\right ) -{\left (a - b\right )} \sqrt{\frac{{\left (a - b\right )} x^{2} + b}{x^{2}}}}{a b - b^{2}}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 - 1)/(sqrt(a - b + b/x^2)*x^3),x, algorithm="fricas")

[Out]

[1/2*(sqrt(a - b)*b*log(-2*(a - b)*x^2*sqrt(((a - b)*x^2 + b)/x^2) - (2*(a - b)*
x^2 + b)*sqrt(a - b)) + 2*(a - b)*sqrt(((a - b)*x^2 + b)/x^2))/(a*b - b^2), -(sq
rt(-a + b)*b*arctan(sqrt(-a + b)/sqrt(((a - b)*x^2 + b)/x^2)) - (a - b)*sqrt(((a
 - b)*x^2 + b)/x^2))/(a*b - b^2)]

_______________________________________________________________________________________

Sympy [A]  time = 7.3092, size = 53, normalized size = 0.91 \[ - \begin{cases} - \frac{1}{2 \sqrt{a} x^{2}} & \text{for}\: b = 0 \\- \frac{\sqrt{a - b + \frac{b}{x^{2}}}}{b} & \text{otherwise} \end{cases} + \frac{\operatorname{asinh}{\left (\frac{x \sqrt{\operatorname{polar\_lift}{\left (a - b \right )}}}{\sqrt{b}} \right )}}{\sqrt{\operatorname{polar\_lift}{\left (a - b \right )}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x**2-1)/x**3/(a-b+b/x**2)**(1/2),x)

[Out]

-Piecewise((-1/(2*sqrt(a)*x**2), Eq(b, 0)), (-sqrt(a - b + b/x**2)/b, True)) + a
sinh(x*sqrt(polar_lift(a - b))/sqrt(b))/sqrt(polar_lift(a - b))

_______________________________________________________________________________________

GIAC/XCAS [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{x^{2} - 1}{\sqrt{a - b + \frac{b}{x^{2}}} x^{3}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((x^2 - 1)/(sqrt(a - b + b/x^2)*x^3),x, algorithm="giac")

[Out]

integrate((x^2 - 1)/(sqrt(a - b + b/x^2)*x^3), x)