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

Optimal. Leaf size=24 \[ x+\frac {1}{8} \left (-3-e^{-x^2} (5+x)\right )-\log (4) \]

________________________________________________________________________________________

Rubi [A]  time = 0.11, antiderivative size = 25, normalized size of antiderivative = 1.04, number of steps used = 7, number of rules used = 5, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.179, Rules used = {12, 6742, 2205, 2209, 2212} \begin {gather*} -\frac {1}{8} e^{-x^2} x-\frac {5 e^{-x^2}}{8}+x \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2205

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[(F^a*Sqrt[Pi]*Erf[(c + d*x)*Rt[-(b*Log[F]),
 2]])/(2*d*Rt[-(b*Log[F]), 2]), x] /; FreeQ[{F, a, b, c, d}, x] && NegQ[b]

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 2212

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^(n_))*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[((c + d*x)^(m
 - n + 1)*F^(a + b*(c + d*x)^n))/(b*d*n*Log[F]), x] - Dist[(m - n + 1)/(b*n*Log[F]), Int[(c + d*x)^(m - n)*F^(
a + b*(c + d*x)^n), x], x] /; FreeQ[{F, a, b, c, d}, x] && IntegerQ[(2*(m + 1))/n] && LtQ[0, (m + 1)/n, 5] &&
IntegerQ[n] && (LtQ[0, n, m + 1] || LtQ[m, n, 0])

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}{8} \int e^{-x^2} \left (-1+8 e^{x^2}+10 x+2 x^2\right ) \, dx\\ &=\frac {1}{8} \int \left (8-e^{-x^2}+10 e^{-x^2} x+2 e^{-x^2} x^2\right ) \, dx\\ &=x-\frac {1}{8} \int e^{-x^2} \, dx+\frac {1}{4} \int e^{-x^2} x^2 \, dx+\frac {5}{4} \int e^{-x^2} x \, dx\\ &=-\frac {5 e^{-x^2}}{8}+x-\frac {1}{8} e^{-x^2} x-\frac {1}{16} \sqrt {\pi } \text {erf}(x)+\frac {1}{8} \int e^{-x^2} \, dx\\ &=-\frac {5 e^{-x^2}}{8}+x-\frac {1}{8} e^{-x^2} x\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 27, normalized size = 1.12 \begin {gather*} \frac {1}{8} \left (-5 e^{-x^2}+8 x-e^{-x^2} x\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.90, size = 20, normalized size = 0.83 \begin {gather*} \frac {1}{8} \, {\left (8 \, x e^{\left (x^{2}\right )} - x - 5\right )} e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.02, size = 16, normalized size = 0.67




method result size



risch \(x +\frac {\left (-x -5\right ) {\mathrm e}^{-x^{2}}}{8}\) \(16\)
norman \(\left (-\frac {5}{8}+{\mathrm e}^{x^{2}} x -\frac {x}{8}\right ) {\mathrm e}^{-x^{2}}\) \(19\)
default \(x -\frac {5 \,{\mathrm e}^{-x^{2}}}{8}-\frac {x \,{\mathrm e}^{-x^{2}}}{8}\) \(20\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

maxima [A]  time = 0.35, size = 19, normalized size = 0.79 \begin {gather*} -\frac {1}{8} \, x e^{\left (-x^{2}\right )} + x - \frac {5}{8} \, e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 0.06, size = 19, normalized size = 0.79 \begin {gather*} x-\frac {5\,{\mathrm {e}}^{-x^2}}{8}-\frac {x\,{\mathrm {e}}^{-x^2}}{8} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.10, size = 12, normalized size = 0.50 \begin {gather*} x + \frac {\left (- x - 5\right ) e^{- x^{2}}}{8} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________