\(\int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} (A+B x+C x^2) \, dx\) [63]

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

Optimal result

Integrand size = 36, antiderivative size = 1353 \[ \int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx =\text {Too large to display} \] Output:

1/512*(-c*f+d*e)*(8*a^2*d^2*f^2*(C*(5*c^2*f^2+6*c*d*e*f+5*d^2*e^2)+8*d*f*( 
2*A*d*f-B*(c*f+d*e)))-8*a*b*d*f*(C*(7*c^3*f^3+9*c^2*d*e*f^2+9*c*d^2*e^2*f+ 
7*d^3*e^3)+2*d*f*(8*A*d*f*(c*f+d*e)-B*(5*c^2*f^2+6*c*d*e*f+5*d^2*e^2)))+b^ 
2*(C*(21*c^4*f^4+28*c^3*d*e*f^3+30*c^2*d^2*e^2*f^2+28*c*d^3*e^3*f+21*d^4*e 
^4)+4*d*f*(2*A*d*f*(5*c^2*f^2+6*c*d*e*f+5*d^2*e^2)-B*(7*c^3*f^3+9*c^2*d*e* 
f^2+9*c*d^2*e^2*f+7*d^3*e^3))))*(d*x+c)^(1/2)*(f*x+e)^(1/2)/d^5/f^5+1/256* 
(8*a^2*d^2*f^2*(C*(5*c^2*f^2+6*c*d*e*f+5*d^2*e^2)+8*d*f*(2*A*d*f-B*(c*f+d* 
e)))-8*a*b*d*f*(C*(7*c^3*f^3+9*c^2*d*e*f^2+9*c*d^2*e^2*f+7*d^3*e^3)+2*d*f* 
(8*A*d*f*(c*f+d*e)-B*(5*c^2*f^2+6*c*d*e*f+5*d^2*e^2)))+b^2*(C*(21*c^4*f^4+ 
28*c^3*d*e*f^3+30*c^2*d^2*e^2*f^2+28*c*d^3*e^3*f+21*d^4*e^4)+4*d*f*(2*A*d* 
f*(5*c^2*f^2+6*c*d*e*f+5*d^2*e^2)-B*(7*c^3*f^3+9*c^2*d*e*f^2+9*c*d^2*e^2*f 
+7*d^3*e^3))))*(d*x+c)^(3/2)*(f*x+e)^(1/2)/d^5/f^4-1/192*(8*a^2*d^2*f^2*(- 
8*B*d*f+11*C*c*f+5*C*d*e)+8*a*b*d*f*(2*d*f*(-8*A*d*f+11*B*c*f+5*B*d*e)-C*( 
25*c^2*f^2+16*c*d*e*f+7*d^2*e^2))+b^2*(C*(107*c^3*f^3+79*c^2*d*e*f^2+49*c* 
d^2*e^2*f+21*d^3*e^3)+4*d*f*(2*A*d*f*(11*c*f+5*d*e)-B*(25*c^2*f^2+16*c*d*e 
*f+7*d^2*e^2))))*(d*x+c)^(3/2)*(f*x+e)^(3/2)/d^4/f^4+1/160*(40*a^2*C*d^2*f 
^2-8*a*b*d*f*(-10*B*d*f+23*C*c*f+7*C*d*e)-b^2*(4*d*f*(-10*A*d*f+23*B*c*f+7 
*B*d*e)-C*(149*c^2*f^2+70*c*d*e*f+21*d^2*e^2)))*(d*x+c)^(5/2)*(f*x+e)^(3/2 
)/d^4/f^3+1/20*b*(8*a*C*d*f-b*(-4*B*d*f+13*C*c*f+3*C*d*e))*(d*x+c)^(7/2)*( 
f*x+e)^(3/2)/d^4/f^2+1/6*b^2*C*(d*x+c)^(9/2)*(f*x+e)^(3/2)/d^4/f-1/512*...
 

Mathematica [A] (verified)

Time = 5.96 (sec) , antiderivative size = 1253, normalized size of antiderivative = 0.93 \[ \int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx =\text {Too large to display} \] Input:

