3.76.29 \(\int e^{-x} (e^x (1+e^2 (-4-2 x))+e^9 (-1+x)) \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.06, antiderivative size = 34, normalized size of antiderivative = 1.89, number of steps used = 4, number of rules used = 3, integrand size = 29, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.103, Rules used = {6688, 2176, 2194} \begin {gather*} -e^2 (x+2)^2-e^{9-x}+e^{9-x} (1-x)+x \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(E^x*(1 + E^2*(-4 - 2*x)) + E^9*(-1 + x))/E^x,x]

[Out]

-E^(9 - x) + E^(9 - x)*(1 - x) + x - E^2*(2 + 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 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^{9-x} (-1+x)-2 e^2 (2+x)\right ) \, dx\\ &=x-e^2 (2+x)^2+\int e^{9-x} (-1+x) \, dx\\ &=e^{9-x} (1-x)+x-e^2 (2+x)^2+\int e^{9-x} \, dx\\ &=-e^{9-x}+e^{9-x} (1-x)+x-e^2 (2+x)^2\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 26, normalized size = 1.44 \begin {gather*} x-4 e^2 x-e^{9-x} x-e^2 x^2 \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(E^x*(1 + E^2*(-4 - 2*x)) + E^9*(-1 + x))/E^x,x]

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.54, size = 28, normalized size = 1.56 \begin {gather*} -{\left (x e^{9} + {\left ({\left (x^{2} + 4 \, x\right )} e^{2} - x\right )} e^{x}\right )} e^{\left (-x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

giac [A]  time = 0.20, size = 22, normalized size = 1.22 \begin {gather*} -{\left (x^{2} + 4 \, x\right )} e^{2} - x e^{\left (-x + 9\right )} + x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.03, size = 24, normalized size = 1.33




method result size



risch \(-x^{2} {\mathrm e}^{2}-4 \,{\mathrm e}^{2} x +x -x \,{\mathrm e}^{9-x}\) \(24\)
norman \(\left (\left (-4 \,{\mathrm e}^{2}+1\right ) x \,{\mathrm e}^{x}-x^{2} {\mathrm e}^{2} {\mathrm e}^{x}-{\mathrm e} \left ({\mathrm e}^{4}\right )^{2} x \right ) {\mathrm e}^{-x}\) \(37\)
default \(x +{\mathrm e} \left ({\mathrm e}^{4}\right )^{2} \left (-x \,{\mathrm e}^{-x}-{\mathrm e}^{-x}\right )-x^{2} {\mathrm e}^{2}+{\mathrm e}^{-x} {\mathrm e} \left ({\mathrm e}^{4}\right )^{2}-4 \,{\mathrm e}^{2} x\) \(51\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maxima [B]  time = 0.37, size = 33, normalized size = 1.83 \begin {gather*} -x^{2} e^{2} - 4 \, x e^{2} - {\left (x e^{9} + e^{9}\right )} e^{\left (-x\right )} + x + e^{\left (-x + 9\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 0.09, size = 19, normalized size = 1.06 \begin {gather*} -x\,\left (4\,{\mathrm {e}}^2+{\mathrm {e}}^{9-x}+x\,{\mathrm {e}}^2-1\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-exp(-x)*(exp(x)*(exp(2)*(2*x + 4) - 1) - exp(9)*(x - 1)),x)

[Out]

-x*(4*exp(2) + exp(9 - x) + x*exp(2) - 1)

________________________________________________________________________________________

sympy [A]  time = 0.12, size = 22, normalized size = 1.22 \begin {gather*} - x^{2} e^{2} + x \left (1 - 4 e^{2}\right ) - x e^{9} e^{- x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x**2*exp(2) + x*(1 - 4*exp(2)) - x*exp(9)*exp(-x)

________________________________________________________________________________________