3.68.100 \(\int \frac {1}{5} e^{-x^2} (10 e^{x^2}-10 x+e^{2 x+2 x^2} (1+2 x+2 x^2)) \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.18, antiderivative size = 39, normalized size of antiderivative = 1.18, number of steps used = 5, number of rules used = 4, integrand size = 44, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {12, 6742, 2209, 2288} \begin {gather*} e^{-x^2}+\frac {e^{2 x (x+1)-x^2} \left (x^2+x\right )}{5 (x+1)}+2 x \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

E^(-x^2) + 2*x + (E^(-x^2 + 2*x*(1 + x))*(x + x^2))/(5*(1 + x))

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, 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]

Rule 2288

Int[(y_.)*(F_)^(u_)*((v_) + (w_)), x_Symbol] :> With[{z = (v*y)/(Log[F]*D[u, x])}, Simp[F^u*z, x] /; EqQ[D[z,
x], w*y]] /; FreeQ[F, x]

Rule 6742

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

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.04, size = 23, normalized size = 0.70 \begin {gather*} e^{-x^2}+2 x+\frac {1}{5} e^{x (2+x)} x \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

E^(-x^2) + 2*x + (E^(x*(2 + x))*x)/5

________________________________________________________________________________________

fricas [A]  time = 0.67, size = 29, normalized size = 0.88 \begin {gather*} \frac {1}{5} \, {\left (x e^{\left (2 \, x^{2} + 2 \, x\right )} + 10 \, x e^{\left (x^{2}\right )} + 5\right )} e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/5*(x*e^(2*x^2 + 2*x) + 10*x*e^(x^2) + 5)*e^(-x^2)

________________________________________________________________________________________

giac [A]  time = 0.19, size = 21, normalized size = 0.64 \begin {gather*} \frac {1}{5} \, x e^{\left (x^{2} + 2 \, x\right )} + 2 \, x + e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/5*x*e^(x^2 + 2*x) + 2*x + e^(-x^2)

________________________________________________________________________________________

maple [A]  time = 0.04, size = 20, normalized size = 0.61




method result size



risch \(2 x +{\mathrm e}^{-x^{2}}+\frac {x \,{\mathrm e}^{x \left (2+x \right )}}{5}\) \(20\)
default \(2 x +{\mathrm e}^{-x^{2}}+\frac {x \,{\mathrm e}^{x^{2}+2 x}}{5}\) \(22\)
norman \(\left (1+2 \,{\mathrm e}^{x^{2}} x +\frac {{\mathrm e}^{2 x^{2}+2 x} x}{5}\right ) {\mathrm e}^{-x^{2}}\) \(30\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

2*x+exp(-x^2)+1/5*x*exp(x*(2+x))

________________________________________________________________________________________

maxima [C]  time = 0.42, size = 130, normalized size = 3.94 \begin {gather*} -\frac {1}{10} i \, \sqrt {\pi } \operatorname {erf}\left (i \, x + i\right ) e^{\left (-1\right )} - \frac {1}{5} \, {\left (\frac {{\left (x + 1\right )}^{3} \Gamma \left (\frac {3}{2}, -{\left (x + 1\right )}^{2}\right )}{\left (-{\left (x + 1\right )}^{2}\right )^{\frac {3}{2}}} - \frac {\sqrt {\pi } {\left (x + 1\right )} {\left (\operatorname {erf}\left (\sqrt {-{\left (x + 1\right )}^{2}}\right ) - 1\right )}}{\sqrt {-{\left (x + 1\right )}^{2}}} + 2 \, e^{\left ({\left (x + 1\right )}^{2}\right )}\right )} e^{\left (-1\right )} - \frac {1}{5} \, {\left (\frac {\sqrt {\pi } {\left (x + 1\right )} {\left (\operatorname {erf}\left (\sqrt {-{\left (x + 1\right )}^{2}}\right ) - 1\right )}}{\sqrt {-{\left (x + 1\right )}^{2}}} - e^{\left ({\left (x + 1\right )}^{2}\right )}\right )} e^{\left (-1\right )} + 2 \, x + e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-1/10*I*sqrt(pi)*erf(I*x + I)*e^(-1) - 1/5*((x + 1)^3*gamma(3/2, -(x + 1)^2)/(-(x + 1)^2)^(3/2) - sqrt(pi)*(x
+ 1)*(erf(sqrt(-(x + 1)^2)) - 1)/sqrt(-(x + 1)^2) + 2*e^((x + 1)^2))*e^(-1) - 1/5*(sqrt(pi)*(x + 1)*(erf(sqrt(
-(x + 1)^2)) - 1)/sqrt(-(x + 1)^2) - e^((x + 1)^2))*e^(-1) + 2*x + e^(-x^2)

________________________________________________________________________________________

mupad [B]  time = 0.13, size = 21, normalized size = 0.64 \begin {gather*} 2\,x+{\mathrm {e}}^{-x^2}+\frac {x\,{\mathrm {e}}^{x^2+2\,x}}{5} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(-x^2)*(2*exp(x^2) - 2*x + (exp(2*x + 2*x^2)*(2*x + 2*x^2 + 1))/5),x)

[Out]

2*x + exp(-x^2) + (x*exp(2*x + x^2))/5

________________________________________________________________________________________

sympy [A]  time = 1.40, size = 27, normalized size = 0.82 \begin {gather*} 2 x + \frac {x e^{- x^{2}} e^{2 x^{2} + 2 x}}{5} + e^{- x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________