\(\int (e+f x)^m (a c+(b c+a d) x+b d x^2)^2 \, dx\) [401]

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

Optimal result

Integrand size = 29, antiderivative size = 221 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx=\frac {(b e-a f)^2 (d e-c f)^2 (e+f x)^{1+m}}{f^5 (1+m)}-\frac {2 (b e-a f) (d e-c f) (2 b d e-b c f-a d f) (e+f x)^{2+m}}{f^5 (2+m)}+\frac {\left (a^2 d^2 f^2-2 a b d f (3 d e-2 c f)+b^2 \left (6 d^2 e^2-6 c d e f+c^2 f^2\right )\right ) (e+f x)^{3+m}}{f^5 (3+m)}-\frac {2 b d (2 b d e-b c f-a d f) (e+f x)^{4+m}}{f^5 (4+m)}+\frac {b^2 d^2 (e+f x)^{5+m}}{f^5 (5+m)} \] Output:

(-a*f+b*e)^2*(-c*f+d*e)^2*(f*x+e)^(1+m)/f^5/(1+m)-2*(-a*f+b*e)*(-c*f+d*e)* 
(-a*d*f-b*c*f+2*b*d*e)*(f*x+e)^(2+m)/f^5/(2+m)+(a^2*d^2*f^2-2*a*b*d*f*(-2* 
c*f+3*d*e)+b^2*(c^2*f^2-6*c*d*e*f+6*d^2*e^2))*(f*x+e)^(3+m)/f^5/(3+m)-2*b* 
d*(-a*d*f-b*c*f+2*b*d*e)*(f*x+e)^(4+m)/f^5/(4+m)+b^2*d^2*(f*x+e)^(5+m)/f^5 
/(5+m)
 

Mathematica [A] (verified)

Time = 0.30 (sec) , antiderivative size = 200, normalized size of antiderivative = 0.90 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx=\frac {(e+f x)^{1+m} \left (\frac {(b e-a f)^2 (d e-c f)^2}{1+m}-\frac {2 (b e-a f) (d e-c f) (2 b d e-b c f-a d f) (e+f x)}{2+m}+\frac {\left (a^2 d^2 f^2+2 a b d f (-3 d e+2 c f)+b^2 \left (6 d^2 e^2-6 c d e f+c^2 f^2\right )\right ) (e+f x)^2}{3+m}-\frac {2 b d (2 b d e-b c f-a d f) (e+f x)^3}{4+m}+\frac {b^2 d^2 (e+f x)^4}{5+m}\right )}{f^5} \] Input:

Integrate[(e + f*x)^m*(a*c + (b*c + a*d)*x + b*d*x^2)^2,x]
 

Output:

((e + f*x)^(1 + m)*(((b*e - a*f)^2*(d*e - c*f)^2)/(1 + m) - (2*(b*e - a*f) 
*(d*e - c*f)*(2*b*d*e - b*c*f - a*d*f)*(e + f*x))/(2 + m) + ((a^2*d^2*f^2 
+ 2*a*b*d*f*(-3*d*e + 2*c*f) + b^2*(6*d^2*e^2 - 6*c*d*e*f + c^2*f^2))*(e + 
 f*x)^2)/(3 + m) - (2*b*d*(2*b*d*e - b*c*f - a*d*f)*(e + f*x)^3)/(4 + m) + 
 (b^2*d^2*(e + f*x)^4)/(5 + m)))/f^5
 

Rubi [A] (verified)

Time = 0.44 (sec) , antiderivative size = 221, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.069, Rules used = {1140, 2009}

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 (e+f x)^m \left (x (a d+b c)+a c+b d x^2\right )^2 \, dx\)

\(\Big \downarrow \) 1140

