### 3.35 $$\int (a+c x^2)^3 (A+B x+C x^2) \, dx$$

Optimal. Leaf size=87 $\frac{1}{3} a^2 x^3 (a C+3 A c)+a^3 A x+\frac{1}{7} c^2 x^7 (3 a C+A c)+\frac{3}{5} a c x^5 (a C+A c)+\frac{B \left (a+c x^2\right )^4}{8 c}+\frac{1}{9} c^3 C x^9$

[Out]

a^3*A*x + (a^2*(3*A*c + a*C)*x^3)/3 + (3*a*c*(A*c + a*C)*x^5)/5 + (c^2*(A*c + 3*a*C)*x^7)/7 + (c^3*C*x^9)/9 +
(B*(a + c*x^2)^4)/(8*c)

________________________________________________________________________________________

Rubi [A]  time = 0.0578149, antiderivative size = 87, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 20, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.1, Rules used = {1582, 373} $\frac{1}{3} a^2 x^3 (a C+3 A c)+a^3 A x+\frac{1}{7} c^2 x^7 (3 a C+A c)+\frac{3}{5} a c x^5 (a C+A c)+\frac{B \left (a+c x^2\right )^4}{8 c}+\frac{1}{9} c^3 C x^9$

Antiderivative was successfully veriﬁed.

[In]

Int[(a + c*x^2)^3*(A + B*x + C*x^2),x]

[Out]

a^3*A*x + (a^2*(3*A*c + a*C)*x^3)/3 + (3*a*c*(A*c + a*C)*x^5)/5 + (c^2*(A*c + 3*a*C)*x^7)/7 + (c^3*C*x^9)/9 +
(B*(a + c*x^2)^4)/(8*c)

Rule 1582

