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

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

Optimal result

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

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

Mathematica [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(786\) vs. \(2(385)=770\).

Time = 2.24 (sec) , antiderivative size = 786, normalized size of antiderivative = 2.04 \[ \int \frac {(a+b x)^3 (g+h x)}{(c+d x)^3 (e+f x)^{3/2}} \, dx=\frac {-3 a^2 b d^2 f^2 \left (c^3 f h (e+f x)+4 d^3 e x (-e g-3 f g x+2 e h x)+c^2 d \left (14 e^2 h-f^2 x (5 g+h x)+e f (-13 g+5 h x)\right )+c d^2 \left (-3 f^2 g x^2-2 e^2 (g-12 h x)+e f x (-21 g+8 h x)\right )\right )+b^3 \left (15 c^5 f^3 h (e+f x)-8 d^5 e^3 x^2 (-f g+2 e h+f h x)+c^4 d f^2 (e+f x) (-3 f g-38 e h+25 f h x)+8 c d^4 e^2 x \left (-4 e^2 h+3 f^2 h x^2+e f (2 g+h x)\right )-4 c^2 d^3 e \left (4 e^3 h+3 f^3 x^2 (-g+2 h x)-3 e f^2 x (g+2 h x)-2 e^2 f (g+5 h x)\right )+c^3 d^2 f (e+f x) \left (24 e^2 h+2 e f (5 g-32 h x)+f^2 x (-5 g+8 h x)\right )\right )-3 a b^2 d f \left (8 d^4 e^2 (f g-e h) x^2+3 c^4 f^2 h (e+f x)+8 c d^3 e x \left (3 e f g-2 e^2 h+f^2 g x\right )+c^3 d f (e+f x) (-10 e h+f (g+5 h x))-c^2 d^2 \left (8 e^3 h+f^3 g x^2-2 e^2 f (7 g-6 h x)+e f^2 x (-5 g+12 h x)\right )\right )+a^3 d^3 f^2 \left (c^2 f (-8 f g+13 e h+5 f h x)+d^2 \left (-15 f^2 g x^2+2 e^2 (g+2 h x)+e f x (-5 g+12 h x)\right )+c d \left (2 e^2 h+f^2 x (-25 g+3 h x)+e f (-9 g+21 h x)\right )\right )}{4 d^3 f^2 (-d e+c f)^3 (c+d x)^2 \sqrt {e+f x}}-\frac {3 (b c-a d) \left (a^2 d^2 f (-5 d f g+4 d e h+c f h)-2 a b d \left (-c^2 f^2 h+2 d^2 e (-3 f g+2 e h)+c d f (f g+2 e h)\right )+b^2 \left (-8 d^3 e^2 g+5 c^3 f^2 h+4 c d^2 e (f g+4 e h)-c^2 d f (f g+16 e h)\right )\right ) \arctan \left (\frac {\sqrt {d} \sqrt {e+f x}}{\sqrt {-d e+c f}}\right )}{4 d^{7/2} (-d e+c f)^{7/2}} \] Input:

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

Output:

(-3*a^2*b*d^2*f^2*(c^3*f*h*(e + f*x) + 4*d^3*e*x*(-(e*g) - 3*f*g*x + 2*e*h 
*x) + c^2*d*(14*e^2*h - f^2*x*(5*g + h*x) + e*f*(-13*g + 5*h*x)) + c*d^2*( 
-3*f^2*g*x^2 - 2*e^2*(g - 12*h*x) + e*f*x*(-21*g + 8*h*x))) + b^3*(15*c^5* 
f^3*h*(e + f*x) - 8*d^5*e^3*x^2*(-(f*g) + 2*e*h + f*h*x) + c^4*d*f^2*(e + 
f*x)*(-3*f*g - 38*e*h + 25*f*h*x) + 8*c*d^4*e^2*x*(-4*e^2*h + 3*f^2*h*x^2 
+ e*f*(2*g + h*x)) - 4*c^2*d^3*e*(4*e^3*h + 3*f^3*x^2*(-g + 2*h*x) - 3*e*f 
^2*x*(g + 2*h*x) - 2*e^2*f*(g + 5*h*x)) + c^3*d^2*f*(e + f*x)*(24*e^2*h + 
2*e*f*(5*g - 32*h*x) + f^2*x*(-5*g + 8*h*x))) - 3*a*b^2*d*f*(8*d^4*e^2*(f* 
g - e*h)*x^2 + 3*c^4*f^2*h*(e + f*x) + 8*c*d^3*e*x*(3*e*f*g - 2*e^2*h + f^ 
2*g*x) + c^3*d*f*(e + f*x)*(-10*e*h + f*(g + 5*h*x)) - c^2*d^2*(8*e^3*h + 
f^3*g*x^2 - 2*e^2*f*(7*g - 6*h*x) + e*f^2*x*(-5*g + 12*h*x))) + a^3*d^3*f^ 
2*(c^2*f*(-8*f*g + 13*e*h + 5*f*h*x) + d^2*(-15*f^2*g*x^2 + 2*e^2*(g + 2*h 
*x) + e*f*x*(-5*g + 12*h*x)) + c*d*(2*e^2*h + f^2*x*(-25*g + 3*h*x) + e*f* 
(-9*g + 21*h*x))))/(4*d^3*f^2*(-(d*e) + c*f)^3*(c + d*x)^2*Sqrt[e + f*x]) 
- (3*(b*c - a*d)*(a^2*d^2*f*(-5*d*f*g + 4*d*e*h + c*f*h) - 2*a*b*d*(-(c^2* 
f^2*h) + 2*d^2*e*(-3*f*g + 2*e*h) + c*d*f*(f*g + 2*e*h)) + b^2*(-8*d^3*e^2 
*g + 5*c^3*f^2*h + 4*c*d^2*e*(f*g + 4*e*h) - c^2*d*f*(f*g + 16*e*h)))*ArcT 
an[(Sqrt[d]*Sqrt[e + f*x])/Sqrt[-(d*e) + c*f]])/(4*d^(7/2)*(-(d*e) + c*f)^ 
(7/2))
 

Rubi [A] (verified)

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

\(\Big \downarrow \) 166

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 166

\(\displaystyle \frac {\frac {\int -\frac {(a+b x) \left (2 a d (b e-a f) (5 d f g-4 d e h-c f h)+(4 b e-a f) \left (a d (5 d f g-4 d e h-c f h)-b \left (5 f h c^2-d (f g+10 e h) c+6 d^2 e g\right )\right )+b \left (a d f (5 d f g-4 d e h-c f h)-b \left (8 e (f g+e h) d^2-c f (3 f g+28 e h) d+15 c^2 f^2 h\right )\right ) x\right )}{2 (c+d x) (e+f x)^{3/2}}dx}{d (d e-c f)}+\frac {(a+b x)^2 \left (a d (-c f h-4 d e h+5 d f g)-b \left (5 c^2 f h-c d (10 e h+f g)+6 d^2 e g\right )\right )}{d (c+d x) \sqrt {e+f x} (d e-c f)}}{4 d (d e-c f)}-\frac {(a+b x)^3 (d g-c h)}{2 d (c+d x)^2 \sqrt {e+f x} (d e-c f)}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\frac {(a+b x)^2 \left (a d (-c f h-4 d e h+5 d f g)-b \left (5 c^2 f h-c d (10 e h+f g)+6 d^2 e g\right )\right )}{d (c+d x) \sqrt {e+f x} (d e-c f)}-\frac {\int \frac {(a+b x) \left (2 a d (b e-a f) (5 d f g-4 d e h-c f h)+(4 b e-a f) \left (a d (5 d f g-4 d e h-c f h)-b \left (5 f h c^2-d (f g+10 e h) c+6 d^2 e g\right )\right )+b \left (a d f (5 d f g-4 d e h-c f h)-b \left (8 e (f g+e h) d^2-c f (3 f g+28 e h) d+15 c^2 f^2 h\right )\right ) x\right )}{(c+d x) (e+f x)^{3/2}}dx}{2 d (d e-c f)}}{4 d (d e-c f)}-\frac {(a+b x)^3 (d g-c h)}{2 d (c+d x)^2 \sqrt {e+f x} (d e-c f)}\)

