### 3.2135 $$\int (a+b x+c x^2)^3 \, dx$$

Optimal. Leaf size=81 $\frac{3}{2} a^2 b x^2+a^3 x+\frac{3}{5} c x^5 \left (a c+b^2\right )+\frac{1}{4} b x^4 \left (6 a c+b^2\right )+a x^3 \left (a c+b^2\right )+\frac{1}{2} b c^2 x^6+\frac{c^3 x^7}{7}$

[Out]

a^3*x + (3*a^2*b*x^2)/2 + a*(b^2 + a*c)*x^3 + (b*(b^2 + 6*a*c)*x^4)/4 + (3*c*(b^2 + a*c)*x^5)/5 + (b*c^2*x^6)/
2 + (c^3*x^7)/7

________________________________________________________________________________________

Rubi [A]  time = 0.0557333, antiderivative size = 81, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 12, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.083, Rules used = {611} $\frac{3}{2} a^2 b x^2+a^3 x+\frac{3}{5} c x^5 \left (a c+b^2\right )+\frac{1}{4} b x^4 \left (6 a c+b^2\right )+a x^3 \left (a c+b^2\right )+\frac{1}{2} b c^2 x^6+\frac{c^3 x^7}{7}$

Antiderivative was successfully veriﬁed.

[In]

Int[(a + b*x + c*x^2)^3,x]

[Out]

a^3*x + (3*a^2*b*x^2)/2 + a*(b^2 + a*c)*x^3 + (b*(b^2 + 6*a*c)*x^4)/4 + (3*c*(b^2 + a*c)*x^5)/5 + (b*c^2*x^6)/
2 + (c^3*x^7)/7

Rule 611

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Int[ExpandIntegrand[(a + b*x + c*x^2)^p, x], x] /;
FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0] && IGtQ[p, 0] && (EqQ[a, 0] ||  !PerfectSquareQ[b^2 - 4*a*c])

Rubi steps

\begin{align*} \int \left (a+b x+c x^2\right )^3 \, dx &=\int \left (a^3+3 a^2 b x+3 a b^2 \left (1+\frac{a c}{b^2}\right ) x^2+b^3 \left (1+\frac{6 a c}{b^2}\right ) x^3+3 b^2 c \left (1+\frac{a c}{b^2}\right ) x^4+3 b c^2 x^5+c^3 x^6\right ) \, dx\\ &=a^3 x+\frac{3}{2} a^2 b x^2+a \left (b^2+a c\right ) x^3+\frac{1}{4} b \left (b^2+6 a c\right ) x^4+\frac{3}{5} c \left (b^2+a c\right ) x^5+\frac{1}{2} b c^2 x^6+\frac{c^3 x^7}{7}\\ \end{align*}

Mathematica [A]  time = 0.0128007, size = 81, normalized size = 1. $\frac{3}{2} a^2 b x^2+a^3 x+\frac{3}{5} c x^5 \left (a c+b^2\right )+\frac{1}{4} b x^4 \left (6 a c+b^2\right )+a x^3 \left (a c+b^2\right )+\frac{1}{2} b c^2 x^6+\frac{c^3 x^7}{7}$

Antiderivative was successfully veriﬁed.

[In]

Integrate[(a + b*x + c*x^2)^3,x]

[Out]

a^3*x + (3*a^2*b*x^2)/2 + a*(b^2 + a*c)*x^3 + (b*(b^2 + 6*a*c)*x^4)/4 + (3*c*(b^2 + a*c)*x^5)/5 + (b*c^2*x^6)/
2 + (c^3*x^7)/7

________________________________________________________________________________________

Maple [A]  time = 0.039, size = 108, normalized size = 1.3 \begin{align*}{\frac{{c}^{3}{x}^{7}}{7}}+{\frac{b{c}^{2}{x}^{6}}{2}}+{\frac{ \left ( a{c}^{2}+2\,{b}^{2}c+c \left ( 2\,ac+{b}^{2} \right ) \right ){x}^{5}}{5}}+{\frac{ \left ( 4\,abc+b \left ( 2\,ac+{b}^{2} \right ) \right ){x}^{4}}{4}}+{\frac{ \left ( a \left ( 2\,ac+{b}^{2} \right ) +2\,{b}^{2}a+{a}^{2}c \right ){x}^{3}}{3}}+{\frac{3\,{a}^{2}b{x}^{2}}{2}}+x{a}^{3} \end{align*}

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

