\(\int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx\) [82]

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

Optimal result

Integrand size = 29, antiderivative size = 191 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=-\frac {2 (a d f h-b (d f g+d e h-c f h)) \sqrt {e+f x}}{b^2 d^2}+\frac {2 h (e+f x)^{3/2}}{3 b d}-\frac {2 (b e-a f)^{3/2} (b g-a h) \text {arctanh}\left (\frac {\sqrt {b} \sqrt {e+f x}}{\sqrt {b e-a f}}\right )}{b^{5/2} (b c-a d)}+\frac {2 (d e-c f)^{3/2} (d g-c h) \text {arctanh}\left (\frac {\sqrt {d} \sqrt {e+f x}}{\sqrt {d e-c f}}\right )}{d^{5/2} (b c-a d)} \] Output:

-2*(a*d*f*h-b*(-c*f*h+d*e*h+d*f*g))*(f*x+e)^(1/2)/b^2/d^2+2/3*h*(f*x+e)^(3 
/2)/b/d-2*(-a*f+b*e)^(3/2)*(-a*h+b*g)*arctanh(b^(1/2)*(f*x+e)^(1/2)/(-a*f+ 
b*e)^(1/2))/b^(5/2)/(-a*d+b*c)+2*(-c*f+d*e)^(3/2)*(-c*h+d*g)*arctanh(d^(1/ 
2)*(f*x+e)^(1/2)/(-c*f+d*e)^(1/2))/d^(5/2)/(-a*d+b*c)
 

Mathematica [A] (verified)

Time = 0.36 (sec) , antiderivative size = 179, normalized size of antiderivative = 0.94 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=\frac {2 \sqrt {e+f x} (-3 b c f h-3 a d f h+b d (3 f g+4 e h+f h x))}{3 b^2 d^2}+\frac {2 (-b e+a f)^{3/2} (b g-a h) \arctan \left (\frac {\sqrt {b} \sqrt {e+f x}}{\sqrt {-b e+a f}}\right )}{b^{5/2} (b c-a d)}+\frac {2 (-d e+c f)^{3/2} (d g-c h) \arctan \left (\frac {\sqrt {d} \sqrt {e+f x}}{\sqrt {-d e+c f}}\right )}{d^{5/2} (-b c+a d)} \] Input:

Integrate[((e + f*x)^(3/2)*(g + h*x))/((a + b*x)*(c + d*x)),x]
 

Output:

(2*Sqrt[e + f*x]*(-3*b*c*f*h - 3*a*d*f*h + b*d*(3*f*g + 4*e*h + f*h*x)))/( 
3*b^2*d^2) + (2*(-(b*e) + a*f)^(3/2)*(b*g - a*h)*ArcTan[(Sqrt[b]*Sqrt[e + 
f*x])/Sqrt[-(b*e) + a*f]])/(b^(5/2)*(b*c - a*d)) + (2*(-(d*e) + c*f)^(3/2) 
*(d*g - c*h)*ArcTan[(Sqrt[d]*Sqrt[e + f*x])/Sqrt[-(d*e) + c*f]])/(d^(5/2)* 
(-(b*c) + a*d))
 

Rubi [A] (verified)

