\(\int \frac {x^{3/2} (A+B x)}{(a^2+2 a b x+b^2 x^2)^2} \, dx\) [397]

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

Optimal result

Integrand size = 29, antiderivative size = 124 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=-\frac {(A b-a B) x^{3/2}}{3 b^2 (a+b x)^3}-\frac {(A b-3 a B) \sqrt {x}}{4 b^3 (a+b x)^2}+\frac {(A b-11 a B) \sqrt {x}}{8 a b^3 (a+b x)}+\frac {(A b+5 a B) \arctan \left (\frac {\sqrt {b} \sqrt {x}}{\sqrt {a}}\right )}{8 a^{3/2} b^{7/2}} \] Output:

-1/3*(A*b-B*a)*x^(3/2)/b^2/(b*x+a)^3-1/4*(A*b-3*B*a)*x^(1/2)/b^3/(b*x+a)^2 
+1/8*(A*b-11*B*a)*x^(1/2)/a/b^3/(b*x+a)+1/8*(A*b+5*B*a)*arctan(b^(1/2)*x^( 
1/2)/a^(1/2))/a^(3/2)/b^(7/2)
 

Mathematica [A] (verified)

Time = 0.29 (sec) , antiderivative size = 105, normalized size of antiderivative = 0.85 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=-\frac {\sqrt {x} \left (15 a^3 B-3 A b^3 x^2+a b^2 x (8 A+33 B x)+a^2 b (3 A+40 B x)\right )}{24 a b^3 (a+b x)^3}+\frac {(A b+5 a B) \arctan \left (\frac {\sqrt {b} \sqrt {x}}{\sqrt {a}}\right )}{8 a^{3/2} b^{7/2}} \] Input:

Integrate[(x^(3/2)*(A + B*x))/(a^2 + 2*a*b*x + b^2*x^2)^2,x]
 

Output:

-1/24*(Sqrt[x]*(15*a^3*B - 3*A*b^3*x^2 + a*b^2*x*(8*A + 33*B*x) + a^2*b*(3 
*A + 40*B*x)))/(a*b^3*(a + b*x)^3) + ((A*b + 5*a*B)*ArcTan[(Sqrt[b]*Sqrt[x 
])/Sqrt[a]])/(8*a^(3/2)*b^(7/2))
 

Rubi [A] (verified)

Time = 0.39 (sec) , antiderivative size = 122, normalized size of antiderivative = 0.98, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.241, Rules used = {1184, 27, 87, 51, 51, 73, 218}

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^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx\)

\(\Big \downarrow \) 1184

\(\displaystyle b^4 \int \frac {x^{3/2} (A+B x)}{b^4 (a+b x)^4}dx\)

\(\Big \downarrow \) 27

\(\displaystyle \int \frac {x^{3/2} (A+B x)}{(a+b x)^4}dx\)

\(\Big \downarrow \) 87

\(\displaystyle \frac {(5 a B+A b) \int \frac {x^{3/2}}{(a+b x)^3}dx}{6 a b}+\frac {x^{5/2} (A b-a B)}{3 a b (a+b x)^3}\)

\(\Big \downarrow \) 51

\(\displaystyle \frac {(5 a B+A b) \left (\frac {3 \int \frac {\sqrt {x}}{(a+b x)^2}dx}{4 b}-\frac {x^{3/2}}{2 b (a+b x)^2}\right )}{6 a b}+\frac {x^{5/2} (A b-a B)}{3 a b (a+b x)^3}\)

\(\Big \downarrow \) 51

\(\displaystyle \frac {(5 a B+A b) \left (\frac {3 \left (\frac {\int \frac {1}{\sqrt {x} (a+b x)}dx}{2 b}-\frac {\sqrt {x}}{b (a+b x)}\right )}{4 b}-\frac {x^{3/2}}{2 b (a+b x)^2}\right )}{6 a b}+\frac {x^{5/2} (A b-a B)}{3 a b (a+b x)^3}\)

\(\Big \downarrow \) 73

\(\displaystyle \frac {(5 a B+A b) \left (\frac {3 \left (\frac {\int \frac {1}{a+b x}d\sqrt {x}}{b}-\frac {\sqrt {x}}{b (a+b x)}\right )}{4 b}-\frac {x^{3/2}}{2 b (a+b x)^2}\right )}{6 a b}+\frac {x^{5/2} (A b-a B)}{3 a b (a+b x)^3}\)

\(\Big \downarrow \) 218