\(\displaystyle \int \left (\frac {(e+f x)^{m+2} \left (a^2 d^2 f^2-2 a b d f (3 d e-2 c f)+b^2 \left (c^2 f^2-6 c d e f+6 d^2 e^2\right )\right )}{f^4}+\frac {(a f-b e)^2 (c f-d e)^2 (e+f x)^m}{f^4}+\frac {2 (a f-b e) (c f-d e) (e+f x)^{m+1} (a d f+b c f-2 b d e)}{f^4}-\frac {2 b d (e+f x)^{m+3} (-a d f-b c f+2 b d e)}{f^4}+\frac {b^2 d^2 (e+f x)^{m+4}}{f^4}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {(e+f x)^{m+3} \left (a^2 d^2 f^2-2 a b d f (3 d e-2 c f)+b^2 \left (c^2 f^2-6 c d e f+6 d^2 e^2\right )\right )}{f^5 (m+3)}+\frac {(b e-a f)^2 (d e-c f)^2 (e+f x)^{m+1}}{f^5 (m+1)}-\frac {2 (b e-a f) (d e-c f) (e+f x)^{m+2} (-a d f-b c f+2 b d e)}{f^5 (m+2)}-\frac {2 b d (e+f x)^{m+4} (-a d f-b c f+2 b d e)}{f^5 (m+4)}+\frac {b^2 d^2 (e+f x)^{m+5}}{f^5 (m+5)}\)

Input:

Int[(e + f*x)^m*(a*c + (b*c + a*d)*x + b*d*x^2)^2,x]
 

Output:

((b*e - a*f)^2*(d*e - c*f)^2*(e + f*x)^(1 + m))/(f^5*(1 + m)) - (2*(b*e - 
a*f)*(d*e - c*f)*(2*b*d*e - b*c*f - a*d*f)*(e + f*x)^(2 + m))/(f^5*(2 + m) 
) + ((a^2*d^2*f^2 - 2*a*b*d*f*(3*d*e - 2*c*f) + b^2*(6*d^2*e^2 - 6*c*d*e*f 
 + c^2*f^2))*(e + f*x)^(3 + m))/(f^5*(3 + m)) - (2*b*d*(2*b*d*e - b*c*f - 
a*d*f)*(e + f*x)^(4 + m))/(f^5*(4 + m)) + (b^2*d^2*(e + f*x)^(5 + m))/(f^5 
*(5 + m))
 

Defintions of rubi rules used

rule 1140
Int[((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x 
_Symbol] :> Int[ExpandIntegrand[(d + e*x)^m*(a + b*x + c*x^2)^p, x], x] /; 
FreeQ[{a, b, c, d, e, m}, x] && IGtQ[p, 0]
 

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 
Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(1400\) vs. \(2(221)=442\).

Time = 1.00 (sec) , antiderivative size = 1401, normalized size of antiderivative = 6.34

method result size
norman \(\text {Expression too large to display}\) \(1401\)
gosper \(\text {Expression too large to display}\) \(1518\)
orering \(\text {Expression too large to display}\) \(1556\)
risch \(\text {Expression too large to display}\) \(2041\)
parallelrisch \(\text {Expression too large to display}\) \(3059\)

Input:

int((f*x+e)^m*(a*c+(a*d+b*c)*x+b*d*x^2)^2,x,method=_RETURNVERBOSE)
 

Output:

b^2*d^2/(5+m)*x^5*exp(m*ln(f*x+e))+e*(a^2*c^2*f^4*m^4+14*a^2*c^2*f^4*m^3-2 
*a^2*c*d*e*f^3*m^3-2*a*b*c^2*e*f^3*m^3+71*a^2*c^2*f^4*m^2-24*a^2*c*d*e*f^3 
*m^2+2*a^2*d^2*e^2*f^2*m^2-24*a*b*c^2*e*f^3*m^2+8*a*b*c*d*e^2*f^2*m^2+2*b^ 
2*c^2*e^2*f^2*m^2+154*a^2*c^2*f^4*m-94*a^2*c*d*e*f^3*m+18*a^2*d^2*e^2*f^2* 
m-94*a*b*c^2*e*f^3*m+72*a*b*c*d*e^2*f^2*m-12*a*b*d^2*e^3*f*m+18*b^2*c^2*e^ 
2*f^2*m-12*b^2*c*d*e^3*f*m+120*a^2*c^2*f^4-120*a^2*c*d*e*f^3+40*a^2*d^2*e^ 
2*f^2-120*a*b*c^2*e*f^3+160*a*b*c*d*e^2*f^2-60*a*b*d^2*e^3*f+40*b^2*c^2*e^ 
2*f^2-60*b^2*c*d*e^3*f+24*b^2*d^2*e^4)/f^5/(m^5+15*m^4+85*m^3+225*m^2+274* 
m+120)*exp(m*ln(f*x+e))+(a^2*d^2*f^2*m^2+4*a*b*c*d*f^2*m^2+2*a*b*d^2*e*f*m 
^2+b^2*c^2*f^2*m^2+2*b^2*c*d*e*f*m^2+9*a^2*d^2*f^2*m+36*a*b*c*d*f^2*m+10*a 
*b*d^2*e*f*m+9*b^2*c^2*f^2*m+10*b^2*c*d*e*f*m-4*b^2*d^2*e^2*m+20*a^2*d^2*f 
^2+80*a*b*c*d*f^2+20*b^2*c^2*f^2)/f^2/(m^3+12*m^2+47*m+60)*x^3*exp(m*ln(f* 
x+e))+(2*a^2*c*d*f^3*m^3+a^2*d^2*e*f^2*m^3+2*a*b*c^2*f^3*m^3+4*a*b*c*d*e*f 
^2*m^3+b^2*c^2*e*f^2*m^3+24*a^2*c*d*f^3*m^2+9*a^2*d^2*e*f^2*m^2+24*a*b*c^2 
*f^3*m^2+36*a*b*c*d*e*f^2*m^2-6*a*b*d^2*e^2*f*m^2+9*b^2*c^2*e*f^2*m^2-6*b^ 
2*c*d*e^2*f*m^2+94*a^2*c*d*f^3*m+20*a^2*d^2*e*f^2*m+94*a*b*c^2*f^3*m+80*a* 
b*c*d*e*f^2*m-30*a*b*d^2*e^2*f*m+20*b^2*c^2*e*f^2*m-30*b^2*c*d*e^2*f*m+12* 
b^2*d^2*e^3*m+120*a^2*c*d*f^3+120*a*b*c^2*f^3)/f^3/(m^4+14*m^3+71*m^2+154* 
m+120)*x^2*exp(m*ln(f*x+e))+(a^2*c^2*f^4*m^4+2*a^2*c*d*e*f^3*m^4+2*a*b*c^2 
*e*f^3*m^4+14*a^2*c^2*f^4*m^3+24*a^2*c*d*e*f^3*m^3-2*a^2*d^2*e^2*f^2*m^...
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1461 vs. \(2 (221) = 442\).

Time = 0.11 (sec) , antiderivative size = 1461, normalized size of antiderivative = 6.61 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx=\text {Too large to display} \] Input:

integrate((f*x+e)^m*(a*c+(a*d+b*c)*x+b*d*x^2)^2,x, algorithm="fricas")
 

Output:

(a^2*c^2*e*f^4*m^4 + 24*b^2*d^2*e^5 + 120*a^2*c^2*e*f^4 - 60*(b^2*c*d + a* 
b*d^2)*e^4*f + 40*(b^2*c^2 + 4*a*b*c*d + a^2*d^2)*e^3*f^2 - 120*(a*b*c^2 + 
 a^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^2)*e^2*f^3 - 5*(b^2*c^2 + 4*a*b*c*d + a^2* 
d^2)*e*f^4 - 13*(a*b*c^2 + a^2*c*d)*f^5)*m^3 + (12*b^2*d^2*e^3*f^2 - 36*(b 
^2*c*d + a*b*d^2)*e^2*f^3 + 29*(b^2*c^2 + 4*a*b*c*d + a^2*d^2)*e*f^4 + 118 
*(a*b*c^2 + a^2*c*d)*f^5)*m^2 + 2*(6*b^2*d^2*e^3*f^2 - 15*(b^2*c*d + a*...
 

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 16288 vs. \(2 (211) = 422\).

Time = 3.63 (sec) , antiderivative size = 16288, normalized size of antiderivative = 73.70 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx=\text {Too large to display} \] Input:

integrate((f*x+e)**m*(a*c+(a*d+b*c)*x+b*d*x**2)**2,x)
 

Output:

Piecewise((e**m*(a**2*c**2*x + a**2*c*d*x**2 + a**2*d**2*x**3/3 + a*b*c**2 
*x**2 + 4*a*b*c*d*x**3/3 + a*b*d**2*x**4/2 + b**2*c**2*x**3/3 + b**2*c*d*x 
**4/2 + b**2*d**2*x**5/5), Eq(f, 0)), (-3*a**2*c**2*f**4/(12*e**4*f**5 + 4 
8*e**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x**4) - 2*a** 
2*c*d*e*f**3/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f** 
8*x**3 + 12*f**9*x**4) - 8*a**2*c*d*f**4*x/(12*e**4*f**5 + 48*e**3*f**6*x 
+ 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x**4) - a**2*d**2*e**2*f**2 
/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 12* 
f**9*x**4) - 4*a**2*d**2*e*f**3*x/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2 
*f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x**4) - 6*a**2*d**2*f**4*x**2/(12*e* 
*4*f**5 + 48*e**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x* 
*4) - 2*a*b*c**2*e*f**3/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2*f**7*x**2 
 + 48*e*f**8*x**3 + 12*f**9*x**4) - 8*a*b*c**2*f**4*x/(12*e**4*f**5 + 48*e 
**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x**4) - 4*a*b*c* 
d*e**2*f**2/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f**8 
*x**3 + 12*f**9*x**4) - 16*a*b*c*d*e*f**3*x/(12*e**4*f**5 + 48*e**3*f**6*x 
 + 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x**4) - 24*a*b*c*d*f**4*x* 
*2/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2*f**7*x**2 + 48*e*f**8*x**3 + 1 
2*f**9*x**4) - 6*a*b*d**2*e**3*f/(12*e**4*f**5 + 48*e**3*f**6*x + 72*e**2* 
f**7*x**2 + 48*e*f**8*x**3 + 12*f**9*x**4) - 24*a*b*d**2*e**2*f**2*x/(1...
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 701 vs. \(2 (221) = 442\).

Time = 0.07 (sec) , antiderivative size = 701, normalized size of antiderivative = 3.17 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx =\text {Too large to display} \] Input:

integrate((f*x+e)^m*(a*c+(a*d+b*c)*x+b*d*x^2)^2,x, algorithm="maxima")
 

Output:

2*(f^2*(m + 1)*x^2 + e*f*m*x - e^2)*(f*x + e)^m*a*b*c^2/((m^2 + 3*m + 2)*f 
^2) + 2*(f^2*(m + 1)*x^2 + e*f*m*x - e^2)*(f*x + e)^m*a^2*c*d/((m^2 + 3*m 
+ 2)*f^2) + (f*x + e)^(m + 1)*a^2*c^2/(f*(m + 1)) + ((m^2 + 3*m + 2)*f^3*x 
^3 + (m^2 + m)*e*f^2*x^2 - 2*e^2*f*m*x + 2*e^3)*(f*x + e)^m*b^2*c^2/((m^3 
+ 6*m^2 + 11*m + 6)*f^3) + 4*((m^2 + 3*m + 2)*f^3*x^3 + (m^2 + m)*e*f^2*x^ 
2 - 2*e^2*f*m*x + 2*e^3)*(f*x + e)^m*a*b*c*d/((m^3 + 6*m^2 + 11*m + 6)*f^3 
) + ((m^2 + 3*m + 2)*f^3*x^3 + (m^2 + m)*e*f^2*x^2 - 2*e^2*f*m*x + 2*e^3)* 
(f*x + e)^m*a^2*d^2/((m^3 + 6*m^2 + 11*m + 6)*f^3) + 2*((m^3 + 6*m^2 + 11* 
m + 6)*f^4*x^4 + (m^3 + 3*m^2 + 2*m)*e*f^3*x^3 - 3*(m^2 + m)*e^2*f^2*x^2 + 
 6*e^3*f*m*x - 6*e^4)*(f*x + e)^m*b^2*c*d/((m^4 + 10*m^3 + 35*m^2 + 50*m + 
 24)*f^4) + 2*((m^3 + 6*m^2 + 11*m + 6)*f^4*x^4 + (m^3 + 3*m^2 + 2*m)*e*f^ 
3*x^3 - 3*(m^2 + m)*e^2*f^2*x^2 + 6*e^3*f*m*x - 6*e^4)*(f*x + e)^m*a*b*d^2 
/((m^4 + 10*m^3 + 35*m^2 + 50*m + 24)*f^4) + ((m^4 + 10*m^3 + 35*m^2 + 50* 
m + 24)*f^5*x^5 + (m^4 + 6*m^3 + 11*m^2 + 6*m)*e*f^4*x^4 - 4*(m^3 + 3*m^2 
+ 2*m)*e^2*f^3*x^3 + 12*(m^2 + m)*e^3*f^2*x^2 - 24*e^4*f*m*x + 24*e^5)*(f* 
x + e)^m*b^2*d^2/((m^5 + 15*m^4 + 85*m^3 + 225*m^2 + 274*m + 120)*f^5)
 

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 2953 vs. \(2 (221) = 442\).