Integrate[(a + b*x)^2*Sqrt[c + d*x]*Sqrt[e + f*x]*(A + B*x + C*x^2),x]
 

Output:

(Sqrt[c + d*x]*Sqrt[e + f*x]*(40*a^2*d^2*f^2*(C*(15*c^3*f^3 - c^2*d*f^2*(7 
*e + 10*f*x) + c*d^2*f*(-7*e^2 + 4*e*f*x + 8*f^2*x^2) + d^3*(15*e^3 - 10*e 
^2*f*x + 8*e*f^2*x^2 + 48*f^3*x^3)) + 8*d*f*(6*A*d*f*(c*f + d*(e + 2*f*x)) 
 + B*(-3*c^2*f^2 + 2*c*d*f*(e + f*x) + d^2*(-3*e^2 + 2*e*f*x + 8*f^2*x^2)) 
)) + 8*a*b*d*f*(C*(-105*c^4*f^4 + 10*c^3*d*f^3*(4*e + 7*f*x) - 2*c^2*d^2*f 
^2*(-17*e^2 + 11*e*f*x + 28*f^2*x^2) + 2*c*d^3*f*(20*e^3 - 11*e^2*f*x + 8* 
e*f^2*x^2 + 24*f^3*x^3) + d^4*(-105*e^4 + 70*e^3*f*x - 56*e^2*f^2*x^2 + 48 
*e*f^3*x^3 + 384*f^4*x^4)) + 10*d*f*(8*A*d*f*(-3*c^2*f^2 + 2*c*d*f*(e + f* 
x) + d^2*(-3*e^2 + 2*e*f*x + 8*f^2*x^2)) + B*(15*c^3*f^3 - c^2*d*f^2*(7*e 
+ 10*f*x) + c*d^2*f*(-7*e^2 + 4*e*f*x + 8*f^2*x^2) + d^3*(15*e^3 - 10*e^2* 
f*x + 8*e*f^2*x^2 + 48*f^3*x^3)))) + b^2*(C*(315*c^5*f^5 - 105*c^4*d*f^4*( 
e + 2*f*x) + 2*c^3*d^2*f^3*(-41*e^2 + 28*e*f*x + 84*f^2*x^2) - 2*c^2*d^3*f 
^2*(41*e^3 - 26*e^2*f*x + 20*e*f^2*x^2 + 72*f^3*x^3) + c*d^4*f*(-105*e^4 + 
 56*e^3*f*x - 40*e^2*f^2*x^2 + 32*e*f^3*x^3 + 128*f^4*x^4) + d^5*(315*e^5 
- 210*e^4*f*x + 168*e^3*f^2*x^2 - 144*e^2*f^3*x^3 + 128*e*f^4*x^4 + 1280*f 
^5*x^5)) + 4*d*f*(10*A*d*f*(15*c^3*f^3 - c^2*d*f^2*(7*e + 10*f*x) + c*d^2* 
f*(-7*e^2 + 4*e*f*x + 8*f^2*x^2) + d^3*(15*e^3 - 10*e^2*f*x + 8*e*f^2*x^2 
+ 48*f^3*x^3)) + B*(-105*c^4*f^4 + 10*c^3*d*f^3*(4*e + 7*f*x) - 2*c^2*d^2* 
f^2*(-17*e^2 + 11*e*f*x + 28*f^2*x^2) + 2*c*d^3*f*(20*e^3 - 11*e^2*f*x + 8 
*e*f^2*x^2 + 24*f^3*x^3) + d^4*(-105*e^4 + 70*e^3*f*x - 56*e^2*f^2*x^2 ...
 

Rubi [A] (verified)

Time = 1.36 (sec) , antiderivative size = 815, normalized size of antiderivative = 0.60, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {2118, 27, 170, 27, 164, 60, 60, 66, 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 (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx\)

\(\Big \downarrow \) 2118

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

\(\Big \downarrow \) 27

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

\(\Big \downarrow \) 170

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\int \frac {1}{2} (a+b x) \sqrt {c+d x} \sqrt {e+f x} (10 a d f (2 b c C e+a C d e+a c C f-4 A b d f)+(4 b c e+3 a (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))+(10 b d f (2 b c C e+a C d e+a c C f-4 A b d f)-(4 a d f-7 b (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))) x)dx}{5 d f}-\frac {(a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2} (-2 a C d f+4 b B d f-3 b C (c f+d e))}{5 d f}}{4 b d f}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\int (a+b x) \sqrt {c+d x} \sqrt {e+f x} (10 a d f (2 b c C e+a C d e+a c C f-4 A b d f)+(4 b c e+3 a (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))+(10 b d f (2 b c C e+a C d e+a c C f-4 A b d f)-(4 a d f-7 b (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))) x)dx}{10 d f}-\frac {(a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2} (-2 a C d f+4 b B d f-3 b C (c f+d e))}{5 d f}}{4 b d f}\)

\(\Big \downarrow \) 164

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\frac {(c+d x)^{3/2} (e+f x)^{3/2} \left (64 a^3 C d^3 f^3-8 a^2 b d^2 f^2 (16 B d f-7 C (c f+d e))-8 a b^2 d f \left (10 d f (8 A d f-5 B (c f+d e))+C \left (35 c^2 f^2+38 c d e f+35 d^2 e^2\right )\right )+6 b d f x (10 b d f (a c C f+a C d e-4 A b d f+2 b c C e)-(4 a d f-7 b (c f+d e)) (-2 a C d f+4 b B d f-3 b C (c f+d e)))+b^3 \left (4 d f \left (50 A d f (c f+d e)-B \left (35 c^2 f^2+38 c d e f+35 d^2 e^2\right )\right )+7 C \left (15 c^3 f^3+17 c^2 d e f^2+17 c d^2 e^2 f+15 d^3 e^3\right )\right )\right )}{24 d^2 f^2}-\frac {5 b \left (8 a^2 d^2 f^2 \left (8 d f (2 A d f-B (c f+d e))+C \left (5 c^2 f^2+6 c d e f+5 d^2 e^2\right )\right )-8 a b d f \left (2 d f \left (8 A d f (c f+d e)-B \left (5 c^2 f^2+6 c d e f+5 d^2 e^2\right )\right )+C \left (7 c^3 f^3+9 c^2 d e f^2+9 c d^2 e^2 f+7 d^3 e^3\right )\right )+b^2 \left (4 d f \left (2 A d f \left (5 c^2 f^2+6 c d e f+5 d^2 e^2\right )-B \left (7 c^3 f^3+9 c^2 d e f^2+9 c d^2 e^2 f+7 d^3 e^3\right )\right )+C \left (21 c^4 f^4+28 c^3 d e f^3+30 c^2 d^2 e^2 f^2+28 c d^3 e^3 f+21 d^4 e^4\right )\right )\right ) \int \sqrt {c+d x} \sqrt {e+f x}dx}{16 d^2 f^2}}{10 d f}-\frac {(a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2} (-2 a C d f+4 b B d f-3 b C (c f+d e))}{5 d f}}{4 b d f}\)