Time = 0.57 (sec) , antiderivative size = 213, normalized size of antiderivative = 1.12, number of steps used = 8, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.241, Rules used = {171, 27, 171, 27, 174, 73, 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 {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx\)

\(\Big \downarrow \) 171

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 171

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 174

\(\displaystyle \frac {\frac {\frac {d^2 (b e-a f)^2 (b g-a h) \int \frac {1}{(a+b x) \sqrt {e+f x}}dx}{b c-a d}-\frac {b^2 (d e-c f)^2 (d g-c h) \int \frac {1}{(c+d x) \sqrt {e+f x}}dx}{b c-a d}}{b d}-\frac {2 \sqrt {e+f x} (a d f h-b (-c f h+d e h+d f g))}{b d}}{b d}+\frac {2 h (e+f x)^{3/2}}{3 b d}\)

\(\Big \downarrow \) 73

\(\displaystyle \frac {\frac {\frac {2 d^2 (b e-a f)^2 (b g-a h) \int \frac {1}{a+\frac {b (e+f x)}{f}-\frac {b e}{f}}d\sqrt {e+f x}}{f (b c-a d)}-\frac {2 b^2 (d e-c f)^2 (d g-c h) \int \frac {1}{c+\frac {d (e+f x)}{f}-\frac {d e}{f}}d\sqrt {e+f x}}{f (b c-a d)}}{b d}-\frac {2 \sqrt {e+f x} (a d f h-b (-c f h+d e h+d f g))}{b d}}{b d}+\frac {2 h (e+f x)^{3/2}}{3 b d}\)

\(\Big \downarrow \) 221

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

Input:

Int[((e + f*x)^(3/2)*(g + h*x))/((a + b*x)*(c + d*x)),x]
 

Output:

(2*h*(e + f*x)^(3/2))/(3*b*d) + ((-2*(a*d*f*h - b*(d*f*g + d*e*h - c*f*h)) 
*Sqrt[e + f*x])/(b*d) + ((-2*d^2*(b*e - a*f)^(3/2)*(b*g - a*h)*ArcTanh[(Sq 
rt[b]*Sqrt[e + f*x])/Sqrt[b*e - a*f]])/(Sqrt[b]*(b*c - a*d)) + (2*b^2*(d*e 
 - c*f)^(3/2)*(d*g - c*h)*ArcTanh[(Sqrt[d]*Sqrt[e + f*x])/Sqrt[d*e - c*f]] 
)/(Sqrt[d]*(b*c - a*d)))/(b*d))/(b*d)
 

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 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 171
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) 
)^(p_)*((g_.) + (h_.)*(x_)), x_] :> Simp[h*(a + b*x)^m*(c + d*x)^(n + 1)*(( 
e + f*x)^(p + 1)/(d*f*(m + n + p + 2))), x] + Simp[1/(d*f*(m + n + p + 2)) 
  Int[(a + b*x)^(m - 1)*(c + d*x)^n*(e + f*x)^p*Simp[a*d*f*g*(m + n + p + 2 
) - h*(b*c*e*m + a*(d*e*(n + 1) + c*f*(p + 1))) + (b*d*f*g*(m + n + p + 2) 
+ h*(a*d*f*m - b*(d*e*(m + n + 1) + c*f*(m + p + 1))))*x, x], x], x] /; Fre 
eQ[{a, b, c, d, e, f, g, h, n, p}, x] && GtQ[m, 0] && NeQ[m + n + p + 2, 0] 
 && IntegersQ[2*m, 2*n, 2*p]
 

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

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]
 
Maple [A] (verified)

Time = 0.62 (sec) , antiderivative size = 217, normalized size of antiderivative = 1.14