\(\Big \downarrow \) 163

\(\displaystyle \frac {\frac {(a+b x)^2 \left (a d (-c f h-4 d e h+5 d f g)-b \left (5 c^2 f h-c d (10 e h+f g)+6 d^2 e g\right )\right )}{d (c+d x) \sqrt {e+f x} (d e-c f)}-\frac {\frac {3 (b c-a d) \left (a^2 d^2 f (-c f h-4 d e h+5 d f g)-2 a b d \left (c^2 f^2 h-c d f (2 e h+f g)+2 d^2 e (3 f g-2 e h)\right )+b^2 \left (-5 c^3 f^2 h+c^2 d f (16 e h+f g)-4 c d^2 e (4 e h+f g)+8 d^3 e^2 g\right )\right ) \int \frac {1}{(c+d x) \sqrt {e+f x}}dx}{d (d e-c f)}-\frac {2 \left (3 a^3 d^2 f^3 (-c f h-4 d e h+5 d f g)-a^2 b d f^2 \left (5 c^2 f^2 h-c d f (18 e h+f g)+2 d^2 e (23 f g-16 e h)\right )-b^2 f x (d e-c f) \left (a d f (-c f h-4 d e h+5 d f g)-b \left (15 c^2 f^2 h-c d f (28 e h+3 f g)+8 d^2 e (e h+f g)\right )\right )+3 a b^2 d e f \left (3 c^2 f^2 h+c d f (f g-10 e h)+2 d^2 e (7 f g-4 e h)\right )+b^3 (-e) \left (15 c^3 f^3 h-c^2 d f^2 (38 e h+3 f g)+2 c d^2 e f (12 e h+5 f g)+8 d^3 e^2 (f g-2 e h)\right )\right )}{d f^2 \sqrt {e+f x} (d e-c f)}}{2 d (d e-c f)}}{4 d (d e-c f)}-\frac {(a+b x)^3 (d g-c h)}{2 d (c+d x)^2 \sqrt {e+f x} (d e-c f)}\)

