3.59.77 \(\int \frac {e^{-x} (-12 x^2+7 x^3-x^4+x^5+(-20 x^4+9 x^5-x^6) \log (-4+x))}{-4+x} \, dx\)

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

________________________________________________________________________________________

Rubi [A]  time = 0.83, antiderivative size = 23, normalized size of antiderivative = 1.21, number of steps used = 39, number of rules used = 7, integrand size = 51, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.137, Rules used = {6742, 2199, 2194, 2178, 2176, 2196, 2554} \begin {gather*} e^{-x} x^5 \log (x-4)+e^{-x} x^3 \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(-12*x^2 + 7*x^3 - x^4 + x^5 + (-20*x^4 + 9*x^5 - x^6)*Log[-4 + x])/(E^x*(-4 + x)),x]

[Out]

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

Rule 2176

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] &&  !$UseGamma === True

Rule 2178

Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[(F^(g*(e - (c*f)/d))*ExpIntegral
Ei[(f*g*(c + d*x)*Log[F])/d])/d, x] /; FreeQ[{F, c, d, e, f, g}, x] &&  !$UseGamma === True

Rule 2194

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 2196

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] &&  !$UseGamma === True

Rule 2199

Int[(F_)^((c_.)*(v_))*(u_)^(m_.)*(w_), x_Symbol] :> Int[ExpandIntegrand[F^(c*ExpandToSum[v, x]), w*NormalizePo
werOfLinear[u, x]^m, x], x] /; FreeQ[{F, c}, x] && PolynomialQ[w, x] && LinearQ[v, x] && PowerOfLinearQ[u, x]
&& IntegerQ[m] &&  !$UseGamma === True

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} &=\int \left (\frac {e^{-x} x^2 \left (-12+7 x-x^2+x^3\right )}{-4+x}-e^{-x} (-5+x) x^4 \log (-4+x)\right ) \, dx\\ &=\int \frac {e^{-x} x^2 \left (-12+7 x-x^2+x^3\right )}{-4+x} \, dx-\int e^{-x} (-5+x) x^4 \log (-4+x) \, dx\\ &=e^{-x} x^5 \log (-4+x)-\int \frac {e^{-x} x^5}{-4+x} \, dx+\int \left (256 e^{-x}+\frac {1024 e^{-x}}{-4+x}+64 e^{-x} x+19 e^{-x} x^2+3 e^{-x} x^3+e^{-x} x^4\right ) \, dx\\ &=e^{-x} x^5 \log (-4+x)+3 \int e^{-x} x^3 \, dx+19 \int e^{-x} x^2 \, dx+64 \int e^{-x} x \, dx+256 \int e^{-x} \, dx+1024 \int \frac {e^{-x}}{-4+x} \, dx+\int e^{-x} x^4 \, dx-\int \left (256 e^{-x}+\frac {1024 e^{-x}}{-4+x}+64 e^{-x} x+16 e^{-x} x^2+4 e^{-x} x^3+e^{-x} x^4\right ) \, dx\\ &=-256 e^{-x}-64 e^{-x} x-19 e^{-x} x^2-3 e^{-x} x^3-e^{-x} x^4+\frac {1024 \text {Ei}(4-x)}{e^4}+e^{-x} x^5 \log (-4+x)+9 \int e^{-x} x^2 \, dx-16 \int e^{-x} x^2 \, dx+38 \int e^{-x} x \, dx+64 \int e^{-x} \, dx-64 \int e^{-x} x \, dx-256 \int e^{-x} \, dx-1024 \int \frac {e^{-x}}{-4+x} \, dx-\int e^{-x} x^4 \, dx\\ &=-64 e^{-x}-38 e^{-x} x-12 e^{-x} x^2-3 e^{-x} x^3+e^{-x} x^5 \log (-4+x)-4 \int e^{-x} x^3 \, dx+18 \int e^{-x} x \, dx-32 \int e^{-x} x \, dx+38 \int e^{-x} \, dx-64 \int e^{-x} \, dx\\ &=-38 e^{-x}-24 e^{-x} x-12 e^{-x} x^2+e^{-x} x^3+e^{-x} x^5 \log (-4+x)-12 \int e^{-x} x^2 \, dx+18 \int e^{-x} \, dx-32 \int e^{-x} \, dx\\ &=-24 e^{-x}-24 e^{-x} x+e^{-x} x^3+e^{-x} x^5 \log (-4+x)-24 \int e^{-x} x \, dx\\ &=-24 e^{-x}+e^{-x} x^3+e^{-x} x^5 \log (-4+x)-24 \int e^{-x} \, dx\\ &=e^{-x} x^3+e^{-x} x^5 \log (-4+x)\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.79, size = 19, normalized size = 1.00 \begin {gather*} e^{-x} x^3 \left (1+x^2 \log (-4+x)\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-12*x^2 + 7*x^3 - x^4 + x^5 + (-20*x^4 + 9*x^5 - x^6)*Log[-4 + x])/(E^x*(-4 + x)),x]

