3.79.8 \(\int (-32 x+12 x^2+16 x^3+e^{2 x} (2 x+2 x^2)+e^x (-12 x^2-4 x^3)) \, dx\)

Optimal. Leaf size=19 \[ 4 x^2 \left (-4+x+\left (-\frac {e^x}{2}+x\right )^2\right ) \]

________________________________________________________________________________________

Rubi [A]  time = 0.14, antiderivative size = 33, normalized size of antiderivative = 1.74, number of steps used = 19, number of rules used = 4, integrand size = 44, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {1593, 2196, 2176, 2194} \begin {gather*} 4 x^4-4 e^x x^3+4 x^3+e^{2 x} x^2-16 x^2 \end {gather*}

Antiderivative was successfully verified.

[In]

Int[-32*x + 12*x^2 + 16*x^3 + E^(2*x)*(2*x + 2*x^2) + E^x*(-12*x^2 - 4*x^3),x]

[Out]

-16*x^2 + E^(2*x)*x^2 + 4*x^3 - 4*E^x*x^3 + 4*x^4

Rule 1593

Int[(u_.)*((a_.)*(x_)^(p_.) + (b_.)*(x_)^(q_.))^(n_.), x_Symbol] :> Int[u*x^(n*p)*(a + b*x^(q - p))^n, x] /; F
reeQ[{a, b, p, q}, x] && IntegerQ[n] && PosQ[q - p]

Rule 2176