\(\Big \downarrow \) 73

\(\displaystyle \frac {\frac {(a+b x)^2 \left (a d (-c f h-4 d e h+5 d f g)-b \left (5 c^2 f h-c d (10 e h+f g)+6 d^2 e g\right )\right )}{d (c+d x) \sqrt {e+f x} (d e-c f)}-\frac {\frac {6 (b c-a d) \left (a^2 d^2 f (-c f h-4 d e h+5 d f g)-2 a b d \left (c^2 f^2 h-c d f (2 e h+f g)+2 d^2 e (3 f g-2 e h)\right )+b^2 \left (-5 c^3 f^2 h+c^2 d f (16 e h+f g)-4 c d^2 e (4 e h+f g)+8 d^3 e^2 g\right )\right ) \int \frac {1}{c+\frac {d (e+f x)}{f}-\frac {d e}{f}}d\sqrt {e+f x}}{d f (d e-c f)}-\frac {2 \left (3 a^3 d^2 f^3 (-c f h-4 d e h+5 d f g)-a^2 b d f^2 \left (5 c^2 f^2 h-c d f (18 e h+f g)+2 d^2 e (23 f g-16 e h)\right )-b^2 f x (d e-c f) \left (a d f (-c f h-4 d e h+5 d f g)-b \left (15 c^2 f^2 h-c d f (28 e h+3 f g)+8 d^2 e (e h+f g)\right )\right )+3 a b^2 d e f \left (3 c^2 f^2 h+c d f (f g-10 e h)+2 d^2 e (7 f g-4 e h)\right )+b^3 (-e) \left (15 c^3 f^3 h-c^2 d f^2 (38 e h+3 f g)+2 c d^2 e f (12 e h+5 f g)+8 d^3 e^2 (f g-2 e h)\right )\right )}{d f^2 \sqrt {e+f x} (d e-c f)}}{2 d (d e-c f)}}{4 d (d e-c f)}-\frac {(a+b x)^3 (d g-c h)}{2 d (c+d x)^2 \sqrt {e+f x} (d e-c f)}\)

