\(\int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx\) [144]

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

Optimal result

Integrand size = 24, antiderivative size = 115 \[ \int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx=\frac {\sqrt {a x+b x^2}}{b d}-\frac {(2 b c+a d) \text {arctanh}\left (\frac {\sqrt {b} x}{\sqrt {a x+b x^2}}\right )}{b^{3/2} d^2}+\frac {2 c^{3/2} \text {arctanh}\left (\frac {\sqrt {b c-a d} x}{\sqrt {c} \sqrt {a x+b x^2}}\right )}{d^2 \sqrt {b c-a d}} \] Output:

(b*x^2+a*x)^(1/2)/b/d-(a*d+2*b*c)*arctanh(b^(1/2)*x/(b*x^2+a*x)^(1/2))/b^( 
3/2)/d^2+2*c^(3/2)*arctanh((-a*d+b*c)^(1/2)*x/c^(1/2)/(b*x^2+a*x)^(1/2))/d 
^2/(-a*d+b*c)^(1/2)
 

Mathematica [C] (verified)

Result contains complex when optimal does not.

Time = 3.48 (sec) , antiderivative size = 431, normalized size of antiderivative = 3.75 \[ \int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx=\frac {\sqrt {x} \left (\sqrt {b} d \sqrt {x} (a+b x)+\frac {2 \sqrt {b} \sqrt {c} \left (-i \sqrt {a} \sqrt {d}+\sqrt {b c-a d}\right ) \sqrt {-b c+2 a d-2 i \sqrt {a} \sqrt {d} \sqrt {b c-a d}} \sqrt {a+b x} \arctan \left (\frac {\sqrt {-b c+2 a d-2 i \sqrt {a} \sqrt {d} \sqrt {b c-a d}} \sqrt {x}}{\sqrt {c} \left (\sqrt {a}-\sqrt {a+b x}\right )}\right )}{\sqrt {b c-a d}}+\frac {2 \sqrt {b} \sqrt {c} \left (i \sqrt {a} \sqrt {d}+\sqrt {b c-a d}\right ) \sqrt {-b c+2 a d+2 i \sqrt {a} \sqrt {d} \sqrt {b c-a d}} \sqrt {a+b x} \arctan \left (\frac {\sqrt {-b c+2 a d+2 i \sqrt {a} \sqrt {d} \sqrt {b c-a d}} \sqrt {x}}{\sqrt {c} \left (\sqrt {a}-\sqrt {a+b x}\right )}\right )}{\sqrt {b c-a d}}+2 (2 b c+a d) \sqrt {a+b x} \text {arctanh}\left (\frac {\sqrt {b} \sqrt {x}}{\sqrt {a}-\sqrt {a+b x}}\right )\right )}{b^{3/2} d^2 \sqrt {x (a+b x)}} \] Input:

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

Output:

(Sqrt[x]*(Sqrt[b]*d*Sqrt[x]*(a + b*x) + (2*Sqrt[b]*Sqrt[c]*((-I)*Sqrt[a]*S 
qrt[d] + Sqrt[b*c - a*d])*Sqrt[-(b*c) + 2*a*d - (2*I)*Sqrt[a]*Sqrt[d]*Sqrt 
[b*c - a*d]]*Sqrt[a + b*x]*ArcTan[(Sqrt[-(b*c) + 2*a*d - (2*I)*Sqrt[a]*Sqr 
t[d]*Sqrt[b*c - a*d]]*Sqrt[x])/(Sqrt[c]*(Sqrt[a] - Sqrt[a + b*x]))])/Sqrt[ 
b*c - a*d] + (2*Sqrt[b]*Sqrt[c]*(I*Sqrt[a]*Sqrt[d] + Sqrt[b*c - a*d])*Sqrt 
[-(b*c) + 2*a*d + (2*I)*Sqrt[a]*Sqrt[d]*Sqrt[b*c - a*d]]*Sqrt[a + b*x]*Arc 
Tan[(Sqrt[-(b*c) + 2*a*d + (2*I)*Sqrt[a]*Sqrt[d]*Sqrt[b*c - a*d]]*Sqrt[x]) 
/(Sqrt[c]*(Sqrt[a] - Sqrt[a + b*x]))])/Sqrt[b*c - a*d] + 2*(2*b*c + a*d)*S 
qrt[a + b*x]*ArcTanh[(Sqrt[b]*Sqrt[x])/(Sqrt[a] - Sqrt[a + b*x])]))/(b^(3/ 
2)*d^2*Sqrt[x*(a + b*x)])
 

