### 3.1744 $$\int (d+e x)^3 (a^2+2 a b x+b^2 x^2)^p \, dx$$

Optimal. Leaf size=181 $\frac{3 e^2 (a+b x)^3 (b d-a e) \left (a^2+2 a b x+b^2 x^2\right )^p}{b^4 (2 p+3)}+\frac{3 e (a+b x)^2 (b d-a e)^2 \left (a^2+2 a b x+b^2 x^2\right )^p}{2 b^4 (p+1)}+\frac{(a+b x) (b d-a e)^3 \left (a^2+2 a b x+b^2 x^2\right )^p}{b^4 (2 p+1)}+\frac{e^3 (a+b x)^4 \left (a^2+2 a b x+b^2 x^2\right )^p}{2 b^4 (p+2)}$

[Out]

((b*d - a*e)^3*(a + b*x)*(a^2 + 2*a*b*x + b^2*x^2)^p)/(b^4*(1 + 2*p)) + (3*e*(b*d - a*e)^2*(a + b*x)^2*(a^2 +
2*a*b*x + b^2*x^2)^p)/(2*b^4*(1 + p)) + (3*e^2*(b*d - a*e)*(a + b*x)^3*(a^2 + 2*a*b*x + b^2*x^2)^p)/(b^4*(3 +
2*p)) + (e^3*(a + b*x)^4*(a^2 + 2*a*b*x + b^2*x^2)^p)/(2*b^4*(2 + p))

________________________________________________________________________________________

Rubi [A]  time = 0.0923914, antiderivative size = 181, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 26, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.077, Rules used = {646, 43} $\frac{3 e^2 (a+b x)^3 (b d-a e) \left (a^2+2 a b x+b^2 x^2\right )^p}{b^4 (2 p+3)}+\frac{3 e (a+b x)^2 (b d-a e)^2 \left (a^2+2 a b x+b^2 x^2\right )^p}{2 b^4 (p+1)}+\frac{(a+b x) (b d-a e)^3 \left (a^2+2 a b x+b^2 x^2\right )^p}{b^4 (2 p+1)}+\frac{e^3 (a+b x)^4 \left (a^2+2 a b x+b^2 x^2\right )^p}{2 b^4 (p+2)}$

Antiderivative was successfully veriﬁed.

[In]

Int[(d + e*x)^3*(a^2 + 2*a*b*x + b^2*x^2)^p,x]

[Out]

((b*d - a*e)^3*(a + b*x)*(a^2 + 2*a*b*x + b^2*x^2)^p)/(b^4*(1 + 2*p)) + (3*e*(b*d - a*e)^2*(a + b*x)^2*(a^2 +
2*a*b*x + b^2*x^2)^p)/(2*b^4*(1 + p)) + (3*e^2*(b*d - a*e)*(a + b*x)^3*(a^2 + 2*a*b*x + b^2*x^2)^p)/(b^4*(3 +
2*p)) + (e^3*(a + b*x)^4*(a^2 + 2*a*b*x + b^2*x^2)^p)/(2*b^4*(2 + p))

Rule 646

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

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)^3 \left (a^2+2 a b x+b^2 x^2\right )^p \, dx &=\left (\left (a b+b^2 x\right )^{-2 p} \left (a^2+2 a b x+b^2 x^2\right )^p\right ) \int \left (a b+b^2 x\right )^{2 p} (d+e x)^3 \, dx\\ &=\left (\left (a b+b^2 x\right )^{-2 p} \left (a^2+2 a b x+b^2 x^2\right )^p\right ) \int \left (\frac{(b d-a e)^3 \left (a b+b^2 x\right )^{2 p}}{b^3}+\frac{3 e (b d-a e)^2 \left (a b+b^2 x\right )^{1+2 p}}{b^4}+\frac{3 e^2 (b d-a e) \left (a b+b^2 x\right )^{2+2 p}}{b^5}+\frac{e^3 \left (a b+b^2 x\right )^{3+2 p}}{b^6}\right ) \, dx\\ &=\frac{(b d-a e)^3 (a+b x) \left (a^2+2 a b x+b^2 x^2\right )^p}{b^4 (1+2 p)}+\frac{3 e (b d-a e)^2 (a+b x)^2 \left (a^2+2 a b x+b^2 x^2\right )^p}{2 b^4 (1+p)}+\frac{3 e^2 (b d-a e) (a+b x)^3 \left (a^2+2 a b x+b^2 x^2\right )^p}{b^4 (3+2 p)}+\frac{e^3 (a+b x)^4 \left (a^2+2 a b x+b^2 x^2\right )^p}{2 b^4 (2+p)}\\ \end{align*}