\(\Big \downarrow \) 60

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\frac {(c+d x)^{3/2} (e+f x)^{3/2} \left (64 a^3 C d^3 f^3-8 a^2 b d^2 f^2 (16 B d f-7 C (c f+d e))-8 a b^2 d f \left (10 d f (8 A d f-5 B (c f+d e))+C \left (35 c^2 f^2+38 c d e f+35 d^2 e^2\right )\right )+6 b d f x (10 b d f (a c C f+a C d e-4 A b d f+2 b c C e)-(4 a d f-7 b (c f+d e)) (-2 a C d f+4 b B d f-3 b C (c f+d e)))+b^3 \left (4 d f \left (50 A d f (c f+d e)-B \left (35 c^2 f^2+38 c d e f+35 d^2 e^2\right )\right )+7 C \left (15 c^3 f^3+17 c^2 d e f^2+17 c d^2 e^2 f+15 d^3 e^3\right )\right )\right )}{24 d^2 f^2}-\frac {5 b \left (8 a^2 d^2 f^2 \left (8 d f (2 A d f-B (c f+d e))+C \left (5 c^2 f^2+6 c d e f+5 d^2 e^2\right )\right )-8 a b d f \left (2 d f \left (8 A d f (c f+d e)-B \left (5 c^2 f^2+6 c d e f+5 d^2 e^2\right )\right )+C \left (7 c^3 f^3+9 c^2 d e f^2+9 c d^2 e^2 f+7 d^3 e^3\right )\right )+b^2 \left (4 d f \left (2 A d f \left (5 c^2 f^2+6 c d e f+5 d^2 e^2\right )-B \left (7 c^3 f^3+9 c^2 d e f^2+9 c d^2 e^2 f+7 d^3 e^3\right )\right )+C \left (21 c^4 f^4+28 c^3 d e f^3+30 c^2 d^2 e^2 f^2+28 c d^3 e^3 f+21 d^4 e^4\right )\right )\right ) \left (\frac {(d e-c f) \int \frac {\sqrt {c+d x}}{\sqrt {e+f x}}dx}{4 d}+\frac {(c+d x)^{3/2} \sqrt {e+f x}}{2 d}\right )}{16 d^2 f^2}}{10 d f}-\frac {(a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2} (-2 a C d f+4 b B d f-3 b C (c f+d e))}{5 d f}}{4 b d f}\)

