3.81.38 \(\int \frac {-2 e^{25+10 e^2+e^4+x^2} x^2+e^{x^2} (2-x+8 x^2-2 x^3)+4 e^{x^2} x^2 \log (x)}{x} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.12, antiderivative size = 37, normalized size of antiderivative = 1.42, number of steps used = 10, number of rules used = 7, integrand size = 58, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.121, Rules used = {14, 2204, 2210, 2209, 2212, 2554, 12} \begin {gather*} -e^{x^2} x+\left (4-e^{\left (5+e^2\right )^2}\right ) e^{x^2}+2 e^{x^2} \log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-2*E^(25 + 10*E^2 + E^4 + x^2)*x^2 + E^x^2*(2 - x + 8*x^2 - 2*x^3) + 4*E^x^2*x^2*Log[x])/x,x]

[Out]

E^x^2*(4 - E^(5 + E^2)^2) - E^x^2*x + 2*E^x^2*Log[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 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 2204

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^2), x_Symbol] :> Simp[(F^a*Sqrt[Pi]*Erfi[(c + d*x)*Rt[b*Log[F], 2
]])/(2*d*Rt[b*Log[F], 2]), x] /; FreeQ[{F, a, b, c, d}, x] && PosQ[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]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (-e^{x^2}+\frac {2 e^{x^2}}{x}+8 e^{x^2} \left (1-\frac {1}{4} e^{\left (5+e^2\right )^2}\right ) x-2 e^{x^2} x^2+4 e^{x^2} x \log (x)\right ) \, dx\\ &=2 \int \frac {e^{x^2}}{x} \, dx-2 \int e^{x^2} x^2 \, dx+4 \int e^{x^2} x \log (x) \, dx+\left (2 \left (4-e^{\left (5+e^2\right )^2}\right )\right ) \int e^{x^2} x \, dx-\int e^{x^2} \, dx\\ &=e^{x^2} \left (4-e^{\left (5+e^2\right )^2}\right )-e^{x^2} x-\frac {1}{2} \sqrt {\pi } \text {erfi}(x)+\text {Ei}\left (x^2\right )+2 e^{x^2} \log (x)-4 \int \frac {e^{x^2}}{2 x} \, dx+\int e^{x^2} \, dx\\ &=e^{x^2} \left (4-e^{\left (5+e^2\right )^2}\right )-e^{x^2} x+\text {Ei}\left (x^2\right )+2 e^{x^2} \log (x)-2 \int \frac {e^{x^2}}{x} \, dx\\ &=e^{x^2} \left (4-e^{\left (5+e^2\right )^2}\right )-e^{x^2} x+2 e^{x^2} \log (x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.07, size = 23, normalized size = 0.88 \begin {gather*} -e^{x^2} \left (-4+e^{\left (5+e^2\right )^2}+x-2 \log (x)\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-2*E^(25 + 10*E^2 + E^4 + x^2)*x^2 + E^x^2*(2 - x + 8*x^2 - 2*x^3) + 4*E^x^2*x^2*Log[x])/x,x]

[Out]

-(E^x^2*(-4 + E^(5 + E^2)^2 + x - 2*Log[x]))

________________________________________________________________________________________