Int[((b_.)*(F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[((c + d*x)^m
*(b*F^(g*(e + f*x)))^n)/(f*g*n*Log[F]), x] - Dist[(d*m)/(f*g*n*Log[F]), Int[(c + d*x)^(m - 1)*(b*F^(g*(e + f*x
)))^n, x], x] /; FreeQ[{F, b, c, d, e, f, g, n}, x] && GtQ[m, 0] && IntegerQ[2*m] &&  !$UseGamma === True

Rule 2194

Int[((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.), x_Symbol] :> Simp[(F^(c*(a + b*x)))^n/(b*c*n*Log[F]), x] /; Fre
eQ[{F, a, b, c, n}, x]

Rule 2196

Int[(F_)^((c_.)*(v_))*(u_), x_Symbol] :> Int[ExpandIntegrand[F^(c*ExpandToSum[v, x]), u, x], x] /; FreeQ[{F, c
}, x] && PolynomialQ[u, x] && LinearQ[v, x] &&  !$UseGamma === True

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=-16 x^2+4 x^3+4 x^4+\int e^{2 x} \left (2 x+2 x^2\right ) \, dx+\int e^x \left (-12 x^2-4 x^3\right ) \, dx\\ &=-16 x^2+4 x^3+4 x^4+\int e^x (-12-4 x) x^2 \, dx+\int e^{2 x} x (2+2 x) \, dx\\ &=-16 x^2+4 x^3+4 x^4+\int \left (2 e^{2 x} x+2 e^{2 x} x^2\right ) \, dx+\int \left (-12 e^x x^2-4 e^x x^3\right ) \, dx\\ &=-16 x^2+4 x^3+4 x^4+2 \int e^{2 x} x \, dx+2 \int e^{2 x} x^2 \, dx-4 \int e^x x^3 \, dx-12 \int e^x x^2 \, dx\\ &=e^{2 x} x-16 x^2-12 e^x x^2+e^{2 x} x^2+4 x^3-4 e^x x^3+4 x^4-2 \int e^{2 x} x \, dx+12 \int e^x x^2 \, dx+24 \int e^x x \, dx-\int e^{2 x} \, dx\\ &=-\frac {e^{2 x}}{2}+24 e^x x-16 x^2+e^{2 x} x^2+4 x^3-4 e^x x^3+4 x^4-24 \int e^x \, dx-24 \int e^x x \, dx+\int e^{2 x} \, dx\\ &=-24 e^x-16 x^2+e^{2 x} x^2+4 x^3-4 e^x x^3+4 x^4+24 \int e^x \, dx\\ &=-16 x^2+e^{2 x} x^2+4 x^3-4 e^x x^3+4 x^4\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.04, size = 24, normalized size = 1.26 \begin {gather*} x^2 \left (e^{2 x}-4 e^x x+4 \left (-4+x+x^2\right )\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[-32*x + 12*x^2 + 16*x^3 + E^(2*x)*(2*x + 2*x^2) + E^x*(-12*x^2 - 4*x^3),x]

[Out]

x^2*(E^(2*x) - 4*E^x*x + 4*(-4 + x + x^2))

________________________________________________________________________________________

fricas [A]  time = 0.57, size = 31, normalized size = 1.63 \begin {gather*} 4 \, x^{4} - 4 \, x^{3} e^{x} + 4 \, x^{3} + x^{2} e^{\left (2 \, x\right )} - 16 \, x^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2+2*x)*exp(x)^2+(-4*x^3-12*x^2)*exp(x)+16*x^3+12*x^2-32*x,x, algorithm="fricas")

[Out]

4*x^4 - 4*x^3*e^x + 4*x^3 + x^2*e^(2*x) - 16*x^2

________________________________________________________________________________________

giac [A]  time = 1.96, size = 31, normalized size = 1.63 \begin {gather*} 4 \, x^{4} - 4 \, x^{3} e^{x} + 4 \, x^{3} + x^{2} e^{\left (2 \, x\right )} - 16 \, x^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2+2*x)*exp(x)^2+(-4*x^3-12*x^2)*exp(x)+16*x^3+12*x^2-32*x,x, algorithm="giac")

[Out]

4*x^4 - 4*x^3*e^x + 4*x^3 + x^2*e^(2*x) - 16*x^2

________________________________________________________________________________________

maple [A]  time = 0.03, size = 32, normalized size = 1.68




method result size



default \({\mathrm e}^{2 x} x^{2}-4 \,{\mathrm e}^{x} x^{3}-16 x^{2}+4 x^{3}+4 x^{4}\) \(32\)
norman \({\mathrm e}^{2 x} x^{2}-4 \,{\mathrm e}^{x} x^{3}-16 x^{2}+4 x^{3}+4 x^{4}\) \(32\)
risch \({\mathrm e}^{2 x} x^{2}-4 \,{\mathrm e}^{x} x^{3}-16 x^{2}+4 x^{3}+4 x^{4}\) \(32\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((2*x^2+2*x)*exp(x)^2+(-4*x^3-12*x^2)*exp(x)+16*x^3+12*x^2-32*x,x,method=_RETURNVERBOSE)

[Out]

exp(x)^2*x^2-4*exp(x)*x^3-16*x^2+4*x^3+4*x^4

________________________________________________________________________________________

maxima [A]  time = 0.36, size = 31, normalized size = 1.63 \begin {gather*} 4 \, x^{4} - 4 \, x^{3} e^{x} + 4 \, x^{3} + x^{2} e^{\left (2 \, x\right )} - 16 \, x^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2+2*x)*exp(x)^2+(-4*x^3-12*x^2)*exp(x)+16*x^3+12*x^2-32*x,x, algorithm="maxima")

[Out]

4*x^4 - 4*x^3*e^x + 4*x^3 + x^2*e^(2*x) - 16*x^2

________________________________________________________________________________________

mupad [B]  time = 5.09, size = 23, normalized size = 1.21 \begin {gather*} x^2\,\left (4\,x+{\mathrm {e}}^{2\,x}-4\,x\,{\mathrm {e}}^x+4\,x^2-16\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(2*x)*(2*x + 2*x^2) - 32*x - exp(x)*(12*x^2 + 4*x^3) + 12*x^2 + 16*x^3,x)

[Out]

x^2*(4*x + exp(2*x) - 4*x*exp(x) + 4*x^2 - 16)

________________________________________________________________________________________

sympy [A]  time = 0.11, size = 31, normalized size = 1.63 \begin {gather*} 4 x^{4} - 4 x^{3} e^{x} + 4 x^{3} + x^{2} e^{2 x} - 16 x^{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x**2+2*x)*exp(x)**2+(-4*x**3-12*x**2)*exp(x)+16*x**3+12*x**2-32*x,x)

[Out]

4*x**4 - 4*x**3*exp(x) + 4*x**3 + x**2*exp(2*x) - 16*x**2

________________________________________________________________________________________