\(\Big \downarrow \) 221

\(\displaystyle \frac {\frac {(a+b x)^2 \left (a d (-c f h-4 d e h+5 d f g)-b \left (5 c^2 f h-c d (10 e h+f g)+6 d^2 e g\right )\right )}{d (c+d x) \sqrt {e+f x} (d e-c f)}-\frac {-\frac {6 (b c-a d) \text {arctanh}\left (\frac {\sqrt {d} \sqrt {e+f x}}{\sqrt {d e-c f}}\right ) \left (a^2 d^2 f (-c f h-4 d e h+5 d f g)-2 a b d \left (c^2 f^2 h-c d f (2 e h+f g)+2 d^2 e (3 f g-2 e h)\right )+b^2 \left (-5 c^3 f^2 h+c^2 d f (16 e h+f g)-4 c d^2 e (4 e h+f g)+8 d^3 e^2 g\right )\right )}{d^{3/2} (d e-c f)^{3/2}}-\frac {2 \left (3 a^3 d^2 f^3 (-c f h-4 d e h+5 d f g)-a^2 b d f^2 \left (5 c^2 f^2 h-c d f (18 e h+f g)+2 d^2 e (23 f g-16 e h)\right )-b^2 f x (d e-c f) \left (a d f (-c f h-4 d e h+5 d f g)-b \left (15 c^2 f^2 h-c d f (28 e h+3 f g)+8 d^2 e (e h+f g)\right )\right )+3 a b^2 d e f \left (3 c^2 f^2 h+c d f (f g-10 e h)+2 d^2 e (7 f g-4 e h)\right )+b^3 (-e) \left (15 c^3 f^3 h-c^2 d f^2 (38 e h+3 f g)+2 c d^2 e f (12 e h+5 f g)+8 d^3 e^2 (f g-2 e h)\right )\right )}{d f^2 \sqrt {e+f x} (d e-c f)}}{2 d (d e-c f)}}{4 d (d e-c f)}-\frac {(a+b x)^3 (d g-c h)}{2 d (c+d x)^2 \sqrt {e+f x} (d e-c f)}\)

Input:

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

Output:

-1/2*((d*g - c*h)*(a + b*x)^3)/(d*(d*e - c*f)*(c + d*x)^2*Sqrt[e + f*x]) + 
 (((a*d*(5*d*f*g - 4*d*e*h - c*f*h) - b*(6*d^2*e*g + 5*c^2*f*h - c*d*(f*g 
+ 10*e*h)))*(a + b*x)^2)/(d*(d*e - c*f)*(c + d*x)*Sqrt[e + f*x]) - ((-2*(3 
*a^3*d^2*f^3*(5*d*f*g - 4*d*e*h - c*f*h) + 3*a*b^2*d*e*f*(3*c^2*f^2*h + c* 
d*f*(f*g - 10*e*h) + 2*d^2*e*(7*f*g - 4*e*h)) - a^2*b*d*f^2*(5*c^2*f^2*h + 
 2*d^2*e*(23*f*g - 16*e*h) - c*d*f*(f*g + 18*e*h)) - b^3*e*(15*c^3*f^3*h + 
 8*d^3*e^2*(f*g - 2*e*h) + 2*c*d^2*e*f*(5*f*g + 12*e*h) - c^2*d*f^2*(3*f*g 
 + 38*e*h)) - b^2*f*(d*e - c*f)*(a*d*f*(5*d*f*g - 4*d*e*h - c*f*h) - b*(15 
*c^2*f^2*h + 8*d^2*e*(f*g + e*h) - c*d*f*(3*f*g + 28*e*h)))*x))/(d*f^2*(d* 
e - c*f)*Sqrt[e + f*x]) - (6*(b*c - a*d)*(a^2*d^2*f*(5*d*f*g - 4*d*e*h - c 
*f*h) - 2*a*b*d*(c^2*f^2*h + 2*d^2*e*(3*f*g - 2*e*h) - c*d*f*(f*g + 2*e*h) 
) + b^2*(8*d^3*e^2*g - 5*c^3*f^2*h - 4*c*d^2*e*(f*g + 4*e*h) + c^2*d*f*(f* 
g + 16*e*h)))*ArcTanh[(Sqrt[d]*Sqrt[e + f*x])/Sqrt[d*e - c*f]])/(d^(3/2)*( 
d*e - c*f)^(3/2)))/(2*d*(d*e - c*f)))/(4*d*(d*e - c*f))
 

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 163
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_.)*((e_) + (f_.)*(x_) 
)*((g_.) + (h_.)*(x_)), x_] :> Simp[((a^2*d*f*h*(n + 2) + b^2*d*e*g*(m + n 
+ 3) + a*b*(c*f*h*(m + 1) - d*(f*g + e*h)*(m + n + 3)) + b*f*h*(b*c - a*d)* 
(m + 1)*x)/(b^2*d*(b*c - a*d)*(m + 1)*(m + n + 3)))*(a + b*x)^(m + 1)*(c + 
d*x)^(n + 1), x] - Simp[(a^2*d^2*f*h*(n + 1)*(n + 2) + a*b*d*(n + 1)*(2*c*f 
*h*(m + 1) - d*(f*g + e*h)*(m + n + 3)) + b^2*(c^2*f*h*(m + 1)*(m + 2) - c* 
d*(f*g + e*h)*(m + 1)*(m + n + 3) + d^2*e*g*(m + n + 2)*(m + n + 3)))/(b^2* 
d*(b*c - a*d)*(m + 1)*(m + n + 3))   Int[(a + b*x)^(m + 1)*(c + d*x)^n, x], 
 x] /; FreeQ[{a, b, c, d, e, f, g, h, m, n}, x] && ((GeQ[m, -2] && LtQ[m, - 
1]) || SumSimplerQ[m, 1]) && NeQ[m, -1] && NeQ[m + n + 3, 0]
 

rule 166
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_) 
)^(p_)*((g_.) + (h_.)*(x_)), x_] :> Simp[(b*g - a*h)*(a + b*x)^(m + 1)*(c + 
 d*x)^n*((e + f*x)^(p + 1)/(b*(b*e - a*f)*(m + 1))), x] - Simp[1/(b*(b*e - 
a*f)*(m + 1))   Int[(a + b*x)^(m + 1)*(c + d*x)^(n - 1)*(e + f*x)^p*Simp[b* 
c*(f*g - e*h)*(m + 1) + (b*g - a*h)*(d*e*n + c*f*(p + 1)) + d*(b*(f*g - e*h 
)*(m + 1) + f*(b*g - a*h)*(n + p + 1))*x, x], x], x] /; FreeQ[{a, b, c, d, 
e, f, g, h, p}, x] && ILtQ[m, -1] && GtQ[n, 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]
 
Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(781\) vs. \(2(361)=722\).

Time = 1.11 (sec) , antiderivative size = 782, normalized size of antiderivative = 2.03