fricas [B]  time = 0.65, size = 55, normalized size = 2.12 \begin {gather*} -{\left ({\left (x + e^{\left (e^{4} + 10 \, e^{2} + 25\right )} - 4\right )} e^{\left (x^{2} + e^{4} + 10 \, e^{2} + 25\right )} - 2 \, e^{\left (x^{2} + e^{4} + 10 \, e^{2} + 25\right )} \log \relax (x)\right )} e^{\left (-e^{4} - 10 \, e^{2} - 25\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((4*x^2*exp(x^2)*log(x)-2*x^2*exp(x^2)*exp(exp(2)^2+10*exp(2)+25)+(-2*x^3+8*x^2-x+2)*exp(x^2))/x,x, a
lgorithm="fricas")

[Out]

-((x + e^(e^4 + 10*e^2 + 25) - 4)*e^(x^2 + e^4 + 10*e^2 + 25) - 2*e^(x^2 + e^4 + 10*e^2 + 25)*log(x))*e^(-e^4
- 10*e^2 - 25)

________________________________________________________________________________________

giac [A]  time = 0.27, size = 36, normalized size = 1.38 \begin {gather*} -x e^{\left (x^{2}\right )} + 2 \, e^{\left (x^{2}\right )} \log \relax (x) - e^{\left (x^{2} + e^{4} + 10 \, e^{2} + 25\right )} + 4 \, e^{\left (x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((4*x^2*exp(x^2)*log(x)-2*x^2*exp(x^2)*exp(exp(2)^2+10*exp(2)+25)+(-2*x^3+8*x^2-x+2)*exp(x^2))/x,x, a
lgorithm="giac")

[Out]

-x*e^(x^2) + 2*e^(x^2)*log(x) - e^(x^2 + e^4 + 10*e^2 + 25) + 4*e^(x^2)

________________________________________________________________________________________

maple [A]  time = 0.09, size = 28, normalized size = 1.08




method result size



risch \(2 \,{\mathrm e}^{x^{2}} \ln \relax (x )-\left ({\mathrm e}^{{\mathrm e}^{4}+10 \,{\mathrm e}^{2}+25}+x -4\right ) {\mathrm e}^{x^{2}}\) \(28\)
default \(-{\mathrm e}^{x^{2}} x +2 \,{\mathrm e}^{x^{2}} \ln \relax (x )+4 \,{\mathrm e}^{x^{2}}-{\mathrm e}^{x^{2}+{\mathrm e}^{4}+10 \,{\mathrm e}^{2}+25}\) \(37\)
norman \(\left (-{\mathrm e}^{25} {\mathrm e}^{{\mathrm e}^{4}} {\mathrm e}^{10 \,{\mathrm e}^{2}}+4\right ) {\mathrm e}^{x^{2}}-{\mathrm e}^{x^{2}} x +2 \,{\mathrm e}^{x^{2}} \ln \relax (x )\) \(38\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((4*x^2*exp(x^2)*ln(x)-2*x^2*exp(x^2)*exp(exp(2)^2+10*exp(2)+25)+(-2*x^3+8*x^2-x+2)*exp(x^2))/x,x,method=_R
ETURNVERBOSE)

[Out]

2*exp(x^2)*ln(x)-(exp(exp(4)+10*exp(2)+25)+x-4)*exp(x^2)

________________________________________________________________________________________

maxima [A]  time = 0.39, size = 36, normalized size = 1.38 \begin {gather*} -x e^{\left (x^{2}\right )} + 2 \, e^{\left (x^{2}\right )} \log \relax (x) - e^{\left (x^{2} + e^{4} + 10 \, e^{2} + 25\right )} + 4 \, e^{\left (x^{2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((4*x^2*exp(x^2)*log(x)-2*x^2*exp(x^2)*exp(exp(2)^2+10*exp(2)+25)+(-2*x^3+8*x^2-x+2)*exp(x^2))/x,x, a
lgorithm="maxima")

[Out]

-x*e^(x^2) + 2*e^(x^2)*log(x) - e^(x^2 + e^4 + 10*e^2 + 25) + 4*e^(x^2)

________________________________________________________________________________________

mupad [B]  time = 6.13, size = 22, normalized size = 0.85 \begin {gather*} -{\mathrm {e}}^{x^2}\,\left (x-2\,\ln \relax (x)+{\mathrm {e}}^{10\,{\mathrm {e}}^2+{\mathrm {e}}^4+25}-4\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(exp(x^2)*(x - 8*x^2 + 2*x^3 - 2) - 4*x^2*exp(x^2)*log(x) + 2*x^2*exp(x^2)*exp(10*exp(2) + exp(4) + 25))/
x,x)

[Out]

-exp(x^2)*(x - 2*log(x) + exp(10*exp(2) + exp(4) + 25) - 4)

________________________________________________________________________________________

sympy [A]  time = 0.38, size = 27, normalized size = 1.04 \begin {gather*} \left (- x + 2 \log {\relax (x )} - e^{25} e^{10 e^{2}} e^{e^{4}} + 4\right ) e^{x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((4*x**2*exp(x**2)*ln(x)-2*x**2*exp(x**2)*exp(exp(2)**2+10*exp(2)+25)+(-2*x**3+8*x**2-x+2)*exp(x**2))
/x,x)

[Out]

(-x + 2*log(x) - exp(25)*exp(10*exp(2))*exp(exp(4)) + 4)*exp(x**2)

________________________________________________________________________________________