Rubi [A] (verified)

Time = 0.48 (sec) , antiderivative size = 156, normalized size of antiderivative = 1.36, number of steps used = 9, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.333, Rules used = {1261, 113, 27, 175, 65, 104, 219, 221}

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 {x^2}{\sqrt {a x+b x^2} (c+d x)} \, dx\)

\(\Big \downarrow \) 1261

\(\displaystyle \frac {\sqrt {x} \sqrt {a+b x} \int \frac {x^{3/2}}{\sqrt {a+b x} (c+d x)}dx}{\sqrt {a x+b x^2}}\)

\(\Big \downarrow \) 113

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 175

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

\(\Big \downarrow \) 65

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

\(\Big \downarrow \) 104

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

\(\Big \downarrow \) 219

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

\(\Big \downarrow \) 221

\(\displaystyle \frac {\sqrt {x} \sqrt {a+b x} \left (\frac {\sqrt {x} \sqrt {a+b x}}{b d}-\frac {\frac {2 \text {arctanh}\left (\frac {\sqrt {b} \sqrt {x}}{\sqrt {a+b x}}\right ) (a d+2 b c)}{\sqrt {b} d}-\frac {4 b c^{3/2} \text {arctanh}\left (\frac {\sqrt {x} \sqrt {b c-a d}}{\sqrt {c} \sqrt {a+b x}}\right )}{d \sqrt {b c-a d}}}{2 b d}\right )}{\sqrt {a x+b x^2}}\)

Input:

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

Output:

(Sqrt[x]*Sqrt[a + b*x]*((Sqrt[x]*Sqrt[a + b*x])/(b*d) - ((2*(2*b*c + a*d)* 
ArcTanh[(Sqrt[b]*Sqrt[x])/Sqrt[a + b*x]])/(Sqrt[b]*d) - (4*b*c^(3/2)*ArcTa 
nh[(Sqrt[b*c - a*d]*Sqrt[x])/(Sqrt[c]*Sqrt[a + b*x])])/(d*Sqrt[b*c - a*d]) 
)/(2*b*d)))/Sqrt[a*x + b*x^2]
 

Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 65
Int[1/(Sqrt[(b_.)*(x_)]*Sqrt[(c_) + (d_.)*(x_)]), x_Symbol] :> Simp[2   Sub 
st[Int[1/(b - d*x^2), x], x, Sqrt[b*x]/Sqrt[c + d*x]], x] /; FreeQ[{b, c, d 
}, x] &&  !GtQ[c, 0]
 

rule 104
Int[(((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_))/((e_.) + (f_.)*(x 
_)), x_] :> With[{q = Denominator[m]}, Simp[q   Subst[Int[x^(q*(m + 1) - 1) 
/(b*e - a*f - (d*e - c*f)*x^q), x], x, (a + b*x)^(1/q)/(c + d*x)^(1/q)], x] 
] /; FreeQ[{a, b, c, d, e, f}, x] && EqQ[m + n + 1, 0] && RationalQ[n] && L 
tQ[-1, m, 0] && SimplerQ[a + b*x, c + d*x]
 

rule 113
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) 
)^(p_), x_] :> Simp[b*(a + b*x)^(m - 1)*(c + d*x)^(n + 1)*((e + f*x)^(p + 1 
)/(d*f*(m + n + p + 1))), x] + Simp[1/(d*f*(m + n + p + 1))   Int[(a + b*x) 
^(m - 2)*(c + d*x)^n*(e + f*x)^p*Simp[a^2*d*f*(m + n + p + 1) - b*(b*c*e*(m 
 - 1) + a*(d*e*(n + 1) + c*f*(p + 1))) + b*(a*d*f*(2*m + n + p) - b*(d*e*(m 
 + n) + c*f*(m + p)))*x, x], x], x] /; FreeQ[{a, b, c, d, e, f, n, p}, x] & 
