3.42.29 \(\int (-5+e^x (1+x)+(-5+e^x (1+3 x+x^2)) \log (x)) \, dx\) [4129]

Optimal. Leaf size=13 \[ x \left (-5+e^x (1+x)\right ) \log (x) \]

[Out]

((1+x)*exp(x)-5)*ln(x)*x

________________________________________________________________________________________

Rubi [A]
time = 0.07, antiderivative size = 22, normalized size of antiderivative = 1.69, number of steps used = 7, number of rules used = 4, integrand size = 26, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {2207, 2225, 2227, 2634} \begin {gather*} e^x x^2 \log (x)+e^x x \log (x)-5 x \log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

-5*x*Log[x] + E^x*x*Log[x] + E^x*x^2*Log[x]

Rule 2207

Int[((b_.)*(F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[(c + d*x)^m*
((b*F^(g*(e + f*x)))^n/(f*g*n*Log[F])), x] - Dist[d*(m/(f*g*n*Log[F])), Int[(c + d*x)^(m - 1)*(b*F^(g*(e + f*x
)))^n, x], x] /; FreeQ[{F, b, c, d, e, f, g, n}, x] && GtQ[m, 0] && IntegerQ[2*m] &&  !TrueQ[$UseGamma]

Rule 2225

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 2227

Int[(F_)^((c_.)*(v_))*(u_), x_Symbol] :> Int[ExpandIntegrand[F^(c*ExpandToSum[v, x]), u, x], x] /; FreeQ[{F, c
}, x] && PolynomialQ[u, x] && LinearQ[v, x] &&  !TrueQ[$UseGamma]

Rule 2634

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} &=-5 x+\int e^x (1+x) \, dx+\int \left (-5+e^x \left (1+3 x+x^2\right )\right ) \log (x) \, dx\\ &=-5 x+e^x (1+x)-5 x \log (x)+e^x x \log (x)+e^x x^2 \log (x)-\int e^x \, dx-\int \left (-5+e^x (1+x)\right ) \, dx\\ &=-e^x+e^x (1+x)-5 x \log (x)+e^x x \log (x)+e^x x^2 \log (x)-\int e^x (1+x) \, dx\\ &=-e^x-5 x \log (x)+e^x x \log (x)+e^x x^2 \log (x)+\int e^x \, dx\\ &=-5 x \log (x)+e^x x \log (x)+e^x x^2 \log (x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]
time = 0.02, size = 14, normalized size = 1.08 \begin {gather*} x \left (-5+e^x+e^x x\right ) \log (x) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

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

________________________________________________________________________________________

Maple [A]
time = 0.04, size = 21, normalized size = 1.62

method result size
risch \(x \left ({\mathrm e}^{x} x +{\mathrm e}^{x}-5\right ) \ln \left (x \right )\) \(13\)
default \(x^{2} {\mathrm e}^{x} \ln \left (x \right )+x \,{\mathrm e}^{x} \ln \left (x \right )-5 x \ln \left (x \right )\) \(21\)
norman \(x^{2} {\mathrm e}^{x} \ln \left (x \right )+x \,{\mathrm e}^{x} \ln \left (x \right )-5 x \ln \left (x \right )\) \(21\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 29 vs. \(2 (12) = 24\).
time = 0.29, size = 29, normalized size = 2.23 \begin {gather*} {\left (x - 1\right )} e^{x} - x e^{x} + {\left ({\left (x^{2} + x\right )} e^{x} - 5 \, x\right )} \log \left (x\right ) + e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Fricas [A]
time = 0.36, size = 15, normalized size = 1.15 \begin {gather*} {\left ({\left (x^{2} + x\right )} e^{x} - 5 \, x\right )} \log \left (x\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

((x^2 + x)*e^x - 5*x)*log(x)

________________________________________________________________________________________

Sympy [A]
time = 0.09, size = 20, normalized size = 1.54 \begin {gather*} - 5 x \log {\left (x \right )} + \left (x^{2} \log {\left (x \right )} + x \log {\left (x \right )}\right ) e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x**2+3*x+1)*exp(x)-5)*ln(x)+(1+x)*exp(x)-5,x)

[Out]

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

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 31 vs. \(2 (12) = 24\).
time = 0.42, size = 31, normalized size = 2.38 \begin {gather*} -{\left (x - 1\right )} e^{x} + x e^{x} + {\left ({\left (x^{2} + x\right )} e^{x} - 5 \, x\right )} \log \left (x\right ) - e^{x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________

Mupad [B]
time = 3.31, size = 12, normalized size = 0.92 \begin {gather*} x\,\ln \left (x\right )\,\left ({\mathrm {e}}^x+x\,{\mathrm {e}}^x-5\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

x*log(x)*(exp(x) + x*exp(x) - 5)

________________________________________________________________________________________