\(\Big \downarrow \) 60

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\frac {(c+d x)^{3/2} (e+f x)^{3/2} \left (\left (7 C \left (15 d^3 e^3+17 c d^2 f e^2+17 c^2 d f^2 e+15 c^3 f^3\right )+4 d f \left (50 A d f (d e+c f)-B \left (35 d^2 e^2+38 c d f e+35 c^2 f^2\right )\right )\right ) b^3-8 a d f \left (C \left (35 d^2 e^2+38 c d f e+35 c^2 f^2\right )+10 d f (8 A d f-5 B (d e+c f))\right ) b^2-8 a^2 d^2 f^2 (16 B d f-7 C (d e+c f)) b+6 d f (10 b d f (2 b c C e+a C d e+a c C f-4 A b d f)-(4 a d f-7 b (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))) x b+64 a^3 C d^3 f^3\right )}{24 d^2 f^2}-\frac {5 b \left (\left (C \left (21 d^4 e^4+28 c d^3 f e^3+30 c^2 d^2 f^2 e^2+28 c^3 d f^3 e+21 c^4 f^4\right )+4 d f \left (2 A d f \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )-B \left (7 d^3 e^3+9 c d^2 f e^2+9 c^2 d f^2 e+7 c^3 f^3\right )\right )\right ) b^2-8 a d f \left (C \left (7 d^3 e^3+9 c d^2 f e^2+9 c^2 d f^2 e+7 c^3 f^3\right )+2 d f \left (8 A d f (d e+c f)-B \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )\right )\right ) b+8 a^2 d^2 f^2 \left (C \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )+8 d f (2 A d f-B (d e+c f))\right )\right ) \left (\frac {\sqrt {e+f x} (c+d x)^{3/2}}{2 d}+\frac {(d e-c f) \left (\frac {\sqrt {c+d x} \sqrt {e+f x}}{f}-\frac {(d e-c f) \int \frac {1}{\sqrt {c+d x} \sqrt {e+f x}}dx}{2 f}\right )}{4 d}\right )}{16 d^2 f^2}}{10 d f}-\frac {(4 b B d f-2 a C d f-3 b C (d e+c f)) (a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2}}{5 d f}}{4 b d f}\)