\(\displaystyle \frac {(5 a B+A b) \left (\frac {3 \left (\frac {\arctan \left (\frac {\sqrt {b} \sqrt {x}}{\sqrt {a}}\right )}{\sqrt {a} b^{3/2}}-\frac {\sqrt {x}}{b (a+b x)}\right )}{4 b}-\frac {x^{3/2}}{2 b (a+b x)^2}\right )}{6 a b}+\frac {x^{5/2} (A b-a B)}{3 a b (a+b x)^3}\)

Input:

Int[(x^(3/2)*(A + B*x))/(a^2 + 2*a*b*x + b^2*x^2)^2,x]
 

Output:

((A*b - a*B)*x^(5/2))/(3*a*b*(a + b*x)^3) + ((A*b + 5*a*B)*(-1/2*x^(3/2)/( 
b*(a + b*x)^2) + (3*(-(Sqrt[x]/(b*(a + b*x))) + ArcTan[(Sqrt[b]*Sqrt[x])/S 
qrt[a]]/(Sqrt[a]*b^(3/2))))/(4*b)))/(6*a*b)
 

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 51
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[ 
(a + b*x)^(m + 1)*((c + d*x)^n/(b*(m + 1))), x] - Simp[d*(n/(b*(m + 1))) 
Int[(a + b*x)^(m + 1)*(c + d*x)^(n - 1), x], x] /; FreeQ[{a, b, c, d, n}, x 
] && ILtQ[m, -1] && FractionQ[n] && GtQ[n, 0]
 