[In]

int((c*x^2+b*x+a)^3,x)

[Out]

1/7*c^3*x^7+1/2*b*c^2*x^6+1/5*(a*c^2+2*b^2*c+c*(2*a*c+b^2))*x^5+1/4*(4*a*b*c+b*(2*a*c+b^2))*x^4+1/3*(a*(2*a*c+
b^2)+2*b^2*a+a^2*c)*x^3+3/2*a^2*b*x^2+x*a^3

________________________________________________________________________________________

Maxima [A]  time = 1.01875, size = 115, normalized size = 1.42 \begin{align*} \frac{1}{7} \, c^{3} x^{7} + \frac{1}{2} \, b c^{2} x^{6} + \frac{3}{5} \, b^{2} c x^{5} + \frac{1}{4} \, b^{3} x^{4} + a^{3} x + \frac{1}{2} \,{\left (2 \, c x^{3} + 3 \, b x^{2}\right )} a^{2} + \frac{1}{10} \,{\left (6 \, c^{2} x^{5} + 15 \, b c x^{4} + 10 \, b^{2} x^{3}\right )} a \end{align*}

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

[In]

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

[Out]

1/7*c^3*x^7 + 1/2*b*c^2*x^6 + 3/5*b^2*c*x^5 + 1/4*b^3*x^4 + a^3*x + 1/2*(2*c*x^3 + 3*b*x^2)*a^2 + 1/10*(6*c^2*
x^5 + 15*b*c*x^4 + 10*b^2*x^3)*a

________________________________________________________________________________________

Fricas [A]  time = 1.69686, size = 188, normalized size = 2.32 \begin{align*} \frac{1}{7} x^{7} c^{3} + \frac{1}{2} x^{6} c^{2} b + \frac{3}{5} x^{5} c b^{2} + \frac{3}{5} x^{5} c^{2} a + \frac{1}{4} x^{4} b^{3} + \frac{3}{2} x^{4} c b a + x^{3} b^{2} a + x^{3} c a^{2} + \frac{3}{2} x^{2} b a^{2} + x a^{3} \end{align*}

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

[In]

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

[Out]

1/7*x^7*c^3 + 1/2*x^6*c^2*b + 3/5*x^5*c*b^2 + 3/5*x^5*c^2*a + 1/4*x^4*b^3 + 3/2*x^4*c*b*a + x^3*b^2*a + x^3*c*
a^2 + 3/2*x^2*b*a^2 + x*a^3

________________________________________________________________________________________

Sympy [A]  time = 0.078463, size = 85, normalized size = 1.05 \begin{align*} a^{3} x + \frac{3 a^{2} b x^{2}}{2} + \frac{b c^{2} x^{6}}{2} + \frac{c^{3} x^{7}}{7} + x^{5} \left (\frac{3 a c^{2}}{5} + \frac{3 b^{2} c}{5}\right ) + x^{4} \left (\frac{3 a b c}{2} + \frac{b^{3}}{4}\right ) + x^{3} \left (a^{2} c + a b^{2}\right ) \end{align*}

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

[In]

integrate((c*x**2+b*x+a)**3,x)

[Out]

a**3*x + 3*a**2*b*x**2/2 + b*c**2*x**6/2 + c**3*x**7/7 + x**5*(3*a*c**2/5 + 3*b**2*c/5) + x**4*(3*a*b*c/2 + b*
*3/4) + x**3*(a**2*c + a*b**2)

________________________________________________________________________________________

Giac [A]  time = 1.07453, size = 111, normalized size = 1.37 \begin{align*} \frac{1}{7} \, c^{3} x^{7} + \frac{1}{2} \, b c^{2} x^{6} + \frac{3}{5} \, b^{2} c x^{5} + \frac{3}{5} \, a c^{2} x^{5} + \frac{1}{4} \, b^{3} x^{4} + \frac{3}{2} \, a b c x^{4} + a b^{2} x^{3} + a^{2} c x^{3} + \frac{3}{2} \, a^{2} b x^{2} + a^{3} x \end{align*}

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

[In]

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

[Out]

1/7*c^3*x^7 + 1/2*b*c^2*x^6 + 3/5*b^2*c*x^5 + 3/5*a*c^2*x^5 + 1/4*b^3*x^4 + 3/2*a*b*c*x^4 + a*b^2*x^3 + a^2*c*
x^3 + 3/2*a^2*b*x^2 + a^3*x