method result size
pseudoelliptic \(\frac {\frac {3 \left (x d +c \right )^{2} \sqrt {f x +e}\, f^{2} \left (a d -b c \right ) \left (\left (-5 a^{2} f^{2} g +4 a e \left (a h +3 b g \right ) f -8 b \,e^{2} \left (a h +b g \right )\right ) d^{3}+\left (\left (a^{2} h -2 g a b \right ) f^{2}-4 b e \left (a h -b g \right ) f +16 b^{2} e^{2} h \right ) c \,d^{2}+2 \left (\left (a h -\frac {b g}{2}\right ) f -8 e h b \right ) c^{2} b f d +5 b^{2} c^{3} f^{2} h \right ) \arctan \left (\frac {d \sqrt {f x +e}}{\sqrt {\left (c f -d e \right ) d}}\right )}{4}+\frac {13 \sqrt {\left (c f -d e \right ) d}\, \left (\frac {\left (-15 a^{3} f^{4} g \,x^{2}-5 a^{2} x \left (-\frac {36 x g b}{5}+a \left (-\frac {12 h x}{5}+g \right )\right ) e \,f^{3}+2 a \left (-12 b^{2} g \,x^{2}+6 a x \left (-2 h x +g \right ) b +a^{2} \left (2 h x +g \right )\right ) e^{2} f^{2}+24 x^{2} b^{2} e^{3} \left (\frac {\left (-h x +g \right ) b}{3}+a h \right ) f -16 b^{3} e^{4} h \,x^{2}\right ) d^{5}}{13}+\frac {2 c \left (-\frac {25 a^{2} x \left (-\frac {9 x g b}{25}+a \left (-\frac {3 h x}{25}+g \right )\right ) f^{4}}{2}-\frac {9 a \left (\frac {8 b^{2} g \,x^{2}}{3}-7 a x \left (-\frac {8 h x}{21}+g \right ) b +a^{2} \left (-\frac {7 h x}{3}+g \right )\right ) e \,f^{3}}{2}+\left (12 x^{3} h \,b^{3}-36 a \,b^{2} g x +3 a^{2} \left (-12 h x +g \right ) b +h \,a^{3}\right ) e^{2} f^{2}+24 \left (\frac {\left (\frac {h x}{2}+g \right ) b}{3}+a h \right ) x \,b^{2} e^{3} f -16 b^{3} e^{4} h x \right ) d^{4}}{13}+c^{2} \left (-\frac {8 a \left (-\frac {3 b^{2} g \,x^{2}}{8}-\frac {15 a x \left (\frac {h x}{5}+g \right ) b}{8}+a^{2} \left (-\frac {5 h x}{8}+g \right )\right ) f^{4}}{13}+\left (\frac {12 x^{2} \left (-2 h x +g \right ) b^{3}}{13}-\frac {15 a x \left (-\frac {12 h x}{5}+g \right ) b^{2}}{13}+3 a^{2} \left (-\frac {5 h x}{13}+g \right ) b +h \,a^{3}\right ) e \,f^{3}-\frac {42 \left (-\frac {2 x \left (2 h x +g \right ) b^{2}}{7}+a \left (-\frac {6 h x}{7}+g \right ) b +a^{2} h \right ) b \,e^{2} f^{2}}{13}+\frac {24 b^{2} e^{3} \left (\frac {\left (5 h x +g \right ) b}{3}+a h \right ) f}{13}-\frac {16 b^{3} e^{4} h}{13}\right ) d^{3}-\frac {3 c^{3} \left (\left (\frac {5 \left (-\frac {8 h x}{5}+g \right ) x \,b^{2}}{3}+a \left (5 h x +g \right ) b +a^{2} h \right ) f^{2}-10 \left (\frac {\left (-\frac {32 h x}{5}+g \right ) b}{3}+a h \right ) b e f -8 b^{2} e^{2} h \right ) \left (f x +e \right ) b f \,d^{2}}{13}-\frac {9 c^{4} \left (f x +e \right ) \left (\left (\frac {\left (-\frac {25 h x}{3}+g \right ) b}{3}+a h \right ) f +\frac {38 e h b}{9}\right ) b^{2} f^{2} d}{13}+\frac {15 b^{3} c^{5} f^{3} h \left (f x +e \right )}{13}\right )}{4}}{d^{3} \left (x d +c \right )^{2} \left (c f -d e \right )^{3} \sqrt {\left (c f -d e \right ) d}\, \sqrt {f x +e}\, f^{2}}\) \(782\)
derivativedivides \(\text {Expression too large to display}\) \(1012\)
default \(\text {Expression too large to display}\) \(1012\)
risch \(\text {Expression too large to display}\) \(1019\)