\(\Big \downarrow \) 66

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\frac {(c+d x)^{3/2} (e+f x)^{3/2} \left (\left (7 C \left (15 d^3 e^3+17 c d^2 f e^2+17 c^2 d f^2 e+15 c^3 f^3\right )+4 d f \left (50 A d f (d e+c f)-B \left (35 d^2 e^2+38 c d f e+35 c^2 f^2\right )\right )\right ) b^3-8 a d f \left (C \left (35 d^2 e^2+38 c d f e+35 c^2 f^2\right )+10 d f (8 A d f-5 B (d e+c f))\right ) b^2-8 a^2 d^2 f^2 (16 B d f-7 C (d e+c f)) b+6 d f (10 b d f (2 b c C e+a C d e+a c C f-4 A b d f)-(4 a d f-7 b (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))) x b+64 a^3 C d^3 f^3\right )}{24 d^2 f^2}-\frac {5 b \left (\left (C \left (21 d^4 e^4+28 c d^3 f e^3+30 c^2 d^2 f^2 e^2+28 c^3 d f^3 e+21 c^4 f^4\right )+4 d f \left (2 A d f \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )-B \left (7 d^3 e^3+9 c d^2 f e^2+9 c^2 d f^2 e+7 c^3 f^3\right )\right )\right ) b^2-8 a d f \left (C \left (7 d^3 e^3+9 c d^2 f e^2+9 c^2 d f^2 e+7 c^3 f^3\right )+2 d f \left (8 A d f (d e+c f)-B \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )\right )\right ) b+8 a^2 d^2 f^2 \left (C \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )+8 d f (2 A d f-B (d e+c f))\right )\right ) \left (\frac {\sqrt {e+f x} (c+d x)^{3/2}}{2 d}+\frac {(d e-c f) \left (\frac {\sqrt {c+d x} \sqrt {e+f x}}{f}-\frac {(d e-c f) \int \frac {1}{d-\frac {f (c+d x)}{e+f x}}d\frac {\sqrt {c+d x}}{\sqrt {e+f x}}}{f}\right )}{4 d}\right )}{16 d^2 f^2}}{10 d f}-\frac {(4 b B d f-2 a C d f-3 b C (d e+c f)) (a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2}}{5 d f}}{4 b d f}\)

\(\Big \downarrow \) 221

\(\displaystyle \frac {C (a+b x)^3 (c+d x)^{3/2} (e+f x)^{3/2}}{6 b d f}-\frac {\frac {\frac {(c+d x)^{3/2} (e+f x)^{3/2} \left (\left (7 C \left (15 d^3 e^3+17 c d^2 f e^2+17 c^2 d f^2 e+15 c^3 f^3\right )+4 d f \left (50 A d f (d e+c f)-B \left (35 d^2 e^2+38 c d f e+35 c^2 f^2\right )\right )\right ) b^3-8 a d f \left (C \left (35 d^2 e^2+38 c d f e+35 c^2 f^2\right )+10 d f (8 A d f-5 B (d e+c f))\right ) b^2-8 a^2 d^2 f^2 (16 B d f-7 C (d e+c f)) b+6 d f (10 b d f (2 b c C e+a C d e+a c C f-4 A b d f)-(4 a d f-7 b (d e+c f)) (4 b B d f-2 a C d f-3 b C (d e+c f))) x b+64 a^3 C d^3 f^3\right )}{24 d^2 f^2}-\frac {5 b \left (\left (C \left (21 d^4 e^4+28 c d^3 f e^3+30 c^2 d^2 f^2 e^2+28 c^3 d f^3 e+21 c^4 f^4\right )+4 d f \left (2 A d f \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )-B \left (7 d^3 e^3+9 c d^2 f e^2+9 c^2 d f^2 e+7 c^3 f^3\right )\right )\right ) b^2-8 a d f \left (C \left (7 d^3 e^3+9 c d^2 f e^2+9 c^2 d f^2 e+7 c^3 f^3\right )+2 d f \left (8 A d f (d e+c f)-B \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )\right )\right ) b+8 a^2 d^2 f^2 \left (C \left (5 d^2 e^2+6 c d f e+5 c^2 f^2\right )+8 d f (2 A d f-B (d e+c f))\right )\right ) \left (\frac {\sqrt {e+f x} (c+d x)^{3/2}}{2 d}+\frac {(d e-c f) \left (\frac {\sqrt {c+d x} \sqrt {e+f x}}{f}-\frac {(d e-c f) \text {arctanh}\left (\frac {\sqrt {f} \sqrt {c+d x}}{\sqrt {d} \sqrt {e+f x}}\right )}{\sqrt {d} f^{3/2}}\right )}{4 d}\right )}{16 d^2 f^2}}{10 d f}-\frac {(4 b B d f-2 a C d f-3 b C (d e+c f)) (a+b x)^2 (c+d x)^{3/2} (e+f x)^{3/2}}{5 d f}}{4 b d f}\)