Time = 0.40 (sec) , antiderivative size = 2953, normalized size of antiderivative = 13.36 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx=\text {Too large to display} \] Input:

integrate((f*x+e)^m*(a*c+(a*d+b*c)*x+b*d*x^2)^2,x, algorithm="giac")
 

Output:

((f*x + e)^m*b^2*d^2*f^5*m^4*x^5 + (f*x + e)^m*b^2*d^2*e*f^4*m^4*x^4 + 2*( 
f*x + e)^m*b^2*c*d*f^5*m^4*x^4 + 2*(f*x + e)^m*a*b*d^2*f^5*m^4*x^4 + 10*(f 
*x + e)^m*b^2*d^2*f^5*m^3*x^5 + 2*(f*x + e)^m*b^2*c*d*e*f^4*m^4*x^3 + 2*(f 
*x + e)^m*a*b*d^2*e*f^4*m^4*x^3 + (f*x + e)^m*b^2*c^2*f^5*m^4*x^3 + 4*(f*x 
 + e)^m*a*b*c*d*f^5*m^4*x^3 + (f*x + e)^m*a^2*d^2*f^5*m^4*x^3 + 6*(f*x + e 
)^m*b^2*d^2*e*f^4*m^3*x^4 + 22*(f*x + e)^m*b^2*c*d*f^5*m^3*x^4 + 22*(f*x + 
 e)^m*a*b*d^2*f^5*m^3*x^4 + 35*(f*x + e)^m*b^2*d^2*f^5*m^2*x^5 + (f*x + e) 
^m*b^2*c^2*e*f^4*m^4*x^2 + 4*(f*x + e)^m*a*b*c*d*e*f^4*m^4*x^2 + (f*x + e) 
^m*a^2*d^2*e*f^4*m^4*x^2 + 2*(f*x + e)^m*a*b*c^2*f^5*m^4*x^2 + 2*(f*x + e) 
^m*a^2*c*d*f^5*m^4*x^2 - 4*(f*x + e)^m*b^2*d^2*e^2*f^3*m^3*x^3 + 16*(f*x + 
 e)^m*b^2*c*d*e*f^4*m^3*x^3 + 16*(f*x + e)^m*a*b*d^2*e*f^4*m^3*x^3 + 12*(f 
*x + e)^m*b^2*c^2*f^5*m^3*x^3 + 48*(f*x + e)^m*a*b*c*d*f^5*m^3*x^3 + 12*(f 
*x + e)^m*a^2*d^2*f^5*m^3*x^3 + 11*(f*x + e)^m*b^2*d^2*e*f^4*m^2*x^4 + 82* 
(f*x + e)^m*b^2*c*d*f^5*m^2*x^4 + 82*(f*x + e)^m*a*b*d^2*f^5*m^2*x^4 + 50* 
(f*x + e)^m*b^2*d^2*f^5*m*x^5 + 2*(f*x + e)^m*a*b*c^2*e*f^4*m^4*x + 2*(f*x 
 + e)^m*a^2*c*d*e*f^4*m^4*x + (f*x + e)^m*a^2*c^2*f^5*m^4*x - 6*(f*x + e)^ 
m*b^2*c*d*e^2*f^3*m^3*x^2 - 6*(f*x + e)^m*a*b*d^2*e^2*f^3*m^3*x^2 + 10*(f* 
x + e)^m*b^2*c^2*e*f^4*m^3*x^2 + 40*(f*x + e)^m*a*b*c*d*e*f^4*m^3*x^2 + 10 
*(f*x + e)^m*a^2*d^2*e*f^4*m^3*x^2 + 26*(f*x + e)^m*a*b*c^2*f^5*m^3*x^2 + 
26*(f*x + e)^m*a^2*c*d*f^5*m^3*x^2 - 12*(f*x + e)^m*b^2*d^2*e^2*f^3*m^2...
 

Mupad [B] (verification not implemented)

Time = 6.01 (sec) , antiderivative size = 1509, normalized size of antiderivative = 6.83 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx=\text {Too large to display} \] Input:

int((e + f*x)^m*(a*c + x*(a*d + b*c) + b*d*x^2)^2,x)
 

Output:

((e + f*x)^m*(24*b^2*d^2*e^5 + 120*a^2*c^2*e*f^4 + 40*a^2*d^2*e^3*f^2 + 40 
*b^2*c^2*e^3*f^2 - 60*a*b*d^2*e^4*f - 60*b^2*c*d*e^4*f + 2*a^2*d^2*e^3*f^2 
*m^2 + 2*b^2*c^2*e^3*f^2*m^2 - 120*a*b*c^2*e^2*f^3 - 120*a^2*c*d*e^2*f^3 + 
 154*a^2*c^2*e*f^4*m + 71*a^2*c^2*e*f^4*m^2 + 14*a^2*c^2*e*f^4*m^3 + a^2*c 
^2*e*f^4*m^4 + 18*a^2*d^2*e^3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*c 
^2*f^3 + 120*a^2*c*d*f^3 + 94*a*b*c^2*f^3*m + 94*a^2*c*d*f^3*m + 24*a*b...
 

Reduce [B] (verification not implemented)

Time = 0.24 (sec) , antiderivative size = 2040, normalized size of antiderivative = 9.23 \[ \int (e+f x)^m \left (a c+(b c+a d) x+b d x^2\right )^2 \, dx =\text {Too large to display} \] Input:

int((f*x+e)^m*(a*c+(a*d+b*c)*x+b*d*x^2)^2,x)
 

Output:

((e + f*x)**m*(a**2*c**2*e*f**4*m**4 + 14*a**2*c**2*e*f**4*m**3 + 71*a**2* 
c**2*e*f**4*m**2 + 154*a**2*c**2*e*f**4*m + 120*a**2*c**2*e*f**4 + a**2*c* 
*2*f**5*m**4*x + 14*a**2*c**2*f**5*m**3*x + 71*a**2*c**2*f**5*m**2*x + 154 
*a**2*c**2*f**5*m*x + 120*a**2*c**2*f**5*x - 2*a**2*c*d*e**2*f**3*m**3 - 2 
4*a**2*c*d*e**2*f**3*m**2 - 94*a**2*c*d*e**2*f**3*m - 120*a**2*c*d*e**2*f* 
*3 + 2*a**2*c*d*e*f**4*m**4*x + 24*a**2*c*d*e*f**4*m**3*x + 94*a**2*c*d*e* 
f**4*m**2*x + 120*a**2*c*d*e*f**4*m*x + 2*a**2*c*d*f**5*m**4*x**2 + 26*a** 
2*c*d*f**5*m**3*x**2 + 118*a**2*c*d*f**5*m**2*x**2 + 214*a**2*c*d*f**5*m*x 
**2 + 120*a**2*c*d*f**5*x**2 + 2*a**2*d**2*e**3*f**2*m**2 + 18*a**2*d**2*e 
**3*f**2*m + 40*a**2*d**2*e**3*f**2 - 2*a**2*d**2*e**2*f**3*m**3*x - 18*a* 
*2*d**2*e**2*f**3*m**2*x - 40*a**2*d**2*e**2*f**3*m*x + a**2*d**2*e*f**4*m 
**4*x**2 + 10*a**2*d**2*e*f**4*m**3*x**2 + 29*a**2*d**2*e*f**4*m**2*x**2 + 
 20*a**2*d**2*e*f**4*m*x**2 + a**2*d**2*f**5*m**4*x**3 + 12*a**2*d**2*f**5 
*m**3*x**3 + 49*a**2*d**2*f**5*m**2*x**3 + 78*a**2*d**2*f**5*m*x**3 + 40*a 
**2*d**2*f**5*x**3 - 2*a*b*c**2*e**2*f**3*m**3 - 24*a*b*c**2*e**2*f**3*m** 
2 - 94*a*b*c**2*e**2*f**3*m - 120*a*b*c**2*e**2*f**3 + 2*a*b*c**2*e*f**4*m 
**4*x + 24*a*b*c**2*e*f**4*m**3*x + 94*a*b*c**2*e*f**4*m**2*x + 120*a*b*c* 
*2*e*f**4*m*x + 2*a*b*c**2*f**5*m**4*x**2 + 26*a*b*c**2*f**5*m**3*x**2 + 1 
18*a*b*c**2*f**5*m**2*x**2 + 214*a*b*c**2*f**5*m*x**2 + 120*a*b*c**2*f**5* 
x**2 + 8*a*b*c*d*e**3*f**2*m**2 + 72*a*b*c*d*e**3*f**2*m + 160*a*b*c*d*...