### 3.2086 $$\int (d+e x)^m (a d e+(c d^2+a e^2) x+c d e x^2) \, dx$$

Optimal. Leaf size=52 $\frac{c d (d+e x)^{m+3}}{e^2 (m+3)}-\frac{\left (c d^2-a e^2\right ) (d+e x)^{m+2}}{e^2 (m+2)}$

[Out]

-(((c*d^2 - a*e^2)*(d + e*x)^(2 + m))/(e^2*(2 + m))) + (c*d*(d + e*x)^(3 + m))/(e^2*(3 + m))

________________________________________________________________________________________

Rubi [A]  time = 0.025133, antiderivative size = 52, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 33, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.061, Rules used = {626, 43} $\frac{c d (d+e x)^{m+3}}{e^2 (m+3)}-\frac{\left (c d^2-a e^2\right ) (d+e x)^{m+2}}{e^2 (m+2)}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

-(((c*d^2 - a*e^2)*(d + e*x)^(2 + m))/(e^2*(2 + m))) + (c*d*(d + e*x)^(3 + m))/(e^2*(3 + m))

Rule 626

Int[((d_) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[(d + e*x)^(m + p)*(a
/d + (c*x)/e)^p, x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b^2 - 4*a*c, 0] && EqQ[c*d^2 - b*d*e + a*e^2, 0] &&
IntegerQ[p]

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin{align*} \int (d+e x)^m \left (a d e+\left (c d^2+a e^2\right ) x+c d e x^2\right ) \, dx &=\int (a e+c d x) (d+e x)^{1+m} \, dx\\ &=\int \left (\frac{\left (-c d^2+a e^2\right ) (d+e x)^{1+m}}{e}+\frac{c d (d+e x)^{2+m}}{e}\right ) \, dx\\ &=-\frac{\left (c d^2-a e^2\right ) (d+e x)^{2+m}}{e^2 (2+m)}+\frac{c d (d+e x)^{3+m}}{e^2 (3+m)}\\ \end{align*}

Mathematica [A]  time = 0.0361307, size = 45, normalized size = 0.87 $\frac{(d+e x)^{m+2} \left (a e^2 (m+3)+c d (e (m+2) x-d)\right )}{e^2 (m+2) (m+3)}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

((d + e*x)^(2 + m)*(a*e^2*(3 + m) + c*d*(-d + e*(2 + m)*x)))/(e^2*(2 + m)*(3 + m))

________________________________________________________________________________________

Maple [A]  time = 0.045, size = 55, normalized size = 1.1 \begin{align*}{\frac{ \left ( ex+d \right ) ^{2+m} \left ( cdemx+a{e}^{2}m+2\,cdex+3\,a{e}^{2}-c{d}^{2} \right ) }{{e}^{2} \left ({m}^{2}+5\,m+6 \right ) }} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [B]  time = 1.93392, size = 277, normalized size = 5.33 \begin{align*} \frac{{\left (a d^{2} e^{2} m - c d^{4} + 3 \, a d^{2} e^{2} +{\left (c d e^{3} m + 2 \, c d e^{3}\right )} x^{3} +{\left (3 \, c d^{2} e^{2} + 3 \, a e^{4} +{\left (2 \, c d^{2} e^{2} + a e^{4}\right )} m\right )} x^{2} +{\left (6 \, a d e^{3} +{\left (c d^{3} e + 2 \, a d e^{3}\right )} m\right )} x\right )}{\left (e x + d\right )}^{m}}{e^{2} m^{2} + 5 \, e^{2} m + 6 \, e^{2}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Sympy [A]  time = 1.3552, size = 556, normalized size = 10.69 \begin{align*} \begin{cases} \frac{c d^{2} d^{m} x^{2}}{2} & \text{for}\: e = 0 \\- \frac{a e^{2}}{d e^{2} + e^{3} x} + \frac{c d^{2} \log{\left (\frac{d}{e} + x \right )}}{d e^{2} + e^{3} x} + \frac{c d^{2}}{d e^{2} + e^{3} x} + \frac{c d e x \log{\left (\frac{d}{e} + x \right )}}{d e^{2} + e^{3} x} & \text{for}\: m = -3 \\a \log{\left (\frac{d}{e} + x \right )} - \frac{c d^{2} \log{\left (\frac{d}{e} + x \right )}}{e^{2}} + \frac{c d x}{e} & \text{for}\: m = -2 \\\frac{a d^{2} e^{2} m \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{3 a d^{2} e^{2} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{2 a d e^{3} m x \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{6 a d e^{3} x \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{a e^{4} m x^{2} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{3 a e^{4} x^{2} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} - \frac{c d^{4} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{c d^{3} e m x \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{2 c d^{2} e^{2} m x^{2} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{3 c d^{2} e^{2} x^{2} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{c d e^{3} m x^{3} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} + \frac{2 c d e^{3} x^{3} \left (d + e x\right )^{m}}{e^{2} m^{2} + 5 e^{2} m + 6 e^{2}} & \text{otherwise} \end{cases} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Piecewise((c*d**2*d**m*x**2/2, Eq(e, 0)), (-a*e**2/(d*e**2 + e**3*x) + c*d**2*log(d/e + x)/(d*e**2 + e**3*x) +
c*d**2/(d*e**2 + e**3*x) + c*d*e*x*log(d/e + x)/(d*e**2 + e**3*x), Eq(m, -3)), (a*log(d/e + x) - c*d**2*log(d
/e + x)/e**2 + c*d*x/e, Eq(m, -2)), (a*d**2*e**2*m*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) + 3*a*d**2*e**
2*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) + 2*a*d*e**3*m*x*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) +
6*a*d*e**3*x*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) + a*e**4*m*x**2*(d + e*x)**m/(e**2*m**2 + 5*e**2*m
+ 6*e**2) + 3*a*e**4*x**2*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) - c*d**4*(d + e*x)**m/(e**2*m**2 + 5*e*
*2*m + 6*e**2) + c*d**3*e*m*x*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) + 2*c*d**2*e**2*m*x**2*(d + e*x)**m
/(e**2*m**2 + 5*e**2*m + 6*e**2) + 3*c*d**2*e**2*x**2*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) + c*d*e**3*
m*x**3*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e**2) + 2*c*d*e**3*x**3*(d + e*x)**m/(e**2*m**2 + 5*e**2*m + 6*e
**2), True))

________________________________________________________________________________________

Giac [B]  time = 1.12733, size = 296, normalized size = 5.69 \begin{align*} \frac{{\left (x e + d\right )}^{m} c d m x^{3} e^{3} + 2 \,{\left (x e + d\right )}^{m} c d^{2} m x^{2} e^{2} +{\left (x e + d\right )}^{m} c d^{3} m x e + 2 \,{\left (x e + d\right )}^{m} c d x^{3} e^{3} + 3 \,{\left (x e + d\right )}^{m} c d^{2} x^{2} e^{2} -{\left (x e + d\right )}^{m} c d^{4} +{\left (x e + d\right )}^{m} a m x^{2} e^{4} + 2 \,{\left (x e + d\right )}^{m} a d m x e^{3} +{\left (x e + d\right )}^{m} a d^{2} m e^{2} + 3 \,{\left (x e + d\right )}^{m} a x^{2} e^{4} + 6 \,{\left (x e + d\right )}^{m} a d x e^{3} + 3 \,{\left (x e + d\right )}^{m} a d^{2} e^{2}}{m^{2} e^{2} + 5 \, m e^{2} + 6 \, e^{2}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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