Mathematica [A]  time = 0.0857858, size = 107, normalized size = 0.59 $\frac{(a+b x) \left ((a+b x)^2\right )^p \left (\frac{6 e^2 (a+b x)^2 (b d-a e)}{2 p+3}+\frac{3 e (a+b x) (b d-a e)^2}{p+1}+\frac{2 (b d-a e)^3}{2 p+1}+\frac{e^3 (a+b x)^3}{p+2}\right )}{2 b^4}$

Antiderivative was successfully veriﬁed.

[In]

Integrate[(d + e*x)^3*(a^2 + 2*a*b*x + b^2*x^2)^p,x]

[Out]

((a + b*x)*((a + b*x)^2)^p*((2*(b*d - a*e)^3)/(1 + 2*p) + (3*e*(b*d - a*e)^2*(a + b*x))/(1 + p) + (6*e^2*(b*d
- a*e)*(a + b*x)^2)/(3 + 2*p) + (e^3*(a + b*x)^3)/(2 + p)))/(2*b^4)

________________________________________________________________________________________

Maple [B]  time = 0.049, size = 405, normalized size = 2.2 \begin{align*} -{\frac{ \left ({b}^{2}{x}^{2}+2\,abx+{a}^{2} \right ) ^{p} \left ( -4\,{b}^{3}{e}^{3}{p}^{3}{x}^{3}-12\,{b}^{3}d{e}^{2}{p}^{3}{x}^{2}-12\,{b}^{3}{e}^{3}{p}^{2}{x}^{3}+6\,a{b}^{2}{e}^{3}{p}^{2}{x}^{2}-12\,{b}^{3}{d}^{2}e{p}^{3}x-42\,{b}^{3}d{e}^{2}{p}^{2}{x}^{2}-11\,{b}^{3}{e}^{3}p{x}^{3}+12\,a{b}^{2}d{e}^{2}{p}^{2}x+9\,a{b}^{2}{e}^{3}p{x}^{2}-4\,{b}^{3}{d}^{3}{p}^{3}-48\,{b}^{3}{d}^{2}e{p}^{2}x-42\,{b}^{3}d{e}^{2}p{x}^{2}-3\,{x}^{3}{b}^{3}{e}^{3}-6\,{a}^{2}b{e}^{3}px+6\,a{b}^{2}{d}^{2}e{p}^{2}+30\,a{b}^{2}d{e}^{2}px+3\,{x}^{2}a{b}^{2}{e}^{3}-18\,{b}^{3}{d}^{3}{p}^{2}-57\,{b}^{3}{d}^{2}epx-12\,{x}^{2}{b}^{3}d{e}^{2}-6\,{a}^{2}bd{e}^{2}p-3\,x{a}^{2}b{e}^{3}+21\,a{b}^{2}{d}^{2}ep+12\,xa{b}^{2}d{e}^{2}-26\,{b}^{3}{d}^{3}p-18\,x{b}^{3}{d}^{2}e+3\,{a}^{3}{e}^{3}-12\,d{e}^{2}{a}^{2}b+18\,a{b}^{2}{d}^{2}e-12\,{b}^{3}{d}^{3} \right ) \left ( bx+a \right ) }{2\,{b}^{4} \left ( 4\,{p}^{4}+20\,{p}^{3}+35\,{p}^{2}+25\,p+6 \right ) }} \end{align*}

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

[In]

int((e*x+d)^3*(b^2*x^2+2*a*b*x+a^2)^p,x)

[Out]

-1/2*(b^2*x^2+2*a*b*x+a^2)^p*(-4*b^3*e^3*p^3*x^3-12*b^3*d*e^2*p^3*x^2-12*b^3*e^3*p^2*x^3+6*a*b^2*e^3*p^2*x^2-1
2*b^3*d^2*e*p^3*x-42*b^3*d*e^2*p^2*x^2-11*b^3*e^3*p*x^3+12*a*b^2*d*e^2*p^2*x+9*a*b^2*e^3*p*x^2-4*b^3*d^3*p^3-4
8*b^3*d^2*e*p^2*x-42*b^3*d*e^2*p*x^2-3*b^3*e^3*x^3-6*a^2*b*e^3*p*x+6*a*b^2*d^2*e*p^2+30*a*b^2*d*e^2*p*x+3*a*b^
2*e^3*x^2-18*b^3*d^3*p^2-57*b^3*d^2*e*p*x-12*b^3*d*e^2*x^2-6*a^2*b*d*e^2*p-3*a^2*b*e^3*x+21*a*b^2*d^2*e*p+12*a
*b^2*d*e^2*x-26*b^3*d^3*p-18*b^3*d^2*e*x+3*a^3*e^3-12*a^2*b*d*e^2+18*a*b^2*d^2*e-12*b^3*d^3)*(b*x+a)/b^4/(4*p^
4+20*p^3+35*p^2+25*p+6)

