3.476 \(\int (-3+x) (-7+4 x^2) \, dx\)

Optimal. Leaf size=22 \[ -4 x^3+\frac{1}{16} \left (7-4 x^2\right )^2+21 x \]

[Out]

21*x - 4*x^3 + (7 - 4*x^2)^2/16

________________________________________________________________________________________

Rubi [A]  time = 0.0042643, antiderivative size = 22, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 11, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.091, Rules used = {641} \[ -4 x^3+\frac{1}{16} \left (7-4 x^2\right )^2+21 x \]

Antiderivative was successfully verified.

[In]

Int[(-3 + x)*(-7 + 4*x^2),x]

[Out]

21*x - 4*x^3 + (7 - 4*x^2)^2/16

Rule 641

Int[((d_) + (e_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Simp[(e*(a + c*x^2)^(p + 1))/(2*c*(p + 1)),
x] + Dist[d, Int[(a + c*x^2)^p, x], x] /; FreeQ[{a, c, d, e, p}, x] && NeQ[p, -1]

Rubi steps

\begin{align*} \int (-3+x) \left (-7+4 x^2\right ) \, dx &=\frac{1}{16} \left (7-4 x^2\right )^2-3 \int \left (-7+4 x^2\right ) \, dx\\ &=21 x-4 x^3+\frac{1}{16} \left (7-4 x^2\right )^2\\ \end{align*}

Mathematica [A]  time = 0.0009434, size = 19, normalized size = 0.86 \[ x^4-4 x^3-\frac{7 x^2}{2}+21 x \]

Antiderivative was successfully verified.

[In]

Integrate[(-3 + x)*(-7 + 4*x^2),x]

[Out]

21*x - (7*x^2)/2 - 4*x^3 + x^4

________________________________________________________________________________________

Maple [A]  time = 0., size = 18, normalized size = 0.8 \begin{align*}{x}^{4}-4\,{x}^{3}-{\frac{7\,{x}^{2}}{2}}+21\,x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-3+x)*(4*x^2-7),x)

[Out]

x^4-4*x^3-7/2*x^2+21*x

________________________________________________________________________________________

Maxima [A]  time = 1.11595, size = 23, normalized size = 1.05 \begin{align*} x^{4} - 4 \, x^{3} - \frac{7}{2} \, x^{2} + 21 \, x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-3+x)*(4*x^2-7),x, algorithm="maxima")

[Out]

x^4 - 4*x^3 - 7/2*x^2 + 21*x

________________________________________________________________________________________

Fricas [A]  time = 1.13045, size = 41, normalized size = 1.86 \begin{align*} x^{4} - 4 x^{3} - \frac{7}{2} x^{2} + 21 x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-3+x)*(4*x^2-7),x, algorithm="fricas")

[Out]

x^4 - 4*x^3 - 7/2*x^2 + 21*x

________________________________________________________________________________________

Sympy [A]  time = 0.051037, size = 17, normalized size = 0.77 \begin{align*} x^{4} - 4 x^{3} - \frac{7 x^{2}}{2} + 21 x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-3+x)*(4*x**2-7),x)

[Out]

x**4 - 4*x**3 - 7*x**2/2 + 21*x

________________________________________________________________________________________

Giac [A]  time = 1.14309, size = 23, normalized size = 1.05 \begin{align*} x^{4} - 4 \, x^{3} - \frac{7}{2} \, x^{2} + 21 \, x \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-3+x)*(4*x^2-7),x, algorithm="giac")

[Out]

x^4 - 4*x^3 - 7/2*x^2 + 21*x