Input:

int((b*x+a)^3*(h*x+g)/(d*x+c)^3/(f*x+e)^(3/2),x,method=_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*b^2+a* 
(5*h*x+g)*b+a^2*h)*f^2-10*(1/3*(-32/5*h*x+g)*b+a*h)*b*e*f-8*b^2*e^2*h)*(f* 
x+e)*b*f*d^2-9/13*c^4*(f*x+e)*((1/3*(-25/3*h*x+g)*b+a*h)*f+38/9*e*h*b)*b^2 
*f^2*d+15/13*b^3*c^5*f^3*h*(f*x+e)))/(f*x+e)^(1/2)/((c*f-d*e)*d)^(1/2)/(d* 
x+c)^2/(c*f-d*e)^3/d^3/f^2
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 2893 vs. \(2 (361) = 722\).

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

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

Output:

Too large to include
 

Sympy [F(-1)]

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

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

Output:

Timed out
 

Maxima [F(-2)]

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

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

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1383 vs. \(2 (361) = 722\).

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

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

Output:

-3/4*(8*b^3*c*d^3*e^2*g - 8*a*b^2*d^4*e^2*g - 4*b^3*c^2*d^2*e*f*g - 8*a*b^ 
2*c*d^3*e*f*g + 12*a^2*b*d^4*e*f*g + b^3*c^3*d*f^2*g + a*b^2*c^2*d^2*f^2*g 
 + 3*a^2*b*c*d^3*f^2*g - 5*a^3*d^4*f^2*g - 16*b^3*c^2*d^2*e^2*h + 24*a*b^2 
*c*d^3*e^2*h - 8*a^2*b*d^4*e^2*h + 16*b^3*c^3*d*e*f*h - 12*a*b^2*c^2*d^2*e 
*f*h - 8*a^2*b*c*d^3*e*f*h + 4*a^3*d^4*e*f*h - 5*b^3*c^4*f^2*h + 3*a*b^2*c 
^3*d*f^2*h + a^2*b*c^2*d^2*f^2*h + a^3*c*d^3*f^2*h)*arctan(sqrt(f*x + e)*d 
/sqrt(-d^2*e + c*d*f))/((d^6*e^3 - 3*c*d^5*e^2*f + 3*c^2*d^4*e*f^2 - c^3*d 
^3*f^3)*sqrt(-d^2*e + c*d*f)) - 2*(b^3*e^3*f*g - 3*a*b^2*e^2*f^2*g + 3*a^2 
*b*e*f^3*g - a^3*f^4*g - b^3*e^4*h + 3*a*b^2*e^3*f*h - 3*a^2*b*e^2*f^2*h + 
 a^3*e*f^3*h)/((d^3*e^3*f^2 - 3*c*d^2*e^2*f^3 + 3*c^2*d*e*f^4 - c^3*f^5)*s 
qrt(f*x + e)) + 2*sqrt(f*x + e)*b^3*h/(d^3*f^2) - 1/4*(12*(f*x + e)^(3/2)* 
b^3*c^2*d^3*e*f*g - 24*(f*x + e)^(3/2)*a*b^2*c*d^4*e*f*g + 12*(f*x + e)^(3 
/2)*a^2*b*d^5*e*f*g - 12*sqrt(f*x + e)*b^3*c^2*d^3*e^2*f*g + 24*sqrt(f*x + 
 e)*a*b^2*c*d^4*e^2*f*g - 12*sqrt(f*x + e)*a^2*b*d^5*e^2*f*g - 5*(f*x + e) 
^(3/2)*b^3*c^3*d^2*f^2*g + 3*(f*x + e)^(3/2)*a*b^2*c^2*d^3*f^2*g + 9*(f*x 
+ e)^(3/2)*a^2*b*c*d^4*f^2*g - 7*(f*x + e)^(3/2)*a^3*d^5*f^2*g + 15*sqrt(f 
*x + e)*b^3*c^3*d^2*e*f^2*g - 21*sqrt(f*x + e)*a*b^2*c^2*d^3*e*f^2*g - 3*s 
qrt(f*x + e)*a^2*b*c*d^4*e*f^2*g + 9*sqrt(f*x + e)*a^3*d^5*e*f^2*g - 3*sqr 
t(f*x + e)*b^3*c^4*d*f^3*g - 3*sqrt(f*x + e)*a*b^2*c^3*d^2*f^3*g + 15*sqrt 
(f*x + e)*a^2*b*c^2*d^3*f^3*g - 9*sqrt(f*x + e)*a^3*c*d^4*f^3*g - 16*(f...
 

Mupad [B] (verification not implemented)

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

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

Output:

(2*b^3*h*(e + f*x)^(1/2))/(d^3*f^2) - ((2*(a^3*d^3*f^4*g + b^3*d^3*e^4*h - 
 a^3*d^3*e*f^3*h - b^3*d^3*e^3*f*g + 3*a*b^2*d^3*e^2*f^2*g + 3*a^2*b*d^3*e 
^2*f^2*h - 3*a^2*b*d^3*e*f^3*g - 3*a*b^2*d^3*e^3*f*h))/(c*f - d*e) - ((e + 
 f*x)^2*(3*a^3*c*d^4*f^4*h - 8*b^3*d^5*e^4*h - 15*a^3*d^5*f^4*g + 9*b^3*c^ 
4*d*f^4*h + 12*a^3*d^5*e*f^3*h + 8*b^3*d^5*e^3*f*g - 5*b^3*c^3*d^2*f^4*g + 
 3*a*b^2*c^2*d^3*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3*f^2*h...
 

Reduce [B] (verification not implemented)

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

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

Output:

(3*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*s 
qrt(c*f - d*e)))*a**3*c**3*d**3*f**4*h + 12*sqrt(d)*sqrt(e + f*x)*sqrt(c*f 
 - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**3*c**2*d**4*e 
*f**3*h - 15*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/ 
(sqrt(d)*sqrt(c*f - d*e)))*a**3*c**2*d**4*f**4*g + 6*sqrt(d)*sqrt(e + f*x) 
*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**3*c* 
*2*d**4*f**4*h*x + 24*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + 
 f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**3*c*d**5*e*f**3*h*x - 30*sqrt(d)*sq 
rt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e 
)))*a**3*c*d**5*f**4*g*x + 3*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((s 
qrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**3*c*d**5*f**4*h*x**2 + 12*sq 
rt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c 
*f - d*e)))*a**3*d**6*e*f**3*h*x**2 - 15*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - 
d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**3*d**6*f**4*g*x* 
*2 + 3*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt( 
d)*sqrt(c*f - d*e)))*a**2*b*c**4*d**2*f**4*h - 24*sqrt(d)*sqrt(e + f*x)*sq 
rt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**2*b*c** 
3*d**3*e*f**3*h + 9*sqrt(d)*sqrt(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f 
*x)*d)/(sqrt(d)*sqrt(c*f - d*e)))*a**2*b*c**3*d**3*f**4*g + 6*sqrt(d)*sqrt 
(e + f*x)*sqrt(c*f - d*e)*atan((sqrt(e + f*x)*d)/(sqrt(d)*sqrt(c*f - d*...