________________________________________________________________________________________

Maxima [A]  time = 1.12158, size = 373, normalized size = 2.06 \begin{align*} \frac{{\left (b x + a\right )}{\left (b x + a\right )}^{2 \, p} d^{3}}{b{\left (2 \, p + 1\right )}} + \frac{3 \,{\left (b^{2}{\left (2 \, p + 1\right )} x^{2} + 2 \, a b p x - a^{2}\right )}{\left (b x + a\right )}^{2 \, p} d^{2} e}{2 \,{\left (2 \, p^{2} + 3 \, p + 1\right )} b^{2}} + \frac{3 \,{\left ({\left (2 \, p^{2} + 3 \, p + 1\right )} b^{3} x^{3} +{\left (2 \, p^{2} + p\right )} a b^{2} x^{2} - 2 \, a^{2} b p x + a^{3}\right )}{\left (b x + a\right )}^{2 \, p} d e^{2}}{{\left (4 \, p^{3} + 12 \, p^{2} + 11 \, p + 3\right )} b^{3}} + \frac{{\left ({\left (4 \, p^{3} + 12 \, p^{2} + 11 \, p + 3\right )} b^{4} x^{4} + 2 \,{\left (2 \, p^{3} + 3 \, p^{2} + p\right )} a b^{3} x^{3} - 3 \,{\left (2 \, p^{2} + p\right )} a^{2} b^{2} x^{2} + 6 \, a^{3} b p x - 3 \, a^{4}\right )}{\left (b x + a\right )}^{2 \, p} e^{3}}{2 \,{\left (4 \, p^{4} + 20 \, p^{3} + 35 \, p^{2} + 25 \, p + 6\right )} b^{4}} \end{align*}

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

[In]

integrate((e*x+d)^3*(b^2*x^2+2*a*b*x+a^2)^p,x, algorithm="maxima")

[Out]

(b*x + a)*(b*x + a)^(2*p)*d^3/(b*(2*p + 1)) + 3/2*(b^2*(2*p + 1)*x^2 + 2*a*b*p*x - a^2)*(b*x + a)^(2*p)*d^2*e/
((2*p^2 + 3*p + 1)*b^2) + 3*((2*p^2 + 3*p + 1)*b^3*x^3 + (2*p^2 + p)*a*b^2*x^2 - 2*a^2*b*p*x + a^3)*(b*x + a)^
(2*p)*d*e^2/((4*p^3 + 12*p^2 + 11*p + 3)*b^3) + 1/2*((4*p^3 + 12*p^2 + 11*p + 3)*b^4*x^4 + 2*(2*p^3 + 3*p^2 +
p)*a*b^3*x^3 - 3*(2*p^2 + p)*a^2*b^2*x^2 + 6*a^3*b*p*x - 3*a^4)*(b*x + a)^(2*p)*e^3/((4*p^4 + 20*p^3 + 35*p^2
+ 25*p + 6)*b^4)

________________________________________________________________________________________

Fricas [B]  time = 1.72555, size = 1053, normalized size = 5.82 \begin{align*} \frac{{\left (4 \, a b^{3} d^{3} p^{3} + 12 \, a b^{3} d^{3} - 18 \, a^{2} b^{2} d^{2} e + 12 \, a^{3} b d e^{2} - 3 \, a^{4} e^{3} +{\left (4 \, b^{4} e^{3} p^{3} + 12 \, b^{4} e^{3} p^{2} + 11 \, b^{4} e^{3} p + 3 \, b^{4} e^{3}\right )} x^{4} + 2 \,{\left (6 \, b^{4} d e^{2} + 2 \,{\left (3 \, b^{4} d e^{2} + a b^{3} e^{3}\right )} p^{3} + 3 \,{\left (7 \, b^{4} d e^{2} + a b^{3} e^{3}\right )} p^{2} +{\left (21 \, b^{4} d e^{2} + a b^{3} e^{3}\right )} p\right )} x^{3} + 6 \,{\left (3 \, a b^{3} d^{3} - a^{2} b^{2} d^{2} e\right )} p^{2} + 3 \,{\left (6 \, b^{4} d^{2} e + 4 \,{\left (b^{4} d^{2} e + a b^{3} d e^{2}\right )} p^{3} + 2 \,{\left (8 \, b^{4} d^{2} e + 5 \, a b^{3} d e^{2} - a^{2} b^{2} e^{3}\right )} p^{2} +{\left (19 \, b^{4} d^{2} e + 4 \, a b^{3} d e^{2} - a^{2} b^{2} e^{3}\right )} p\right )} x^{2} +{\left (26 \, a b^{3} d^{3} - 21 \, a^{2} b^{2} d^{2} e + 6 \, a^{3} b d e^{2}\right )} p + 2 \,{\left (6 \, b^{4} d^{3} + 2 \,{\left (b^{4} d^{3} + 3 \, a b^{3} d^{2} e\right )} p^{3} + 3 \,{\left (3 \, b^{4} d^{3} + 7 \, a b^{3} d^{2} e - 2 \, a^{2} b^{2} d e^{2}\right )} p^{2} +{\left (13 \, b^{4} d^{3} + 18 \, a b^{3} d^{2} e - 12 \, a^{2} b^{2} d e^{2} + 3 \, a^{3} b e^{3}\right )} p\right )} x\right )}{\left (b^{2} x^{2} + 2 \, a b x + a^{2}\right )}^{p}}{2 \,{\left (4 \, b^{4} p^{4} + 20 \, b^{4} p^{3} + 35 \, b^{4} p^{2} + 25 \, b^{4} p + 6 \, b^{4}\right )}} \end{align*}

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