Input:

Int[(a + b*x)^2*Sqrt[c + d*x]*Sqrt[e + f*x]*(A + B*x + C*x^2),x]
 

Output:

(C*(a + b*x)^3*(c + d*x)^(3/2)*(e + f*x)^(3/2))/(6*b*d*f) - (-1/5*((4*b*B* 
d*f - 2*a*C*d*f - 3*b*C*(d*e + c*f))*(a + b*x)^2*(c + d*x)^(3/2)*(e + f*x) 
^(3/2))/(d*f) + (((c + d*x)^(3/2)*(e + f*x)^(3/2)*(64*a^3*C*d^3*f^3 - 8*a^ 
2*b*d^2*f^2*(16*B*d*f - 7*C*(d*e + c*f)) - 8*a*b^2*d*f*(C*(35*d^2*e^2 + 38 
*c*d*e*f + 35*c^2*f^2) + 10*d*f*(8*A*d*f - 5*B*(d*e + c*f))) + b^3*(7*C*(1 
5*d^3*e^3 + 17*c*d^2*e^2*f + 17*c^2*d*e*f^2 + 15*c^3*f^3) + 4*d*f*(50*A*d* 
f*(d*e + c*f) - B*(35*d^2*e^2 + 38*c*d*e*f + 35*c^2*f^2))) + 6*b*d*f*(10*b 
*d*f*(2*b*c*C*e + a*C*d*e + a*c*C*f - 4*A*b*d*f) - (4*a*d*f - 7*b*(d*e + c 
*f))*(4*b*B*d*f - 2*a*C*d*f - 3*b*C*(d*e + c*f)))*x))/(24*d^2*f^2) - (5*b* 
(8*a^2*d^2*f^2*(C*(5*d^2*e^2 + 6*c*d*e*f + 5*c^2*f^2) + 8*d*f*(2*A*d*f - B 
*(d*e + c*f))) - 8*a*b*d*f*(C*(7*d^3*e^3 + 9*c*d^2*e^2*f + 9*c^2*d*e*f^2 + 
 7*c^3*f^3) + 2*d*f*(8*A*d*f*(d*e + c*f) - B*(5*d^2*e^2 + 6*c*d*e*f + 5*c^ 
2*f^2))) + b^2*(C*(21*d^4*e^4 + 28*c*d^3*e^3*f + 30*c^2*d^2*e^2*f^2 + 28*c 
^3*d*e*f^3 + 21*c^4*f^4) + 4*d*f*(2*A*d*f*(5*d^2*e^2 + 6*c*d*e*f + 5*c^2*f 
^2) - B*(7*d^3*e^3 + 9*c*d^2*e^2*f + 9*c^2*d*e*f^2 + 7*c^3*f^3))))*(((c + 
d*x)^(3/2)*Sqrt[e + f*x])/(2*d) + ((d*e - c*f)*((Sqrt[c + d*x]*Sqrt[e + f* 
x])/f - ((d*e - c*f)*ArcTanh[(Sqrt[f]*Sqrt[c + d*x])/(Sqrt[d]*Sqrt[e + f*x 
])])/(Sqrt[d]*f^(3/2))))/(4*d)))/(16*d^2*f^2))/(10*d*f))/(4*b*d*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 60
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[ 
(a + b*x)^(m + 1)*((c + d*x)^n/(b*(m + n + 1))), x] + Simp[n*((b*c - a*d)/( 
b*(m + n + 1)))   Int[(a + b*x)^m*(c + d*x)^(n - 1), x], x] /; FreeQ[{a, b, 
 c, d}, x] && GtQ[n, 0] && NeQ[m + n + 1, 0] &&  !(IGtQ[m, 0] && ( !Integer 
Q[n] || (GtQ[m, 0] && LtQ[m - n, 0]))) &&  !ILtQ[m + n + 2, 0] && IntLinear 
Q[a, b, c, d, m, n, x]
 

rule 66
Int[1/(Sqrt[(a_) + (b_.)*(x_)]*Sqrt[(c_) + (d_.)*(x_)]), x_Symbol] :> Simp[ 
2   Subst[Int[1/(b - d*x^2), x], x, Sqrt[a + b*x]/Sqrt[c + d*x]], x] /; Fre 
eQ[{a, b, c, d}, x] &&  !GtQ[c - a*(d/b), 0]
 

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

rule 170
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] 
 && IntegerQ[m]
 

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 2118
Int[(Px_)*((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f 
_.)*(x_))^(p_.), x_Symbol] :> With[{q = Expon[Px, x], k = Coeff[Px, x, Expo 
n[Px, x]]}, Simp[k*(a + b*x)^(m + q - 1)*(c + d*x)^(n + 1)*((e + f*x)^(p + 
1)/(d*f*b^(q - 1)*(m + n + p + q + 1))), x] + Simp[1/(d*f*b^q*(m + n + p + 
q + 1))   Int[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p*ExpandToSum[d*f*b^q*(m + 
n + p + q + 1)*Px - d*f*k*(m + n + p + q + 1)*(a + b*x)^q + k*(a + b*x)^(q 
- 2)*(a^2*d*f*(m + n + p + q + 1) - b*(b*c*e*(m + q - 1) + a*(d*e*(n + 1) + 
 c*f*(p + 1))) + b*(a*d*f*(2*(m + q) + n + p) - b*(d*e*(m + q + n) + c*f*(m 
 + q + p)))*x), x], x], x] /; NeQ[m + n + p + q + 1, 0]] /; FreeQ[{a, b, c, 
 d, e, f, m, n, p}, x] && PolyQ[Px, x]
 
Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(5733\) vs. \(2(1303)=2606\).