Int[(Px_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(Coeff[Px, x, n - 1]*(a + b*x^n)^(p + 1))/(b*n*(p +
1)), x] + Int[(Px - Coeff[Px, x, n - 1]*x^(n - 1))*(a + b*x^n)^p, x] /; FreeQ[{a, b}, x] && PolyQ[Px, x] && I
GtQ[p, 1] && IGtQ[n, 1] && NeQ[Coeff[Px, x, n - 1], 0] && NeQ[Px, Coeff[Px, x, n - 1]*x^(n - 1)] &&  !MatchQ[P
x, (Qx_.)*((c_) + (d_.)*x^(m_))^(q_) /; FreeQ[{c, d}, x] && PolyQ[Qx, x] && IGtQ[q, 1] && IGtQ[m, 1] && NeQ[Co
eff[Qx*(a + b*x^n)^p, x, m - 1], 0] && GtQ[m*q, n*p]]

Rule 373

Int[((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_))^(q_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x^n
)^p*(c + d*x^n)^q, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[p, 0] && IGtQ[q, 0]

Rubi steps

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

Mathematica [A]  time = 0.0318585, size = 100, normalized size = 1.15 $\frac{1}{20} a^2 c x^3 (20 A+3 x (5 B+4 C x))+\frac{1}{6} a^3 x (6 A+x (3 B+2 C x))+\frac{1}{70} a c^2 x^5 (42 A+5 x (7 B+6 C x))+\frac{1}{504} c^3 x^7 (72 A+7 x (9 B+8 C x))$

Antiderivative was successfully veriﬁed.

[In]

Integrate[(a + c*x^2)^3*(A + B*x + C*x^2),x]

[Out]

(a^3*x*(6*A + x*(3*B + 2*C*x)))/6 + (a^2*c*x^3*(20*A + 3*x*(5*B + 4*C*x)))/20 + (a*c^2*x^5*(42*A + 5*x*(7*B +
6*C*x)))/70 + (c^3*x^7*(72*A + 7*x*(9*B + 8*C*x)))/504

________________________________________________________________________________________

Maple [A]  time = 0.044, size = 111, normalized size = 1.3 \begin{align*}{\frac{{c}^{3}C{x}^{9}}{9}}+{\frac{{c}^{3}B{x}^{8}}{8}}+{\frac{ \left ( A{c}^{3}+3\,a{c}^{2}C \right ){x}^{7}}{7}}+{\frac{a{c}^{2}B{x}^{6}}{2}}+{\frac{ \left ( 3\,aA{c}^{2}+3\,{a}^{2}cC \right ){x}^{5}}{5}}+{\frac{3\,B{a}^{2}c{x}^{4}}{4}}+{\frac{ \left ( 3\,{a}^{2}Ac+{a}^{3}C \right ){x}^{3}}{3}}+{\frac{{a}^{3}B{x}^{2}}{2}}+{a}^{3}Ax \end{align*}

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

[In]

int((c*x^2+a)^3*(C*x^2+B*x+A),x)

[Out]

1/9*c^3*C*x^9+1/8*c^3*B*x^8+1/7*(A*c^3+3*C*a*c^2)*x^7+1/2*a*c^2*B*x^6+1/5*(3*A*a*c^2+3*C*a^2*c)*x^5+3/4*B*a^2*
c*x^4+1/3*(3*A*a^2*c+C*a^3)*x^3+1/2*a^3*B*x^2+a^3*A*x

________________________________________________________________________________________

Maxima [A]  time = 1.22697, size = 146, normalized size = 1.68 \begin{align*} \frac{1}{9} \, C c^{3} x^{9} + \frac{1}{8} \, B c^{3} x^{8} + \frac{1}{2} \, B a c^{2} x^{6} + \frac{3}{4} \, B a^{2} c x^{4} + \frac{1}{7} \,{\left (3 \, C a c^{2} + A c^{3}\right )} x^{7} + \frac{1}{2} \, B a^{3} x^{2} + \frac{3}{5} \,{\left (C a^{2} c + A a c^{2}\right )} x^{5} + A a^{3} x + \frac{1}{3} \,{\left (C a^{3} + 3 \, A a^{2} c\right )} x^{3} \end{align*}

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

[In]

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

[Out]

1/9*C*c^3*x^9 + 1/8*B*c^3*x^8 + 1/2*B*a*c^2*x^6 + 3/4*B*a^2*c*x^4 + 1/7*(3*C*a*c^2 + A*c^3)*x^7 + 1/2*B*a^3*x^
2 + 3/5*(C*a^2*c + A*a*c^2)*x^5 + A*a^3*x + 1/3*(C*a^3 + 3*A*a^2*c)*x^3

________________________________________________________________________________________

Fricas [A]  time = 1.50704, size = 261, normalized size = 3. \begin{align*} \frac{1}{9} x^{9} c^{3} C + \frac{1}{8} x^{8} c^{3} B + \frac{3}{7} x^{7} c^{2} a C + \frac{1}{7} x^{7} c^{3} A + \frac{1}{2} x^{6} c^{2} a B + \frac{3}{5} x^{5} c a^{2} C + \frac{3}{5} x^{5} c^{2} a A + \frac{3}{4} x^{4} c a^{2} B + \frac{1}{3} x^{3} a^{3} C + x^{3} c a^{2} A + \frac{1}{2} x^{2} a^{3} B + x a^{3} A \end{align*}

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

[In]

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

[Out]

1/9*x^9*c^3*C + 1/8*x^8*c^3*B + 3/7*x^7*c^2*a*C + 1/7*x^7*c^3*A + 1/2*x^6*c^2*a*B + 3/5*x^5*c*a^2*C + 3/5*x^5*
c^2*a*A + 3/4*x^4*c*a^2*B + 1/3*x^3*a^3*C + x^3*c*a^2*A + 1/2*x^2*a^3*B + x*a^3*A

________________________________________________________________________________________

Sympy [A]  time = 0.079793, size = 122, normalized size = 1.4 \begin{align*} A a^{3} x + \frac{B a^{3} x^{2}}{2} + \frac{3 B a^{2} c x^{4}}{4} + \frac{B a c^{2} x^{6}}{2} + \frac{B c^{3} x^{8}}{8} + \frac{C c^{3} x^{9}}{9} + x^{7} \left (\frac{A c^{3}}{7} + \frac{3 C a c^{2}}{7}\right ) + x^{5} \left (\frac{3 A a c^{2}}{5} + \frac{3 C a^{2} c}{5}\right ) + x^{3} \left (A a^{2} c + \frac{C a^{3}}{3}\right ) \end{align*}

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

[In]

integrate((c*x**2+a)**3*(C*x**2+B*x+A),x)

[Out]

A*a**3*x + B*a**3*x**2/2 + 3*B*a**2*c*x**4/4 + B*a*c**2*x**6/2 + B*c**3*x**8/8 + C*c**3*x**9/9 + x**7*(A*c**3/
7 + 3*C*a*c**2/7) + x**5*(3*A*a*c**2/5 + 3*C*a**2*c/5) + x**3*(A*a**2*c + C*a**3/3)

________________________________________________________________________________________

Giac [A]  time = 1.14382, size = 150, normalized size = 1.72 \begin{align*} \frac{1}{9} \, C c^{3} x^{9} + \frac{1}{8} \, B c^{3} x^{8} + \frac{3}{7} \, C a c^{2} x^{7} + \frac{1}{7} \, A c^{3} x^{7} + \frac{1}{2} \, B a c^{2} x^{6} + \frac{3}{5} \, C a^{2} c x^{5} + \frac{3}{5} \, A a c^{2} x^{5} + \frac{3}{4} \, B a^{2} c x^{4} + \frac{1}{3} \, C a^{3} x^{3} + A a^{2} c x^{3} + \frac{1}{2} \, B a^{3} x^{2} + A a^{3} x \end{align*}

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

[In]

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

[Out]

1/9*C*c^3*x^9 + 1/8*B*c^3*x^8 + 3/7*C*a*c^2*x^7 + 1/7*A*c^3*x^7 + 1/2*B*a*c^2*x^6 + 3/5*C*a^2*c*x^5 + 3/5*A*a*
c^2*x^5 + 3/4*B*a^2*c*x^4 + 1/3*C*a^3*x^3 + A*a^2*c*x^3 + 1/2*B*a^3*x^2 + A*a^3*x