3.15.49 \(\int \frac {e^{-x^2} (-1+9 x-4 x^2-18 x^3-2 x^4+2 x^2 \log (x))}{4 x} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.51, antiderivative size = 51, normalized size of antiderivative = 1.89, number of steps used = 15, number of rules used = 7, integrand size = 41, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.171, Rules used = {12, 6742, 2205, 2210, 2209, 2212, 2554} \begin {gather*} \frac {1}{4} e^{-x^2} x^2+\frac {9}{4} e^{-x^2} x+\frac {3 e^{-x^2}}{4}-\frac {1}{4} e^{-x^2} \log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

3/(4*E^x^2) + (9*x)/(4*E^x^2) + x^2/(4*E^x^2) - Log[x]/(4*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 2210

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^(n_))/((e_.) + (f_.)*(x_)), x_Symbol] :> Simp[(F^a*ExpIntegralEi[
b*(c + d*x)^n*Log[F]])/(f*n), x] /; FreeQ[{F, a, b, c, d, e, f, n}, x] && 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 2554

Int[Log[u_]*(v_), x_Symbol] :> With[{w = IntHide[v, x]}, Dist[Log[u], w, x] - Int[SimplifyIntegrand[(w*D[u, x]
)/u, x], x] /; InverseFunctionFreeQ[w, x]] /; InverseFunctionFreeQ[u, 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}{4} \int \frac {e^{-x^2} \left (-1+9 x-4 x^2-18 x^3-2 x^4+2 x^2 \log (x)\right )}{x} \, dx\\ &=\frac {1}{4} \int \left (\frac {e^{-x^2} \left (-1+9 x-4 x^2-18 x^3-2 x^4\right )}{x}+2 e^{-x^2} x \log (x)\right ) \, dx\\ &=\frac {1}{4} \int \frac {e^{-x^2} \left (-1+9 x-4 x^2-18 x^3-2 x^4\right )}{x} \, dx+\frac {1}{2} \int e^{-x^2} x \log (x) \, dx\\ &=-\frac {1}{4} e^{-x^2} \log (x)+\frac {1}{4} \int \left (9 e^{-x^2}-\frac {e^{-x^2}}{x}-4 e^{-x^2} x-18 e^{-x^2} x^2-2 e^{-x^2} x^3\right ) \, dx-\frac {1}{2} \int -\frac {e^{-x^2}}{2 x} \, dx\\ &=-\frac {1}{4} e^{-x^2} \log (x)-\frac {1}{2} \int e^{-x^2} x^3 \, dx+\frac {9}{4} \int e^{-x^2} \, dx-\frac {9}{2} \int e^{-x^2} x^2 \, dx-\int e^{-x^2} x \, dx\\ &=\frac {e^{-x^2}}{2}+\frac {9}{4} e^{-x^2} x+\frac {1}{4} e^{-x^2} x^2+\frac {9}{8} \sqrt {\pi } \text {erf}(x)-\frac {1}{4} e^{-x^2} \log (x)-\frac {1}{2} \int e^{-x^2} x \, dx-\frac {9}{4} \int e^{-x^2} \, dx\\ &=\frac {3 e^{-x^2}}{4}+\frac {9}{4} e^{-x^2} x+\frac {1}{4} e^{-x^2} x^2-\frac {1}{4} e^{-x^2} \log (x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.11, size = 23, normalized size = 0.85 \begin {gather*} \frac {1}{4} e^{-x^2} \left (3+9 x+x^2-\log (x)\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

(3 + 9*x + x^2 - Log[x])/(4*E^x^2)

________________________________________________________________________________________

fricas [A]  time = 0.85, size = 27, normalized size = 1.00 \begin {gather*} \frac {1}{4} \, {\left (x^{2} + 9 \, x + 3\right )} e^{\left (-x^{2}\right )} - \frac {1}{4} \, e^{\left (-x^{2}\right )} \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(x^2 + 9*x + 3)*e^(-x^2) - 1/4*e^(-x^2)*log(x)

________________________________________________________________________________________

giac [A]  time = 0.39, size = 39, normalized size = 1.44 \begin {gather*} \frac {1}{4} \, x^{2} e^{\left (-x^{2}\right )} + \frac {9}{4} \, x e^{\left (-x^{2}\right )} - \frac {1}{4} \, e^{\left (-x^{2}\right )} \log \relax (x) + \frac {3}{4} \, e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*x^2*e^(-x^2) + 9/4*x*e^(-x^2) - 1/4*e^(-x^2)*log(x) + 3/4*e^(-x^2)

________________________________________________________________________________________

maple [A]  time = 0.04, size = 22, normalized size = 0.81




method result size



norman \(\left (\frac {3}{4}+\frac {9 x}{4}+\frac {x^{2}}{4}-\frac {\ln \relax (x )}{4}\right ) {\mathrm e}^{-x^{2}}\) \(22\)
risch \(-\frac {{\mathrm e}^{-x^{2}} \ln \relax (x )}{4}+\frac {\left (x^{2}+9 x +3\right ) {\mathrm e}^{-x^{2}}}{4}\) \(28\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

(3/4+9/4*x+1/4*x^2-1/4*ln(x))/exp(x^2)

________________________________________________________________________________________

maxima [A]  time = 0.53, size = 41, normalized size = 1.52 \begin {gather*} \frac {1}{4} \, {\left (x^{2} + 1\right )} e^{\left (-x^{2}\right )} + \frac {9}{4} \, x e^{\left (-x^{2}\right )} - \frac {1}{4} \, e^{\left (-x^{2}\right )} \log \relax (x) + \frac {1}{2} \, e^{\left (-x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/4*(x^2 + 1)*e^(-x^2) + 9/4*x*e^(-x^2) - 1/4*e^(-x^2)*log(x) + 1/2*e^(-x^2)

________________________________________________________________________________________

mupad [B]  time = 1.07, size = 20, normalized size = 0.74 \begin {gather*} \frac {{\mathrm {e}}^{-x^2}\,\left (9\,x-\ln \relax (x)+x^2+3\right )}{4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(exp(-x^2)*(x^2 - (x^2*log(x))/2 - (9*x)/4 + (9*x^3)/2 + x^4/2 + 1/4))/x,x)

[Out]

(exp(-x^2)*(9*x - log(x) + x^2 + 3))/4

________________________________________________________________________________________

sympy [A]  time = 0.32, size = 17, normalized size = 0.63 \begin {gather*} \frac {\left (x^{2} + 9 x - \log {\relax (x )} + 3\right ) e^{- x^{2}}}{4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(1/4*(2*x**2*ln(x)-2*x**4-18*x**3-4*x**2+9*x-1)/exp(x**2)/x,x)

[Out]

(x**2 + 9*x - log(x) + 3)*exp(-x**2)/4

________________________________________________________________________________________