method result size
pseudoelliptic \(-\frac {2 \left (-\sqrt {\left (c f -d e \right ) d}\, d^{2} \left (a h -b g \right ) \left (a f -b e \right )^{2} \arctan \left (\frac {b \sqrt {f x +e}}{\sqrt {\left (a f -b e \right ) b}}\right )+\sqrt {\left (a f -b e \right ) b}\, \left (b^{2} \left (c f -d e \right )^{2} \left (c h -d g \right ) \arctan \left (\frac {d \sqrt {f x +e}}{\sqrt {\left (c f -d e \right ) d}}\right )+\left (\left (\left (\left (-\frac {h x}{3}-g \right ) f -\frac {4 e h}{3}\right ) d +c f h \right ) b +a d f h \right ) \left (a d -b c \right ) \sqrt {\left (c f -d e \right ) d}\, \sqrt {f x +e}\right )\right )}{\sqrt {\left (a f -b e \right ) b}\, \sqrt {\left (c f -d e \right ) d}\, b^{2} d^{2} \left (a d -b c \right )}\) \(217\)
risch \(-\frac {2 \left (-h f d b x +3 a d f h +3 b c f h -4 b d e h -3 b d f g \right ) \sqrt {f x +e}}{3 b^{2} d^{2}}+\frac {\frac {2 d^{2} \left (f^{2} a^{3} h -2 a^{2} b e f h -a^{2} b \,f^{2} g +a \,b^{2} e^{2} h +2 a \,b^{2} e f g -b^{3} e^{2} g \right ) \arctan \left (\frac {b \sqrt {f x +e}}{\sqrt {\left (a f -b e \right ) b}}\right )}{\left (a d -b c \right ) \sqrt {\left (a f -b e \right ) b}}-\frac {2 b^{2} \left (c^{3} f^{2} h -2 c^{2} d e f h -c^{2} d \,f^{2} g +c \,d^{2} e^{2} h +2 c \,d^{2} e f g -d^{3} e^{2} g \right ) \arctan \left (\frac {d \sqrt {f x +e}}{\sqrt {\left (c f -d e \right ) d}}\right )}{\left (a d -b c \right ) \sqrt {\left (c f -d e \right ) d}}}{b^{2} d^{2}}\) \(265\)
derivativedivides \(-\frac {2 \left (-\frac {d h \left (f x +e \right )^{\frac {3}{2}} b}{3}+a d f h \sqrt {f x +e}+b c f h \sqrt {f x +e}-b d e h \sqrt {f x +e}-b d f g \sqrt {f x +e}\right )}{b^{2} d^{2}}+\frac {2 \left (f^{2} a^{3} h -2 a^{2} b e f h -a^{2} b \,f^{2} g +a \,b^{2} e^{2} h +2 a \,b^{2} e f g -b^{3} e^{2} g \right ) \arctan \left (\frac {b \sqrt {f x +e}}{\sqrt {\left (a f -b e \right ) b}}\right )}{b^{2} \left (a d -b c \right ) \sqrt {\left (a f -b e \right ) b}}+\frac {2 \left (-c^{3} f^{2} h +2 c^{2} d e f h +c^{2} d \,f^{2} g -c \,d^{2} e^{2} h -2 c \,d^{2} e f g +d^{3} e^{2} g \right ) \arctan \left (\frac {d \sqrt {f x +e}}{\sqrt {\left (c f -d e \right ) d}}\right )}{d^{2} \left (a d -b c \right ) \sqrt {\left (c f -d e \right ) d}}\) \(281\)
default \(-\frac {2 \left (-\frac {d h \left (f x +e \right )^{\frac {3}{2}} b}{3}+a d f h \sqrt {f x +e}+b c f h \sqrt {f x +e}-b d e h \sqrt {f x +e}-b d f g \sqrt {f x +e}\right )}{b^{2} d^{2}}+\frac {2 \left (f^{2} a^{3} h -2 a^{2} b e f h -a^{2} b \,f^{2} g +a \,b^{2} e^{2} h +2 a \,b^{2} e f g -b^{3} e^{2} g \right ) \arctan \left (\frac {b \sqrt {f x +e}}{\sqrt {\left (a f -b e \right ) b}}\right )}{b^{2} \left (a d -b c \right ) \sqrt {\left (a f -b e \right ) b}}+\frac {2 \left (-c^{3} f^{2} h +2 c^{2} d e f h +c^{2} d \,f^{2} g -c \,d^{2} e^{2} h -2 c \,d^{2} e f g +d^{3} e^{2} g \right ) \arctan \left (\frac {d \sqrt {f x +e}}{\sqrt {\left (c f -d e \right ) d}}\right )}{d^{2} \left (a d -b c \right ) \sqrt {\left (c f -d e \right ) d}}\) \(281\)

Input:

int((f*x+e)^(3/2)*(h*x+g)/(b*x+a)/(d*x+c),x,method=_RETURNVERBOSE)
 

Output:

-2/((a*f-b*e)*b)^(1/2)/((c*f-d*e)*d)^(1/2)*(-((c*f-d*e)*d)^(1/2)*d^2*(a*h- 
b*g)*(a*f-b*e)^2*arctan(b*(f*x+e)^(1/2)/((a*f-b*e)*b)^(1/2))+((a*f-b*e)*b) 
^(1/2)*(b^2*(c*f-d*e)^2*(c*h-d*g)*arctan(d*(f*x+e)^(1/2)/((c*f-d*e)*d)^(1/ 
2))+((((-1/3*h*x-g)*f-4/3*e*h)*d+c*f*h)*b+a*d*f*h)*(a*d-b*c)*((c*f-d*e)*d) 
^(1/2)*(f*x+e)^(1/2)))/b^2/d^2/(a*d-b*c)
 

Fricas [A] (verification not implemented)

Time = 20.55 (sec) , antiderivative size = 1213, normalized size of antiderivative = 6.35 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=\text {Too large to display} \] Input:

integrate((f*x+e)^(3/2)*(h*x+g)/(b*x+a)/(d*x+c),x, algorithm="fricas")
 

Output:

[-1/3*(3*((b^2*d^2*e - a*b*d^2*f)*g - (a*b*d^2*e - a^2*d^2*f)*h)*sqrt((b*e 
 - a*f)/b)*log((b*f*x + 2*b*e - a*f + 2*sqrt(f*x + e)*b*sqrt((b*e - a*f)/b 
))/(b*x + a)) + 3*((b^2*d^2*e - b^2*c*d*f)*g - (b^2*c*d*e - b^2*c^2*f)*h)* 
sqrt((d*e - c*f)/d)*log((d*f*x + 2*d*e - c*f - 2*sqrt(f*x + e)*d*sqrt((d*e 
 - c*f)/d))/(d*x + c)) - 2*((b^2*c*d - a*b*d^2)*f*h*x + 3*(b^2*c*d - a*b*d 
^2)*f*g + (4*(b^2*c*d - a*b*d^2)*e - 3*(b^2*c^2 - a^2*d^2)*f)*h)*sqrt(f*x 
+ e))/(b^3*c*d^2 - a*b^2*d^3), -1/3*(6*((b^2*d^2*e - a*b*d^2*f)*g - (a*b*d 
^2*e - a^2*d^2*f)*h)*sqrt(-(b*e - a*f)/b)*arctan(-sqrt(f*x + e)*b*sqrt(-(b 
*e - a*f)/b)/(b*e - a*f)) + 3*((b^2*d^2*e - b^2*c*d*f)*g - (b^2*c*d*e - b^ 
2*c^2*f)*h)*sqrt((d*e - c*f)/d)*log((d*f*x + 2*d*e - c*f - 2*sqrt(f*x + e) 
*d*sqrt((d*e - c*f)/d))/(d*x + c)) - 2*((b^2*c*d - a*b*d^2)*f*h*x + 3*(b^2 
*c*d - a*b*d^2)*f*g + (4*(b^2*c*d - a*b*d^2)*e - 3*(b^2*c^2 - a^2*d^2)*f)* 
h)*sqrt(f*x + e))/(b^3*c*d^2 - a*b^2*d^3), 1/3*(6*((b^2*d^2*e - b^2*c*d*f) 
*g - (b^2*c*d*e - b^2*c^2*f)*h)*sqrt(-(d*e - c*f)/d)*arctan(-sqrt(f*x + e) 
*d*sqrt(-(d*e - c*f)/d)/(d*e - c*f)) - 3*((b^2*d^2*e - a*b*d^2*f)*g - (a*b 
*d^2*e - a^2*d^2*f)*h)*sqrt((b*e - a*f)/b)*log((b*f*x + 2*b*e - a*f + 2*sq 
rt(f*x + e)*b*sqrt((b*e - a*f)/b))/(b*x + a)) + 2*((b^2*c*d - a*b*d^2)*f*h 
*x + 3*(b^2*c*d - a*b*d^2)*f*g + (4*(b^2*c*d - a*b*d^2)*e - 3*(b^2*c^2 - a 
^2*d^2)*f)*h)*sqrt(f*x + e))/(b^3*c*d^2 - a*b^2*d^3), -2/3*(3*((b^2*d^2*e 
- a*b*d^2*f)*g - (a*b*d^2*e - a^2*d^2*f)*h)*sqrt(-(b*e - a*f)/b)*arctan...
                                                                                    
                                                                                    
 

Sympy [A] (verification not implemented)

Time = 25.80 (sec) , antiderivative size = 252, normalized size of antiderivative = 1.32 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=\begin {cases} \frac {2 \left (- \frac {f \left (c f - d e\right )^{2} \left (c h - d g\right ) \operatorname {atan}{\left (\frac {\sqrt {e + f x}}{\sqrt {\frac {c f - d e}{d}}} \right )}}{d^{3} \sqrt {\frac {c f - d e}{d}} \left (a d - b c\right )} + \frac {f h \left (e + f x\right )^{\frac {3}{2}}}{3 b d} + \frac {\sqrt {e + f x} \left (- a d f^{2} h - b c f^{2} h + b d e f h + b d f^{2} g\right )}{b^{2} d^{2}} + \frac {f \left (a f - b e\right )^{2} \left (a h - b g\right ) \operatorname {atan}{\left (\frac {\sqrt {e + f x}}{\sqrt {\frac {a f - b e}{b}}} \right )}}{b^{3} \sqrt {\frac {a f - b e}{b}} \left (a d - b c\right )}\right )}{f} & \text {for}\: f \neq 0 \\e^{\frac {3}{2}} \left (\frac {\left (a h - b g\right ) \left (\begin {cases} \frac {x}{a} & \text {for}\: b = 0 \\\frac {\log {\left (a + b x \right )}}{b} & \text {otherwise} \end {cases}\right )}{a d - b c} - \frac {\left (c h - d g\right ) \left (\begin {cases} \frac {x}{c} & \text {for}\: d = 0 \\\frac {\log {\left (c + d x \right )}}{d} & \text {otherwise} \end {cases}\right )}{a d - b c}\right ) & \text {otherwise} \end {cases} \] Input:

integrate((f*x+e)**(3/2)*(h*x+g)/(b*x+a)/(d*x+c),x)
 

Output:

Piecewise((2*(-f*(c*f - d*e)**2*(c*h - d*g)*atan(sqrt(e + f*x)/sqrt((c*f - 
 d*e)/d))/(d**3*sqrt((c*f - d*e)/d)*(a*d - b*c)) + f*h*(e + f*x)**(3/2)/(3 
*b*d) + sqrt(e + f*x)*(-a*d*f**2*h - b*c*f**2*h + b*d*e*f*h + b*d*f**2*g)/ 
(b**2*d**2) + f*(a*f - b*e)**2*(a*h - b*g)*atan(sqrt(e + f*x)/sqrt((a*f - 
b*e)/b))/(b**3*sqrt((a*f - b*e)/b)*(a*d - b*c)))/f, Ne(f, 0)), (e**(3/2)*( 
(a*h - b*g)*Piecewise((x/a, Eq(b, 0)), (log(a + b*x)/b, True))/(a*d - b*c) 
 - (c*h - d*g)*Piecewise((x/c, Eq(d, 0)), (log(c + d*x)/d, True))/(a*d - b 
*c)), True))
 

Maxima [F(-2)]

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

integrate((f*x+e)^(3/2)*(h*x+g)/(b*x+a)/(d*x+c),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(c*f-d*e>0)', see `assume?` for m 
ore detail
 

Giac [A] (verification not implemented)

Time = 0.14 (sec) , antiderivative size = 307, normalized size of antiderivative = 1.61 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=\frac {2 \, {\left (b^{3} e^{2} g - 2 \, a b^{2} e f g + a^{2} b f^{2} g - a b^{2} e^{2} h + 2 \, a^{2} b e f h - a^{3} f^{2} h\right )} \arctan \left (\frac {\sqrt {f x + e} b}{\sqrt {-b^{2} e + a b f}}\right )}{{\left (b^{3} c - a b^{2} d\right )} \sqrt {-b^{2} e + a b f}} - \frac {2 \, {\left (d^{3} e^{2} g - 2 \, c d^{2} e f g + c^{2} d f^{2} g - c d^{2} e^{2} h + 2 \, c^{2} d e f h - c^{3} f^{2} h\right )} \arctan \left (\frac {\sqrt {f x + e} d}{\sqrt {-d^{2} e + c d f}}\right )}{{\left (b c d^{2} - a d^{3}\right )} \sqrt {-d^{2} e + c d f}} + \frac {2 \, {\left (3 \, \sqrt {f x + e} b^{2} d^{2} f g + {\left (f x + e\right )}^{\frac {3}{2}} b^{2} d^{2} h + 3 \, \sqrt {f x + e} b^{2} d^{2} e h - 3 \, \sqrt {f x + e} b^{2} c d f h - 3 \, \sqrt {f x + e} a b d^{2} f h\right )}}{3 \, b^{3} d^{3}} \] Input:

integrate((f*x+e)^(3/2)*(h*x+g)/(b*x+a)/(d*x+c),x, algorithm="giac")
 

Output:

2*(b^3*e^2*g - 2*a*b^2*e*f*g + a^2*b*f^2*g - a*b^2*e^2*h + 2*a^2*b*e*f*h - 
 a^3*f^2*h)*arctan(sqrt(f*x + e)*b/sqrt(-b^2*e + a*b*f))/((b^3*c - a*b^2*d 
)*sqrt(-b^2*e + a*b*f)) - 2*(d^3*e^2*g - 2*c*d^2*e*f*g + c^2*d*f^2*g - c*d 
^2*e^2*h + 2*c^2*d*e*f*h - c^3*f^2*h)*arctan(sqrt(f*x + e)*d/sqrt(-d^2*e + 
 c*d*f))/((b*c*d^2 - a*d^3)*sqrt(-d^2*e + c*d*f)) + 2/3*(3*sqrt(f*x + e)*b 
^2*d^2*f*g + (f*x + e)^(3/2)*b^2*d^2*h + 3*sqrt(f*x + e)*b^2*d^2*e*h - 3*s 
qrt(f*x + e)*b^2*c*d*f*h - 3*sqrt(f*x + e)*a*b*d^2*f*h)/(b^3*d^3)
 

Mupad [B] (verification not implemented)

Time = 3.60 (sec) , antiderivative size = 13380, normalized size of antiderivative = 70.05 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=\text {Too large to display} \] Input:

int(((e + f*x)^(3/2)*(g + h*x))/((a + b*x)*(c + d*x)),x)
 

Output:

(2*h*(e + f*x)^(3/2))/(3*b*d) - (atan(((((8*(e + f*x)^(1/2)*(a^6*d^6*f^6*h 
^2 + b^6*c^6*f^6*h^2 + a^4*b^2*d^6*f^6*g^2 + b^6*c^4*d^2*f^6*g^2 + 2*b^6*d 
^6*e^4*f^2*g^2 - 4*a^5*b*d^6*e*f^5*h^2 - 4*b^6*c^5*d*e*f^5*h^2 - 4*a*b^5*d 
^6*e^3*f^3*g^2 - 4*a^3*b^3*d^6*e*f^5*g^2 - 4*b^6*c*d^5*e^3*f^3*g^2 - 4*b^6 
*c^3*d^3*e*f^5*g^2 - 2*a^5*b*d^6*f^6*g*h - 2*b^6*c^5*d*f^6*g*h + 6*a^2*b^4 
*d^6*e^2*f^4*g^2 + a^2*b^4*d^6*e^4*f^2*h^2 - 4*a^3*b^3*d^6*e^3*f^3*h^2 + 6 
*a^4*b^2*d^6*e^2*f^4*h^2 + 6*b^6*c^2*d^4*e^2*f^4*g^2 + b^6*c^2*d^4*e^4*f^2 
*h^2 - 4*b^6*c^3*d^3*e^3*f^3*h^2 + 6*b^6*c^4*d^2*e^2*f^4*h^2 - 2*a*b^5*d^6 
*e^4*f^2*g*h + 8*a^4*b^2*d^6*e*f^5*g*h - 2*b^6*c*d^5*e^4*f^2*g*h + 8*b^6*c 
^4*d^2*e*f^5*g*h + 8*a^2*b^4*d^6*e^3*f^3*g*h - 12*a^3*b^3*d^6*e^2*f^4*g*h 
+ 8*b^6*c^2*d^4*e^3*f^3*g*h - 12*b^6*c^3*d^3*e^2*f^4*g*h))/(b^3*d^3) + ((( 
8*(a*b^6*c^3*d^4*f^5*g + a^3*b^4*c*d^6*f^5*g - a*b^6*c^4*d^3*f^5*h - a^4*b 
^3*c*d^6*f^5*h - a^3*b^4*d^7*e*f^4*g + a^4*b^3*d^7*e*f^4*h - b^7*c^3*d^4*e 
*f^4*g + b^7*c^4*d^3*e*f^4*h - 2*a^2*b^5*c^2*d^5*f^5*g + a^2*b^5*c^3*d^4*f 
^5*h + a^3*b^4*c^2*d^5*f^5*h + a^2*b^5*d^7*e^2*f^3*g + a^2*b^5*d^7*e^3*f^2 
*h - 2*a^3*b^4*d^7*e^2*f^3*h + b^7*c^2*d^5*e^2*f^3*g + b^7*c^2*d^5*e^3*f^2 
*h - 2*b^7*c^3*d^4*e^2*f^3*h - 2*a*b^6*c*d^6*e^2*f^3*g + a*b^6*c^2*d^5*e*f 
^4*g + a^2*b^5*c*d^6*e*f^4*g - 2*a*b^6*c*d^6*e^3*f^2*h + a*b^6*c^3*d^4*e*f 
^4*h + a^3*b^4*c*d^6*e*f^4*h + 2*a*b^6*c^2*d^5*e^2*f^3*h + 2*a^2*b^5*c*d^6 
*e^2*f^3*h - 4*a^2*b^5*c^2*d^5*e*f^4*h))/(b^3*d^3) - (8*(e + f*x)^(1/2)...
 

Reduce [B] (verification not implemented)

Time = 0.16 (sec) , antiderivative size = 512, normalized size of antiderivative = 2.68 \[ \int \frac {(e+f x)^{3/2} (g+h x)}{(a+b x) (c+d x)} \, dx=\frac {2 \sqrt {b}\, \sqrt {a f -b e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, b}{\sqrt {b}\, \sqrt {a f -b e}}\right ) a^{2} d^{3} f h -2 \sqrt {b}\, \sqrt {a f -b e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, b}{\sqrt {b}\, \sqrt {a f -b e}}\right ) a b \,d^{3} e h -2 \sqrt {b}\, \sqrt {a f -b e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, b}{\sqrt {b}\, \sqrt {a f -b e}}\right ) a b \,d^{3} f g +2 \sqrt {b}\, \sqrt {a f -b e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, b}{\sqrt {b}\, \sqrt {a f -b e}}\right ) b^{2} d^{3} e g -2 \sqrt {d}\, \sqrt {c f -d e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, d}{\sqrt {d}\, \sqrt {c f -d e}}\right ) b^{3} c^{2} f h +2 \sqrt {d}\, \sqrt {c f -d e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, d}{\sqrt {d}\, \sqrt {c f -d e}}\right ) b^{3} c d e h +2 \sqrt {d}\, \sqrt {c f -d e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, d}{\sqrt {d}\, \sqrt {c f -d e}}\right ) b^{3} c d f g -2 \sqrt {d}\, \sqrt {c f -d e}\, \mathit {atan} \left (\frac {\sqrt {f x +e}\, d}{\sqrt {d}\, \sqrt {c f -d e}}\right ) b^{3} d^{2} e g -2 \sqrt {f x +e}\, a^{2} b \,d^{3} f h +\frac {8 \sqrt {f x +e}\, a \,b^{2} d^{3} e h}{3}+2 \sqrt {f x +e}\, a \,b^{2} d^{3} f g +\frac {2 \sqrt {f x +e}\, a \,b^{2} d^{3} f h x}{3}+2 \sqrt {f x +e}\, b^{3} c^{2} d f h -\frac {8 \sqrt {f x +e}\, b^{3} c \,d^{2} e h}{3}-2 \sqrt {f x +e}\, b^{3} c \,d^{2} f g -\frac {2 \sqrt {f x +e}\, b^{3} c \,d^{2} f h x}{3}}{b^{3} d^{3} \left (a d -b c \right )} \] Input:

int((f*x+e)^(3/2)*(h*x+g)/(b*x+a)/(d*x+c),x)
 

Output:

(2*(3*sqrt(b)*sqrt(a*f - b*e)*atan((sqrt(e + f*x)*b)/(sqrt(b)*sqrt(a*f - b 
*e)))*a**2*d**3*f*h - 3*sqrt(b)*sqrt(a*f - b*e)*atan((sqrt(e + f*x)*b)/(sq 
rt(b)*sqrt(a*f - b*e)))*a*b*d**3*e*h - 3*sqrt(b)*sqrt(a*f - b*e)*atan((sqr 
t(e + f*x)*b)/(sqrt(b)*sqrt(a*f - b*e)))*a*b*d**3*f*g + 3*sqrt(b)*sqrt(a*f 
 - b*e)*atan((sqrt(e + f*x)*b)/(sqrt(b)*sqrt(a*f - b*e)))*b**2*d**3*e*g - 
3*sqrt(d)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)) 
)*b**3*c**2*f*h + 3*sqrt(d)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d 
)*sqrt(c*f - d*e)))*b**3*c*d*e*h + 3*sqrt(d)*sqrt(c*f - d*e)*atan((sqrt(e 
+ f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*b**3*c*d*f*g - 3*sqrt(d)*sqrt(c*f - d 
*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*b**3*d**2*e*g - 3*sq 
rt(e + f*x)*a**2*b*d**3*f*h + 4*sqrt(e + f*x)*a*b**2*d**3*e*h + 3*sqrt(e + 
 f*x)*a*b**2*d**3*f*g + sqrt(e + f*x)*a*b**2*d**3*f*h*x + 3*sqrt(e + f*x)* 
b**3*c**2*d*f*h - 4*sqrt(e + f*x)*b**3*c*d**2*e*h - 3*sqrt(e + f*x)*b**3*c 
*d**2*f*g - sqrt(e + f*x)*b**3*c*d**2*f*h*x))/(3*b**3*d**3*(a*d - b*c))