& GtQ[m, 1] && NeQ[m + n + p + 1, 0] && IntegersQ[2*m, 2*n, 2*p]
 

rule 175
Int[(((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_))^(p_)*((g_.) + (h_.)*(x_ 
)))/((a_.) + (b_.)*(x_)), x_] :> Simp[h/b   Int[(c + d*x)^n*(e + f*x)^p, x] 
, x] + Simp[(b*g - a*h)/b   Int[(c + d*x)^n*((e + f*x)^p/(a + b*x)), x], x] 
 /; FreeQ[{a, b, c, d, e, f, g, h, n, p}, x]
 

rule 219
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[-b, 2]))* 
ArcTanh[Rt[-b, 2]*(x/Rt[a, 2])], x] /; FreeQ[{a, b}, x] && NegQ[a/b] && (Gt 
Q[a, 0] || LtQ[b, 0])
 

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

rule 1261
Int[((e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((b_.)*(x_) + (c_.)*(x_)^2) 
^(p_), x_Symbol] :> Simp[(e*x)^m*((b*x + c*x^2)^p/(x^(m + p)*(b + c*x)^p)) 
  Int[x^(m + p)*(f + g*x)^n*(b + c*x)^p, x], x] /; FreeQ[{b, c, e, f, g, m, 
 n}, x] &&  !IGtQ[n, 0]
 
Maple [A] (verified)

Time = 0.64 (sec) , antiderivative size = 95, normalized size of antiderivative = 0.83

method result size
pseudoelliptic \(-\frac {-\frac {d \sqrt {x \left (b x +a \right )}}{b}+\frac {\left (a d +2 b c \right ) \operatorname {arctanh}\left (\frac {\sqrt {x \left (b x +a \right )}}{x \sqrt {b}}\right )}{b^{\frac {3}{2}}}+\frac {2 c^{2} \arctan \left (\frac {\sqrt {x \left (b x +a \right )}\, c}{x \sqrt {c \left (a d -b c \right )}}\right )}{\sqrt {c \left (a d -b c \right )}}}{d^{2}}\) \(95\)
risch \(\frac {x \left (b x +a \right )}{b d \sqrt {x \left (b x +a \right )}}-\frac {\frac {\left (a d +2 b c \right ) \ln \left (\frac {\frac {a}{2}+b x}{\sqrt {b}}+\sqrt {b \,x^{2}+a x}\right )}{d \sqrt {b}}+\frac {2 c^{2} b \ln \left (\frac {-\frac {2 c \left (a d -b c \right )}{d^{2}}+\frac {\left (a d -2 b c \right ) \left (x +\frac {c}{d}\right )}{d}+2 \sqrt {-\frac {c \left (a d -b c \right )}{d^{2}}}\, \sqrt {b \left (x +\frac {c}{d}\right )^{2}+\frac {\left (a d -2 b c \right ) \left (x +\frac {c}{d}\right )}{d}-\frac {c \left (a d -b c \right )}{d^{2}}}}{x +\frac {c}{d}}\right )}{d^{2} \sqrt {-\frac {c \left (a d -b c \right )}{d^{2}}}}}{2 b d}\) \(207\)
default \(\frac {\frac {\sqrt {b \,x^{2}+a x}}{b}-\frac {a \ln \left (\frac {\frac {a}{2}+b x}{\sqrt {b}}+\sqrt {b \,x^{2}+a x}\right )}{2 b^{\frac {3}{2}}}}{d}-\frac {c^{2} \ln \left (\frac {-\frac {2 c \left (a d -b c \right )}{d^{2}}+\frac {\left (a d -2 b c \right ) \left (x +\frac {c}{d}\right )}{d}+2 \sqrt {-\frac {c \left (a d -b c \right )}{d^{2}}}\, \sqrt {b \left (x +\frac {c}{d}\right )^{2}+\frac {\left (a d -2 b c \right ) \left (x +\frac {c}{d}\right )}{d}-\frac {c \left (a d -b c \right )}{d^{2}}}}{x +\frac {c}{d}}\right )}{d^{3} \sqrt {-\frac {c \left (a d -b c \right )}{d^{2}}}}-\frac {c \ln \left (\frac {\frac {a}{2}+b x}{\sqrt {b}}+\sqrt {b \,x^{2}+a x}\right )}{d^{2} \sqrt {b}}\) \(219\)

Input:

int(x^2/(d*x+c)/(b*x^2+a*x)^(1/2),x,method=_RETURNVERBOSE)
 

Output:

-1/d^2*(-d*(x*(b*x+a))^(1/2)/b+(a*d+2*b*c)/b^(3/2)*arctanh((x*(b*x+a))^(1/ 
2)/x/b^(1/2))+2*c^2/(c*(a*d-b*c))^(1/2)*arctan((x*(b*x+a))^(1/2)/x*c/(c*(a 
*d-b*c))^(1/2)))
 

Fricas [A] (verification not implemented)

Time = 0.10 (sec) , antiderivative size = 534, normalized size of antiderivative = 4.64 \[ \int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx=\left [\frac {2 \, b^{2} c \sqrt {\frac {c}{b c - a d}} \log \left (\frac {a c + {\left (2 \, b c - a d\right )} x + 2 \, \sqrt {b x^{2} + a x} {\left (b c - a d\right )} \sqrt {\frac {c}{b c - a d}}}{d x + c}\right ) + 2 \, \sqrt {b x^{2} + a x} b d + {\left (2 \, b c + a d\right )} \sqrt {b} \log \left (2 \, b x + a - 2 \, \sqrt {b x^{2} + a x} \sqrt {b}\right )}{2 \, b^{2} d^{2}}, \frac {4 \, b^{2} c \sqrt {-\frac {c}{b c - a d}} \arctan \left (-\frac {\sqrt {b x^{2} + a x} {\left (b c - a d\right )} \sqrt {-\frac {c}{b c - a d}}}{b c x + a c}\right ) + 2 \, \sqrt {b x^{2} + a x} b d + {\left (2 \, b c + a d\right )} \sqrt {b} \log \left (2 \, b x + a - 2 \, \sqrt {b x^{2} + a x} \sqrt {b}\right )}{2 \, b^{2} d^{2}}, \frac {b^{2} c \sqrt {\frac {c}{b c - a d}} \log \left (\frac {a c + {\left (2 \, b c - a d\right )} x + 2 \, \sqrt {b x^{2} + a x} {\left (b c - a d\right )} \sqrt {\frac {c}{b c - a d}}}{d x + c}\right ) + \sqrt {b x^{2} + a x} b d + {\left (2 \, b c + a d\right )} \sqrt {-b} \arctan \left (\frac {\sqrt {b x^{2} + a x} \sqrt {-b}}{b x + a}\right )}{b^{2} d^{2}}, \frac {2 \, b^{2} c \sqrt {-\frac {c}{b c - a d}} \arctan \left (-\frac {\sqrt {b x^{2} + a x} {\left (b c - a d\right )} \sqrt {-\frac {c}{b c - a d}}}{b c x + a c}\right ) + \sqrt {b x^{2} + a x} b d + {\left (2 \, b c + a d\right )} \sqrt {-b} \arctan \left (\frac {\sqrt {b x^{2} + a x} \sqrt {-b}}{b x + a}\right )}{b^{2} d^{2}}\right ] \] Input:

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

Output:

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

Sympy [F]

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

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

Output:

Integral(x**2/(sqrt(x*(a + b*x))*(c + d*x)), x)
 

Maxima [F(-2)]

Exception generated. \[ \int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx=\text {Exception raised: ValueError} \] Input:

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

Output:

Exception raised: ValueError >> Computation failed since Maxima requested 
additional constraints; using the 'assume' command before evaluation *may* 
 help (example of legal syntax is 'assume((a/d-(2*b*c)/d^2)^2>0)', see `as 
sume?` for
 

Giac [F(-2)]

Exception generated. \[ \int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx=\text {Exception raised: TypeError} \] Input:

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

Output:

Exception raised: TypeError >> an error occurred running a Giac command:IN 
PUT:sage2:=int(sage0,sageVARx):;OUTPUT:Error: Bad Argument Type
 

Mupad [F(-1)]

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

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

Output:

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

Reduce [B] (verification not implemented)

Time = 0.22 (sec) , antiderivative size = 237, normalized size of antiderivative = 2.06 \[ \int \frac {x^2}{(c+d x) \sqrt {a x+b x^2}} \, dx=\frac {-2 \sqrt {c}\, \sqrt {a d -b c}\, \mathit {atan} \left (\frac {\sqrt {a d -b c}-\sqrt {d}\, \sqrt {b x +a}-\sqrt {x}\, \sqrt {d}\, \sqrt {b}}{\sqrt {c}\, \sqrt {b}}\right ) b^{2} c -2 \sqrt {c}\, \sqrt {a d -b c}\, \mathit {atan} \left (\frac {\sqrt {a d -b c}+\sqrt {d}\, \sqrt {b x +a}+\sqrt {x}\, \sqrt {d}\, \sqrt {b}}{\sqrt {c}\, \sqrt {b}}\right ) b^{2} c +\sqrt {x}\, \sqrt {b x +a}\, a b \,d^{2}-\sqrt {x}\, \sqrt {b x +a}\, b^{2} c d -\sqrt {b}\, \mathrm {log}\left (\frac {\sqrt {b x +a}+\sqrt {x}\, \sqrt {b}}{\sqrt {a}}\right ) a^{2} d^{2}-\sqrt {b}\, \mathrm {log}\left (\frac {\sqrt {b x +a}+\sqrt {x}\, \sqrt {b}}{\sqrt {a}}\right ) a b c d +2 \sqrt {b}\, \mathrm {log}\left (\frac {\sqrt {b x +a}+\sqrt {x}\, \sqrt {b}}{\sqrt {a}}\right ) b^{2} c^{2}}{b^{2} d^{2} \left (a d -b c \right )} \] Input:

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

Output:

( - 2*sqrt(c)*sqrt(a*d - b*c)*atan((sqrt(a*d - b*c) - sqrt(d)*sqrt(a + b*x 
) - sqrt(x)*sqrt(d)*sqrt(b))/(sqrt(c)*sqrt(b)))*b**2*c - 2*sqrt(c)*sqrt(a* 
d - b*c)*atan((sqrt(a*d - b*c) + sqrt(d)*sqrt(a + b*x) + sqrt(x)*sqrt(d)*s 
qrt(b))/(sqrt(c)*sqrt(b)))*b**2*c + sqrt(x)*sqrt(a + b*x)*a*b*d**2 - sqrt( 
x)*sqrt(a + b*x)*b**2*c*d - sqrt(b)*log((sqrt(a + b*x) + sqrt(x)*sqrt(b))/ 
sqrt(a))*a**2*d**2 - sqrt(b)*log((sqrt(a + b*x) + sqrt(x)*sqrt(b))/sqrt(a) 
)*a*b*c*d + 2*sqrt(b)*log((sqrt(a + b*x) + sqrt(x)*sqrt(b))/sqrt(a))*b**2* 
c**2)/(b**2*d**2*(a*d - b*c))