rule 73
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[ 
{p = Denominator[m]}, Simp[p/b   Subst[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] && Lt 
Q[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntL 
inearQ[a, b, c, d, m, n, x]
 

rule 87
Int[((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p 
_.), x_] :> Simp[(-(b*e - a*f))*(c + d*x)^(n + 1)*((e + f*x)^(p + 1)/(f*(p 
+ 1)*(c*f - d*e))), x] - Simp[(a*d*f*(n + p + 2) - b*(d*e*(n + 1) + c*f*(p 
+ 1)))/(f*(p + 1)*(c*f - d*e))   Int[(c + d*x)^n*(e + f*x)^(p + 1), x], x] 
/; FreeQ[{a, b, c, d, e, f, n}, x] && LtQ[p, -1] && ( !LtQ[n, -1] || Intege 
rQ[p] ||  !(IntegerQ[n] ||  !(EqQ[e, 0] ||  !(EqQ[c, 0] || LtQ[p, n]))))
 

rule 218
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/R 
t[a/b, 2]], x] /; FreeQ[{a, b}, x] && PosQ[a/b]
 

rule 1184
Int[((d_.) + (e_.)*(x_))^(m_.)*((f_.) + (g_.)*(x_))^(n_.)*((a_) + (b_.)*(x_ 
) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Simp[1/c^p   Int[(d + e*x)^m*(f + g*x 
)^n*(b/2 + c*x)^(2*p), x], x] /; FreeQ[{a, b, c, d, e, f, g, m, n}, x] && E 
qQ[b^2 - 4*a*c, 0] && IntegerQ[p]
 
Maple [A] (verified)

Time = 1.11 (sec) , antiderivative size = 96, normalized size of antiderivative = 0.77

method result size
derivativedivides \(\frac {\frac {\left (A b -11 B a \right ) x^{\frac {5}{2}}}{8 a b}-\frac {\left (A b +5 B a \right ) x^{\frac {3}{2}}}{3 b^{2}}-\frac {\left (A b +5 B a \right ) a \sqrt {x}}{8 b^{3}}}{\left (b x +a \right )^{3}}+\frac {\left (A b +5 B a \right ) \arctan \left (\frac {b \sqrt {x}}{\sqrt {a b}}\right )}{8 a \,b^{3} \sqrt {a b}}\) \(96\)
default \(\frac {\frac {\left (A b -11 B a \right ) x^{\frac {5}{2}}}{8 a b}-\frac {\left (A b +5 B a \right ) x^{\frac {3}{2}}}{3 b^{2}}-\frac {\left (A b +5 B a \right ) a \sqrt {x}}{8 b^{3}}}{\left (b x +a \right )^{3}}+\frac {\left (A b +5 B a \right ) \arctan \left (\frac {b \sqrt {x}}{\sqrt {a b}}\right )}{8 a \,b^{3} \sqrt {a b}}\) \(96\)

Input:

int(x^(3/2)*(B*x+A)/(b^2*x^2+2*a*b*x+a^2)^2,x,method=_RETURNVERBOSE)
 

Output:

2*(1/16*(A*b-11*B*a)/a/b*x^(5/2)-1/6/b^2*(A*b+5*B*a)*x^(3/2)-1/16*(A*b+5*B 
*a)*a/b^3*x^(1/2))/(b*x+a)^3+1/8*(A*b+5*B*a)/a/b^3/(a*b)^(1/2)*arctan(b*x^ 
(1/2)/(a*b)^(1/2))
 

Fricas [A] (verification not implemented)

Time = 0.09 (sec) , antiderivative size = 411, normalized size of antiderivative = 3.31 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=\left [-\frac {3 \, {\left (5 \, B a^{4} + A a^{3} b + {\left (5 \, B a b^{3} + A b^{4}\right )} x^{3} + 3 \, {\left (5 \, B a^{2} b^{2} + A a b^{3}\right )} x^{2} + 3 \, {\left (5 \, B a^{3} b + A a^{2} b^{2}\right )} x\right )} \sqrt {-a b} \log \left (\frac {b x - a - 2 \, \sqrt {-a b} \sqrt {x}}{b x + a}\right ) + 2 \, {\left (15 \, B a^{4} b + 3 \, A a^{3} b^{2} + 3 \, {\left (11 \, B a^{2} b^{3} - A a b^{4}\right )} x^{2} + 8 \, {\left (5 \, B a^{3} b^{2} + A a^{2} b^{3}\right )} x\right )} \sqrt {x}}{48 \, {\left (a^{2} b^{7} x^{3} + 3 \, a^{3} b^{6} x^{2} + 3 \, a^{4} b^{5} x + a^{5} b^{4}\right )}}, -\frac {3 \, {\left (5 \, B a^{4} + A a^{3} b + {\left (5 \, B a b^{3} + A b^{4}\right )} x^{3} + 3 \, {\left (5 \, B a^{2} b^{2} + A a b^{3}\right )} x^{2} + 3 \, {\left (5 \, B a^{3} b + A a^{2} b^{2}\right )} x\right )} \sqrt {a b} \arctan \left (\frac {\sqrt {a b}}{b \sqrt {x}}\right ) + {\left (15 \, B a^{4} b + 3 \, A a^{3} b^{2} + 3 \, {\left (11 \, B a^{2} b^{3} - A a b^{4}\right )} x^{2} + 8 \, {\left (5 \, B a^{3} b^{2} + A a^{2} b^{3}\right )} x\right )} \sqrt {x}}{24 \, {\left (a^{2} b^{7} x^{3} + 3 \, a^{3} b^{6} x^{2} + 3 \, a^{4} b^{5} x + a^{5} b^{4}\right )}}\right ] \] Input:

integrate(x^(3/2)*(B*x+A)/(b^2*x^2+2*a*b*x+a^2)^2,x, algorithm="fricas")
 

Output:

[-1/48*(3*(5*B*a^4 + A*a^3*b + (5*B*a*b^3 + A*b^4)*x^3 + 3*(5*B*a^2*b^2 + 
A*a*b^3)*x^2 + 3*(5*B*a^3*b + A*a^2*b^2)*x)*sqrt(-a*b)*log((b*x - a - 2*sq 
rt(-a*b)*sqrt(x))/(b*x + a)) + 2*(15*B*a^4*b + 3*A*a^3*b^2 + 3*(11*B*a^2*b 
^3 - A*a*b^4)*x^2 + 8*(5*B*a^3*b^2 + A*a^2*b^3)*x)*sqrt(x))/(a^2*b^7*x^3 + 
 3*a^3*b^6*x^2 + 3*a^4*b^5*x + a^5*b^4), -1/24*(3*(5*B*a^4 + A*a^3*b + (5* 
B*a*b^3 + A*b^4)*x^3 + 3*(5*B*a^2*b^2 + A*a*b^3)*x^2 + 3*(5*B*a^3*b + A*a^ 
2*b^2)*x)*sqrt(a*b)*arctan(sqrt(a*b)/(b*sqrt(x))) + (15*B*a^4*b + 3*A*a^3* 
b^2 + 3*(11*B*a^2*b^3 - A*a*b^4)*x^2 + 8*(5*B*a^3*b^2 + A*a^2*b^3)*x)*sqrt 
(x))/(a^2*b^7*x^3 + 3*a^3*b^6*x^2 + 3*a^4*b^5*x + a^5*b^4)]
 

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 2261 vs. \(2 (117) = 234\).

Time = 44.97 (sec) , antiderivative size = 2261, normalized size of antiderivative = 18.23 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=\text {Too large to display} \] Input:

integrate(x**(3/2)*(B*x+A)/(b**2*x**2+2*a*b*x+a**2)**2,x)
 

Output:

Piecewise((zoo*(-2*A/(3*x**(3/2)) - 2*B/sqrt(x)), Eq(a, 0) & Eq(b, 0)), (( 
2*A*x**(5/2)/5 + 2*B*x**(7/2)/7)/a**4, Eq(b, 0)), ((-2*A/(3*x**(3/2)) - 2* 
B/sqrt(x))/b**4, Eq(a, 0)), (3*A*a**3*b*log(sqrt(x) - sqrt(-a/b))/(48*a**4 
*b**4*sqrt(-a/b) + 144*a**3*b**5*x*sqrt(-a/b) + 144*a**2*b**6*x**2*sqrt(-a 
/b) + 48*a*b**7*x**3*sqrt(-a/b)) - 3*A*a**3*b*log(sqrt(x) + sqrt(-a/b))/(4 
8*a**4*b**4*sqrt(-a/b) + 144*a**3*b**5*x*sqrt(-a/b) + 144*a**2*b**6*x**2*s 
qrt(-a/b) + 48*a*b**7*x**3*sqrt(-a/b)) - 6*A*a**2*b**2*sqrt(x)*sqrt(-a/b)/ 
(48*a**4*b**4*sqrt(-a/b) + 144*a**3*b**5*x*sqrt(-a/b) + 144*a**2*b**6*x**2 
*sqrt(-a/b) + 48*a*b**7*x**3*sqrt(-a/b)) + 9*A*a**2*b**2*x*log(sqrt(x) - s 
qrt(-a/b))/(48*a**4*b**4*sqrt(-a/b) + 144*a**3*b**5*x*sqrt(-a/b) + 144*a** 
2*b**6*x**2*sqrt(-a/b) + 48*a*b**7*x**3*sqrt(-a/b)) - 9*A*a**2*b**2*x*log( 
sqrt(x) + sqrt(-a/b))/(48*a**4*b**4*sqrt(-a/b) + 144*a**3*b**5*x*sqrt(-a/b 
) + 144*a**2*b**6*x**2*sqrt(-a/b) + 48*a*b**7*x**3*sqrt(-a/b)) - 16*A*a*b* 
*3*x**(3/2)*sqrt(-a/b)/(48*a**4*b**4*sqrt(-a/b) + 144*a**3*b**5*x*sqrt(-a/ 
b) + 144*a**2*b**6*x**2*sqrt(-a/b) + 48*a*b**7*x**3*sqrt(-a/b)) + 9*A*a*b* 
*3*x**2*log(sqrt(x) - sqrt(-a/b))/(48*a**4*b**4*sqrt(-a/b) + 144*a**3*b**5 
*x*sqrt(-a/b) + 144*a**2*b**6*x**2*sqrt(-a/b) + 48*a*b**7*x**3*sqrt(-a/b)) 
 - 9*A*a*b**3*x**2*log(sqrt(x) + sqrt(-a/b))/(48*a**4*b**4*sqrt(-a/b) + 14 
4*a**3*b**5*x*sqrt(-a/b) + 144*a**2*b**6*x**2*sqrt(-a/b) + 48*a*b**7*x**3* 
sqrt(-a/b)) + 6*A*b**4*x**(5/2)*sqrt(-a/b)/(48*a**4*b**4*sqrt(-a/b) + 1...
 

Maxima [A] (verification not implemented)

Time = 0.18 (sec) , antiderivative size = 130, normalized size of antiderivative = 1.05 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=-\frac {3 \, {\left (11 \, B a b^{2} - A b^{3}\right )} x^{\frac {5}{2}} + 8 \, {\left (5 \, B a^{2} b + A a b^{2}\right )} x^{\frac {3}{2}} + 3 \, {\left (5 \, B a^{3} + A a^{2} b\right )} \sqrt {x}}{24 \, {\left (a b^{6} x^{3} + 3 \, a^{2} b^{5} x^{2} + 3 \, a^{3} b^{4} x + a^{4} b^{3}\right )}} + \frac {{\left (5 \, B a + A b\right )} \arctan \left (\frac {b \sqrt {x}}{\sqrt {a b}}\right )}{8 \, \sqrt {a b} a b^{3}} \] Input:

integrate(x^(3/2)*(B*x+A)/(b^2*x^2+2*a*b*x+a^2)^2,x, algorithm="maxima")
                                                                                    
                                                                                    
 

Output:

-1/24*(3*(11*B*a*b^2 - A*b^3)*x^(5/2) + 8*(5*B*a^2*b + A*a*b^2)*x^(3/2) + 
3*(5*B*a^3 + A*a^2*b)*sqrt(x))/(a*b^6*x^3 + 3*a^2*b^5*x^2 + 3*a^3*b^4*x + 
a^4*b^3) + 1/8*(5*B*a + A*b)*arctan(b*sqrt(x)/sqrt(a*b))/(sqrt(a*b)*a*b^3)
 

Giac [A] (verification not implemented)

Time = 0.26 (sec) , antiderivative size = 107, normalized size of antiderivative = 0.86 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=\frac {{\left (5 \, B a + A b\right )} \arctan \left (\frac {b \sqrt {x}}{\sqrt {a b}}\right )}{8 \, \sqrt {a b} a b^{3}} - \frac {33 \, B a b^{2} x^{\frac {5}{2}} - 3 \, A b^{3} x^{\frac {5}{2}} + 40 \, B a^{2} b x^{\frac {3}{2}} + 8 \, A a b^{2} x^{\frac {3}{2}} + 15 \, B a^{3} \sqrt {x} + 3 \, A a^{2} b \sqrt {x}}{24 \, {\left (b x + a\right )}^{3} a b^{3}} \] Input:

integrate(x^(3/2)*(B*x+A)/(b^2*x^2+2*a*b*x+a^2)^2,x, algorithm="giac")
 

Output:

1/8*(5*B*a + A*b)*arctan(b*sqrt(x)/sqrt(a*b))/(sqrt(a*b)*a*b^3) - 1/24*(33 
*B*a*b^2*x^(5/2) - 3*A*b^3*x^(5/2) + 40*B*a^2*b*x^(3/2) + 8*A*a*b^2*x^(3/2 
) + 15*B*a^3*sqrt(x) + 3*A*a^2*b*sqrt(x))/((b*x + a)^3*a*b^3)
 

Mupad [B] (verification not implemented)

Time = 11.40 (sec) , antiderivative size = 112, normalized size of antiderivative = 0.90 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=\frac {\mathrm {atan}\left (\frac {\sqrt {b}\,\sqrt {x}}{\sqrt {a}}\right )\,\left (A\,b+5\,B\,a\right )}{8\,a^{3/2}\,b^{7/2}}-\frac {\frac {x^{3/2}\,\left (A\,b+5\,B\,a\right )}{3\,b^2}-\frac {x^{5/2}\,\left (A\,b-11\,B\,a\right )}{8\,a\,b}+\frac {a\,\sqrt {x}\,\left (A\,b+5\,B\,a\right )}{8\,b^3}}{a^3+3\,a^2\,b\,x+3\,a\,b^2\,x^2+b^3\,x^3} \] Input:

int((x^(3/2)*(A + B*x))/(a^2 + b^2*x^2 + 2*a*b*x)^2,x)
 

Output:

(atan((b^(1/2)*x^(1/2))/a^(1/2))*(A*b + 5*B*a))/(8*a^(3/2)*b^(7/2)) - ((x^ 
(3/2)*(A*b + 5*B*a))/(3*b^2) - (x^(5/2)*(A*b - 11*B*a))/(8*a*b) + (a*x^(1/ 
2)*(A*b + 5*B*a))/(8*b^3))/(a^3 + b^3*x^3 + 3*a*b^2*x^2 + 3*a^2*b*x)
 

Reduce [B] (verification not implemented)

Time = 0.27 (sec) , antiderivative size = 113, normalized size of antiderivative = 0.91 \[ \int \frac {x^{3/2} (A+B x)}{\left (a^2+2 a b x+b^2 x^2\right )^2} \, dx=\frac {3 \sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {x}\, b}{\sqrt {b}\, \sqrt {a}}\right ) a^{2}+6 \sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {x}\, b}{\sqrt {b}\, \sqrt {a}}\right ) a b x +3 \sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {\sqrt {x}\, b}{\sqrt {b}\, \sqrt {a}}\right ) b^{2} x^{2}-3 \sqrt {x}\, a^{2} b -5 \sqrt {x}\, a \,b^{2} x}{4 a \,b^{3} \left (b^{2} x^{2}+2 a b x +a^{2}\right )} \] Input:

int(x^(3/2)*(B*x+A)/(b^2*x^2+2*a*b*x+a^2)^2,x)
 

Output:

(3*sqrt(b)*sqrt(a)*atan((sqrt(x)*b)/(sqrt(b)*sqrt(a)))*a**2 + 6*sqrt(b)*sq 
rt(a)*atan((sqrt(x)*b)/(sqrt(b)*sqrt(a)))*a*b*x + 3*sqrt(b)*sqrt(a)*atan(( 
sqrt(x)*b)/(sqrt(b)*sqrt(a)))*b**2*x**2 - 3*sqrt(x)*a**2*b - 5*sqrt(x)*a*b 
**2*x)/(4*a*b**3*(a**2 + 2*a*b*x + b**2*x**2))