\(\int e^{-x} (-3 x^2+x^3-e^x \log (4)) \, dx\) [8684]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 22, antiderivative size = 25 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=2-\log \left (\frac {5}{4}\right )+x \left (-e^{-x} x^2-\log (4)\right ) \]

[Out]

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

Rubi [A] (verified)

Time = 0.08 (sec) , antiderivative size = 16, normalized size of antiderivative = 0.64, number of steps used = 9, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.136, Rules used = {6874, 2207, 2225} \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=-e^{-x} x^3-x \log (4) \]

[In]

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

[Out]

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

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 6874

Int[u_, x_Symbol] :> With[{v = ExpandIntegrand[u, x]}, Int[v, x] /; SumQ[v]]

Rubi steps \begin{align*} \text {integral}& = \int \left (-3 e^{-x} x^2+e^{-x} x^3-\log (4)\right ) \, dx \\ & = -x \log (4)-3 \int e^{-x} x^2 \, dx+\int e^{-x} x^3 \, dx \\ & = 3 e^{-x} x^2-e^{-x} x^3-x \log (4)+3 \int e^{-x} x^2 \, dx-6 \int e^{-x} x \, dx \\ & = 6 e^{-x} x-e^{-x} x^3-x \log (4)-6 \int e^{-x} \, dx+6 \int e^{-x} x \, dx \\ & = 6 e^{-x}-e^{-x} x^3-x \log (4)+6 \int e^{-x} \, dx \\ & = -e^{-x} x^3-x \log (4) \\ \end{align*}

Mathematica [A] (verified)

Time = 0.04 (sec) , antiderivative size = 16, normalized size of antiderivative = 0.64 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=-e^{-x} x^3-x \log (4) \]

[In]

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

[Out]

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

Maple [A] (verified)

Time = 0.09 (sec) , antiderivative size = 16, normalized size of antiderivative = 0.64

method result size
default \(-x^{3} {\mathrm e}^{-x}-2 x \ln \left (2\right )\) \(16\)
risch \(-x^{3} {\mathrm e}^{-x}-2 x \ln \left (2\right )\) \(16\)
parts \(-x^{3} {\mathrm e}^{-x}-2 x \ln \left (2\right )\) \(16\)
parallelrisch \(-\left (2 x \ln \left (2\right ) {\mathrm e}^{x}+x^{3}\right ) {\mathrm e}^{-x}\) \(18\)
norman \(\left (-x^{3}-2 x \ln \left (2\right ) {\mathrm e}^{x}\right ) {\mathrm e}^{-x}\) \(19\)

[In]

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

[Out]

-x^3/exp(x)-2*x*ln(2)

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.68 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=-{\left (x^{3} + 2 \, x e^{x} \log \left (2\right )\right )} e^{\left (-x\right )} \]

[In]

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

[Out]

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

Sympy [A] (verification not implemented)

Time = 0.04 (sec) , antiderivative size = 14, normalized size of antiderivative = 0.56 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=- x^{3} e^{- x} - 2 x \log {\left (2 \right )} \]

[In]

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

[Out]

-x**3*exp(-x) - 2*x*log(2)

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 39, normalized size of antiderivative = 1.56 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=-{\left (x^{3} + 3 \, x^{2} + 6 \, x + 6\right )} e^{\left (-x\right )} + 3 \, {\left (x^{2} + 2 \, x + 2\right )} e^{\left (-x\right )} - 2 \, x \log \left (2\right ) \]

[In]

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

[Out]

-(x^3 + 3*x^2 + 6*x + 6)*e^(-x) + 3*(x^2 + 2*x + 2)*e^(-x) - 2*x*log(2)

Giac [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 15, normalized size of antiderivative = 0.60 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=-x^{3} e^{\left (-x\right )} - 2 \, x \log \left (2\right ) \]

[In]

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

[Out]

-x^3*e^(-x) - 2*x*log(2)

Mupad [B] (verification not implemented)

Time = 13.81 (sec) , antiderivative size = 15, normalized size of antiderivative = 0.60 \[ \int e^{-x} \left (-3 x^2+x^3-e^x \log (4)\right ) \, dx=-2\,x\,\ln \left (2\right )-x^3\,{\mathrm {e}}^{-x} \]

[In]

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

[Out]

- 2*x*log(2) - x^3*exp(-x)