3.56.21 \(\int e^{-12+x} (e^{12}-e^{12-x}+8 x+4 x^2) \, dx\)

Optimal. Leaf size=24 \[ -\frac {e^5}{5}+e^x-x+4 e^{-12+x} x^2 \]

________________________________________________________________________________________

Rubi [A]  time = 0.12, antiderivative size = 17, normalized size of antiderivative = 0.71, number of steps used = 10, number of rules used = 4, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.148, Rules used = {6688, 2194, 2196, 2176} \begin {gather*} 4 e^{x-12} x^2-x+e^x \end {gather*}

Antiderivative was successfully verified.

[In]

Int[E^(-12 + x)*(E^12 - E^(12 - x) + 8*x + 4*x^2),x]

[Out]

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

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

Rule 6688

Int[u_, x_Symbol] :> With[{v = SimplifyIntegrand[u, x]}, Int[v, x] /; SimplerIntegrandQ[v, u, x]]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 17, normalized size = 0.71 \begin {gather*} e^x-x+4 e^{-12+x} x^2 \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[E^(-12 + x)*(E^12 - E^(12 - x) + 8*x + 4*x^2),x]

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((exp(12-x)*exp(x)-exp(12-x)+4*x^2+8*x)/exp(12-x),x, algorithm="fricas")

[Out]

(4*x^2 + e^12)*e^(x - 12) - x

________________________________________________________________________________________

giac [A]  time = 0.13, size = 15, normalized size = 0.62 \begin {gather*} 4 \, x^{2} e^{\left (x - 12\right )} - x + e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((exp(12-x)*exp(x)-exp(12-x)+4*x^2+8*x)/exp(12-x),x, algorithm="giac")

[Out]

4*x^2*e^(x - 12) - x + e^x

________________________________________________________________________________________

maple [A]  time = 0.07, size = 18, normalized size = 0.75




method result size



risch \(-x +\left (4 x^{2}+{\mathrm e}^{12}\right ) {\mathrm e}^{x -12}\) \(18\)
norman \(\left ({\mathrm e}^{2 x}-{\mathrm e}^{x} x +4 \,{\mathrm e}^{-12} x^{2} {\mathrm e}^{2 x}\right ) {\mathrm e}^{-x}\) \(29\)
default \(-x +8 \,{\mathrm e}^{-12} \left ({\mathrm e}^{x} x -{\mathrm e}^{x}\right )+4 \,{\mathrm e}^{-12} \left ({\mathrm e}^{x} x^{2}-2 \,{\mathrm e}^{x} x +2 \,{\mathrm e}^{x}\right )+{\mathrm e}^{x}\) \(44\)
meijerg \(-{\mathrm e}^{x -x \,{\mathrm e}^{-12}+12} \left (1-{\mathrm e}^{x \,{\mathrm e}^{-12}}\right )+\frac {{\mathrm e}^{x -x \,{\mathrm e}^{-12}+12} \left (1-{\mathrm e}^{x \,{\mathrm e}^{-12} \left (-{\mathrm e}^{12}+1\right )}\right )}{-{\mathrm e}^{12}+1}-4 \,{\mathrm e}^{24+x -x \,{\mathrm e}^{-12}} \left (2-\frac {\left (3 x^{2} {\mathrm e}^{-24}-6 x \,{\mathrm e}^{-12}+6\right ) {\mathrm e}^{x \,{\mathrm e}^{-12}}}{3}\right )+8 \,{\mathrm e}^{x -x \,{\mathrm e}^{-12}+12} \left (1-\frac {\left (2-2 x \,{\mathrm e}^{-12}\right ) {\mathrm e}^{x \,{\mathrm e}^{-12}}}{2}\right )\) \(116\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((exp(12-x)*exp(x)-exp(12-x)+4*x^2+8*x)/exp(12-x),x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

maxima [A]  time = 0.38, size = 29, normalized size = 1.21 \begin {gather*} 4 \, {\left (x^{2} - 2 \, x + 2\right )} e^{\left (x - 12\right )} + 8 \, {\left (x - 1\right )} e^{\left (x - 12\right )} - x + e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((exp(12-x)*exp(x)-exp(12-x)+4*x^2+8*x)/exp(12-x),x, algorithm="maxima")

[Out]

4*(x^2 - 2*x + 2)*e^(x - 12) + 8*(x - 1)*e^(x - 12) - x + e^x

________________________________________________________________________________________

mupad [B]  time = 3.49, size = 15, normalized size = 0.62 \begin {gather*} {\mathrm {e}}^x-x+4\,x^2\,{\mathrm {e}}^{-12}\,{\mathrm {e}}^x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(x - 12)*(8*x - exp(12 - x) + 4*x^2 + exp(12 - x)*exp(x)),x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.11, size = 15, normalized size = 0.62 \begin {gather*} - x + \frac {\left (4 x^{2} + e^{12}\right ) e^{x}}{e^{12}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((exp(12-x)*exp(x)-exp(12-x)+4*x**2+8*x)/exp(12-x),x)

[Out]

-x + (4*x**2 + exp(12))*exp(-12)*exp(x)

________________________________________________________________________________________