\(\int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx\) [372]

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

Optimal result

Integrand size = 58, antiderivative size = 46 \[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\frac {\sqrt {2} b \arcsin \left (\frac {a x-b \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}{\sqrt {a}}\right )}{\sqrt {a}} \] Output:

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

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(114\) vs. \(2(46)=92\).

Time = 6.79 (sec) , antiderivative size = 114, normalized size of antiderivative = 2.48 \[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\frac {\sqrt {2} b \sqrt {x \left (-a x+b \sqrt {\frac {a \left (1+a x^2\right )}{b^2}}\right )} \sqrt {a x \left (a x+b \sqrt {\frac {a \left (1+a x^2\right )}{b^2}}\right )} \arctan \left (\frac {\sqrt {2} \sqrt {a x \left (a x+b \sqrt {\frac {a \left (1+a x^2\right )}{b^2}}\right )}}{\sqrt {a}}\right )}{a^{3/2} x} \] Input:

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

Output:

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

Rubi [A] (verified)

Time = 1.02 (sec) , antiderivative size = 47, normalized size of antiderivative = 1.02, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.034, Rules used = {2555, 223}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

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

\(\Big \downarrow \) 2555

\(\displaystyle -\frac {\sqrt {2} b \int \frac {1}{\sqrt {1-\frac {\left (b \sqrt {\frac {a^2 x^2}{b^2}+\frac {a}{b^2}}-a x\right )^2}{a}}}d\left (b \sqrt {\frac {a^2 x^2}{b^2}+\frac {a}{b^2}}-a x\right )}{a}\)

\(\Big \downarrow \) 223

\(\displaystyle -\frac {\sqrt {2} b \arcsin \left (\frac {b \sqrt {\frac {a^2 x^2}{b^2}+\frac {a}{b^2}}-a x}{\sqrt {a}}\right )}{\sqrt {a}}\)

Input:

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

Output:

-((Sqrt[2]*b*ArcSin[(-(a*x) + b*Sqrt[a/b^2 + (a^2*x^2)/b^2])/Sqrt[a]])/Sqr 
t[a])
 

Defintions of rubi rules used

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

rule 2555
Int[Sqrt[(a_.)*(x_)^2 + (b_.)*(x_)*Sqrt[(c_) + (d_.)*(x_)^2]]/((x_)*Sqrt[(c 
_) + (d_.)*(x_)^2]), x_Symbol] :> Simp[Sqrt[2]*(b/a)   Subst[Int[1/Sqrt[1 + 
 x^2/a], x], x, a*x + b*Sqrt[c + d*x^2]], x] /; FreeQ[{a, b, c, d}, x] && E 
qQ[a^2 - b^2*d, 0] && EqQ[b^2*c + a, 0]
 
Maple [F]

\[\int \frac {\sqrt {-a \,x^{2}+b x \sqrt {\frac {a}{b^{2}}+\frac {a^{2} x^{2}}{b^{2}}}}}{x \sqrt {\frac {a}{b^{2}}+\frac {a^{2} x^{2}}{b^{2}}}}d x\]

Input:

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

Output:

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

Fricas [A] (verification not implemented)

Time = 5.04 (sec) , antiderivative size = 182, normalized size of antiderivative = 3.96 \[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\left [\frac {1}{2} \, \sqrt {2} b \sqrt {-\frac {1}{a}} \log \left (4 \, a x^{2} - 4 \, b x \sqrt {\frac {a^{2} x^{2} + a}{b^{2}}} + 2 \, \sqrt {-a x^{2} + b x \sqrt {\frac {a^{2} x^{2} + a}{b^{2}}}} {\left (\sqrt {2} a x \sqrt {-\frac {1}{a}} - \sqrt {2} b \sqrt {-\frac {1}{a}} \sqrt {\frac {a^{2} x^{2} + a}{b^{2}}}\right )} + 1\right ), \frac {\sqrt {2} b \arctan \left (\sqrt {-a x^{2} + b x \sqrt {\frac {a^{2} x^{2} + a}{b^{2}}}} {\left (\sqrt {2} \sqrt {a} x + \frac {\sqrt {2} b \sqrt {\frac {a^{2} x^{2} + a}{b^{2}}}}{\sqrt {a}}\right )}\right )}{\sqrt {a}}\right ] \] Input:

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

Output:

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

Sympy [F]

\[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\int \frac {\sqrt {- x \left (a x - b \sqrt {\frac {a^{2} x^{2}}{b^{2}} + \frac {a}{b^{2}}}\right )}}{x \sqrt {\frac {a \left (a x^{2} + 1\right )}{b^{2}}}}\, dx \] Input:

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

Output:

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

Maxima [F]

\[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\int { \frac {\sqrt {-a x^{2} + \sqrt {\frac {a^{2} x^{2}}{b^{2}} + \frac {a}{b^{2}}} b x}}{\sqrt {\frac {a^{2} x^{2}}{b^{2}} + \frac {a}{b^{2}}} x} \,d x } \] Input:

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

Output:

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

Giac [F]

\[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\int { \frac {\sqrt {-a x^{2} + \sqrt {\frac {a^{2} x^{2}}{b^{2}} + \frac {a}{b^{2}}} b x}}{\sqrt {\frac {a^{2} x^{2}}{b^{2}} + \frac {a}{b^{2}}} x} \,d x } \] Input:

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

Output:

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

Mupad [F(-1)]

Timed out. \[ \int \frac {\sqrt {-a x^2+b x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}}}{x \sqrt {\frac {a}{b^2}+\frac {a^2 x^2}{b^2}}} \, dx=\int \frac {\sqrt {b\,x\,\sqrt {\frac {a}{b^2}+\frac {a^2\,x^2}{b^2}}-a\,x^2}}{x\,\sqrt {\frac {a}{b^2}+\frac {a^2\,x^2}{b^2}}} \,d x \] Input:

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

Output:

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

Reduce [F]

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

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

Output:

(sqrt(a)*int((sqrt(a*x**2 + 1)*sqrt(sqrt(a)*sqrt(a*x**2 + 1) - a*x))/(sqrt 
(x)*a*x**2 + sqrt(x)),x)*b)/a