Time = 0.62 (sec) , antiderivative size = 5734, normalized size of antiderivative = 4.24

method result size
default \(\text {Expression too large to display}\) \(5734\)

Input:

int((b*x+a)^2*(d*x+c)^(1/2)*(f*x+e)^(1/2)*(C*x^2+B*x+A),x,method=_RETURNVE 
RBOSE)
 

Output:

result too large to display
 

Fricas [A] (verification not implemented)

Time = 1.31 (sec) , antiderivative size = 3096, normalized size of antiderivative = 2.29 \[ \int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx=\text {Too large to display} \] Input:

integrate((b*x+a)^2*(d*x+c)^(1/2)*(f*x+e)^(1/2)*(C*x^2+B*x+A),x, algorithm 
="fricas")
 

Output:

Too large to include
 

Sympy [F]

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

integrate((b*x+a)**2*(d*x+c)**(1/2)*(f*x+e)**(1/2)*(C*x**2+B*x+A),x)
 

Output:

Integral((a + b*x)**2*sqrt(c + d*x)*sqrt(e + f*x)*(A + B*x + C*x**2), x)
 

Maxima [F(-2)]

Exception generated. \[ \int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx=\text {Exception raised: ValueError} \] Input:

integrate((b*x+a)^2*(d*x+c)^(1/2)*(f*x+e)^(1/2)*(C*x^2+B*x+A),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. 4456 vs. \(2 (1303) = 2606\).

Time = 0.71 (sec) , antiderivative size = 4456, normalized size of antiderivative = 3.29 \[ \int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx=\text {Too large to display} \] Input:

integrate((b*x+a)^2*(d*x+c)^(1/2)*(f*x+e)^(1/2)*(C*x^2+B*x+A),x, algorithm 
="giac")
 

Output:

-1/7680*(7680*((d^2*e - c*d*f)*log(abs(-sqrt(d*f)*sqrt(d*x + c) + sqrt(d^2 
*e + (d*x + c)*d*f - c*d*f)))/sqrt(d*f) - sqrt(d^2*e + (d*x + c)*d*f - c*d 
*f)*sqrt(d*x + c))*A*a^2*c*abs(d)/d^2 - 80*(sqrt(d^2*e + (d*x + c)*d*f - c 
*d*f)*(2*(d*x + c)*(4*(d*x + c)*(6*(d*x + c)/d^3 + (d^12*e*f^5 - 25*c*d^11 
*f^6)/(d^14*f^6)) - (5*d^13*e^2*f^4 + 14*c*d^12*e*f^5 - 163*c^2*d^11*f^6)/ 
(d^14*f^6)) + 3*(5*d^14*e^3*f^3 + 9*c*d^13*e^2*f^4 + 15*c^2*d^12*e*f^5 - 9 
3*c^3*d^11*f^6)/(d^14*f^6))*sqrt(d*x + c) + 3*(5*d^4*e^4 + 4*c*d^3*e^3*f + 
 6*c^2*d^2*e^2*f^2 + 20*c^3*d*e*f^3 - 35*c^4*f^4)*log(abs(-sqrt(d*f)*sqrt( 
d*x + c) + sqrt(d^2*e + (d*x + c)*d*f - c*d*f)))/(sqrt(d*f)*d^2*f^3))*C*a* 
b*c*abs(d)/d^2 - 40*(sqrt(d^2*e + (d*x + c)*d*f - c*d*f)*(2*(d*x + c)*(4*( 
d*x + c)*(6*(d*x + c)/d^3 + (d^12*e*f^5 - 25*c*d^11*f^6)/(d^14*f^6)) - (5* 
d^13*e^2*f^4 + 14*c*d^12*e*f^5 - 163*c^2*d^11*f^6)/(d^14*f^6)) + 3*(5*d^14 
*e^3*f^3 + 9*c*d^13*e^2*f^4 + 15*c^2*d^12*e*f^5 - 93*c^3*d^11*f^6)/(d^14*f 
^6))*sqrt(d*x + c) + 3*(5*d^4*e^4 + 4*c*d^3*e^3*f + 6*c^2*d^2*e^2*f^2 + 20 
*c^3*d*e*f^3 - 35*c^4*f^4)*log(abs(-sqrt(d*f)*sqrt(d*x + c) + sqrt(d^2*e + 
 (d*x + c)*d*f - c*d*f)))/(sqrt(d*f)*d^2*f^3))*B*b^2*c*abs(d)/d^2 - 40*(sq 
rt(d^2*e + (d*x + c)*d*f - c*d*f)*(2*(d*x + c)*(4*(d*x + c)*(6*(d*x + c)/d 
^3 + (d^12*e*f^5 - 25*c*d^11*f^6)/(d^14*f^6)) - (5*d^13*e^2*f^4 + 14*c*d^1 
2*e*f^5 - 163*c^2*d^11*f^6)/(d^14*f^6)) + 3*(5*d^14*e^3*f^3 + 9*c*d^13*e^2 
*f^4 + 15*c^2*d^12*e*f^5 - 93*c^3*d^11*f^6)/(d^14*f^6))*sqrt(d*x + c) +...
 

Mupad [F(-1)]

Timed out. \[ \int (a+b x)^2 \sqrt {c+d x} \sqrt {e+f x} \left (A+B x+C x^2\right ) \, dx=\text {Hanged} \] Input:

int((e + f*x)^(1/2)*(a + b*x)^2*(c + d*x)^(1/2)*(A + B*x + C*x^2),x)
                                                                                    
                                                                                    
 

Output:

\text{Hanged}
 

Reduce [F]

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

int((b*x+a)^2*(d*x+c)^(1/2)*(f*x+e)^(1/2)*(C*x^2+B*x+A),x)
 

Output:

int((b*x+a)^2*(d*x+c)^(1/2)*(f*x+e)^(1/2)*(C*x^2+B*x+A),x)