[In]

integrate((e*x+d)^3*(b^2*x^2+2*a*b*x+a^2)^p,x, algorithm="fricas")

[Out]

1/2*(4*a*b^3*d^3*p^3 + 12*a*b^3*d^3 - 18*a^2*b^2*d^2*e + 12*a^3*b*d*e^2 - 3*a^4*e^3 + (4*b^4*e^3*p^3 + 12*b^4*
e^3*p^2 + 11*b^4*e^3*p + 3*b^4*e^3)*x^4 + 2*(6*b^4*d*e^2 + 2*(3*b^4*d*e^2 + a*b^3*e^3)*p^3 + 3*(7*b^4*d*e^2 +
a*b^3*e^3)*p^2 + (21*b^4*d*e^2 + a*b^3*e^3)*p)*x^3 + 6*(3*a*b^3*d^3 - a^2*b^2*d^2*e)*p^2 + 3*(6*b^4*d^2*e + 4*
(b^4*d^2*e + a*b^3*d*e^2)*p^3 + 2*(8*b^4*d^2*e + 5*a*b^3*d*e^2 - a^2*b^2*e^3)*p^2 + (19*b^4*d^2*e + 4*a*b^3*d*
e^2 - a^2*b^2*e^3)*p)*x^2 + (26*a*b^3*d^3 - 21*a^2*b^2*d^2*e + 6*a^3*b*d*e^2)*p + 2*(6*b^4*d^3 + 2*(b^4*d^3 +
3*a*b^3*d^2*e)*p^3 + 3*(3*b^4*d^3 + 7*a*b^3*d^2*e - 2*a^2*b^2*d*e^2)*p^2 + (13*b^4*d^3 + 18*a*b^3*d^2*e - 12*a
^2*b^2*d*e^2 + 3*a^3*b*e^3)*p)*x)*(b^2*x^2 + 2*a*b*x + a^2)^p/(4*b^4*p^4 + 20*b^4*p^3 + 35*b^4*p^2 + 25*b^4*p
+ 6*b^4)

________________________________________________________________________________________

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

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

[In]

integrate((e*x+d)**3*(b**2*x**2+2*a*b*x+a**2)**p,x)

[Out]

Exception raised: TypeError

________________________________________________________________________________________

Giac [B]  time = 1.23718, size = 1710, normalized size = 9.45 \begin{align*} \text{result too large to display} \end{align*}

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

[In]

integrate((e*x+d)^3*(b^2*x^2+2*a*b*x+a^2)^p,x, algorithm="giac")

[Out]

1/2*(4*(b^2*x^2 + 2*a*b*x + a^2)^p*b^4*p^3*x^4*e^3 + 12*(b^2*x^2 + 2*a*b*x + a^2)^p*b^4*d*p^3*x^3*e^2 + 12*(b^
2*x^2 + 2*a*b*x + a^2)^p*b^4*d^2*p^3*x^2*e + 4*(b^2*x^2 + 2*a*b*x + a^2)^p*b^4*d^3*p^3*x + 4*(b^2*x^2 + 2*a*b*
x + a^2)^p*a*b^3*p^3*x^3*e^3 + 12*(b^2*x^2 + 2*a*b*x + a^2)^p*b^4*p^2*x^4*e^3 + 12*(b^2*x^2 + 2*a*b*x + a^2)^p
*a*b^3*d*p^3*x^2*e^2 + 42*(b^2*x^2 + 2*a*b*x + a^2)^p*b^4*d*p^2*x^3*e^2 + 12*(b^2*x^2 + 2*a*b*x +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