3.78.11 \(\int (-1+e^x-2 x-2 e^{2-x^2} x) \, dx\)

Optimal. Leaf size=22 \[ -2+e^x+e^{2-x^2}-x-x^2 \]

________________________________________________________________________________________

Rubi [A]  time = 0.01, antiderivative size = 21, normalized size of antiderivative = 0.95, number of steps used = 3, number of rules used = 2, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {2194, 2209} \begin {gather*} -x^2+e^{2-x^2}-x+e^x \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

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 2209

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^(n_))*((e_.) + (f_.)*(x_))^(m_.), x_Symbol] :> Simp[((e + f*x)^n*
F^(a + b*(c + d*x)^n))/(b*f*n*(c + d*x)^n*Log[F]), x] /; FreeQ[{F, a, b, c, d, e, f, n}, x] && EqQ[m, n - 1] &
& EqQ[d*e - c*f, 0]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=-x-x^2-2 \int e^{2-x^2} x \, dx+\int e^x \, dx\\ &=e^x+e^{2-x^2}-x-x^2\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 21, normalized size = 0.95 \begin {gather*} e^x+e^{2-x^2}-x-x^2 \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.58, size = 19, normalized size = 0.86 \begin {gather*} -x^{2} - x + e^{\left (-x^{2} + 2\right )} + e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x^2 - x + e^(-x^2 + 2) + e^x

________________________________________________________________________________________

giac [A]  time = 0.12, size = 19, normalized size = 0.86 \begin {gather*} -x^{2} - x + e^{\left (-x^{2} + 2\right )} + e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x^2 - x + e^(-x^2 + 2) + e^x

________________________________________________________________________________________

maple [A]  time = 0.01, size = 20, normalized size = 0.91




method result size



default \(-x^{2}-x +{\mathrm e}^{-x^{2}+2}+{\mathrm e}^{x}\) \(20\)
norman \(-x^{2}-x +{\mathrm e}^{-x^{2}+2}+{\mathrm e}^{x}\) \(20\)
risch \(-x^{2}-x +{\mathrm e}^{-x^{2}+2}+{\mathrm e}^{x}\) \(20\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x^2-x+exp(-x^2+2)+exp(x)

________________________________________________________________________________________

maxima [A]  time = 0.37, size = 19, normalized size = 0.86 \begin {gather*} -x^{2} - x + e^{\left (-x^{2} + 2\right )} + e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-x^2 - x + e^(-x^2 + 2) + e^x

________________________________________________________________________________________

mupad [B]  time = 5.58, size = 19, normalized size = 0.86 \begin {gather*} {\mathrm {e}}^x-x+{\mathrm {e}}^{2-x^2}-x^2 \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(x) - 2*x - 2*x*exp(2 - x^2) - 1,x)

[Out]

exp(x) - x + exp(2 - x^2) - x^2

________________________________________________________________________________________

sympy [A]  time = 0.17, size = 14, normalized size = 0.64 \begin {gather*} - x^{2} - x + e^{x} + e^{2 - x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________