[Out]

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

________________________________________________________________________________________

fricas [A]  time = 0.62, size = 21, normalized size = 1.11 \begin {gather*} x^{5} e^{\left (-x\right )} \log \left (x - 4\right ) + x^{3} e^{\left (-x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x^6+9*x^5-20*x^4)*log(x-4)+x^5-x^4+7*x^3-12*x^2)/(x-4)/exp(x),x, algorithm="fricas")

[Out]

x^5*e^(-x)*log(x - 4) + x^3*e^(-x)

________________________________________________________________________________________

giac [A]  time = 0.14, size = 21, normalized size = 1.11 \begin {gather*} x^{5} e^{\left (-x\right )} \log \left (x - 4\right ) + x^{3} e^{\left (-x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x^6+9*x^5-20*x^4)*log(x-4)+x^5-x^4+7*x^3-12*x^2)/(x-4)/exp(x),x, algorithm="giac")

[Out]

x^5*e^(-x)*log(x - 4) + x^3*e^(-x)

________________________________________________________________________________________

maple [A]  time = 0.31, size = 22, normalized size = 1.16




method result size



risch \(x^{5} {\mathrm e}^{-x} \ln \left (x -4\right )+x^{3} {\mathrm e}^{-x}\) \(22\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((-x^6+9*x^5-20*x^4)*ln(x-4)+x^5-x^4+7*x^3-12*x^2)/(x-4)/exp(x),x,method=_RETURNVERBOSE)

[Out]

x^5*exp(-x)*ln(x-4)+x^3*exp(-x)

________________________________________________________________________________________

maxima [A]  time = 0.41, size = 21, normalized size = 1.11 \begin {gather*} x^{5} e^{\left (-x\right )} \log \left (x - 4\right ) + x^{3} e^{\left (-x\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x^6+9*x^5-20*x^4)*log(x-4)+x^5-x^4+7*x^3-12*x^2)/(x-4)/exp(x),x, algorithm="maxima")

[Out]

x^5*e^(-x)*log(x - 4) + x^3*e^(-x)

________________________________________________________________________________________

mupad [B]  time = 4.41, size = 18, normalized size = 0.95 \begin {gather*} x^3\,{\mathrm {e}}^{-x}\,\left (x^2\,\ln \left (x-4\right )+1\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(exp(-x)*(log(x - 4)*(20*x^4 - 9*x^5 + x^6) + 12*x^2 - 7*x^3 + x^4 - x^5))/(x - 4),x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.35, size = 14, normalized size = 0.74 \begin {gather*} \left (x^{5} \log {\left (x - 4 \right )} + x^{3}\right ) e^{- x} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-x**6+9*x**5-20*x**4)*ln(x-4)+x**5-x**4+7*x**3-12*x**2)/(x-4)/exp(x),x)

[Out]

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

________________________________________________________________________________________