Optimal. Leaf size=22 \[ e^{-x} \left (-2+\frac {5 e^2}{2}+x\right ) (-x+\log (x)) \]
________________________________________________________________________________________
Rubi [B] time = 0.56, antiderivative size = 104, normalized size of antiderivative = 4.73, number of steps used = 16, number of rules used = 6, integrand size = 57, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {6742, 2199, 2194, 2178, 2176, 2554} \begin {gather*} -e^{-x} x^2-2 e^{-x} x+\frac {1}{2} \left (8-5 e^2\right ) e^{-x} x-e^{-x}+\frac {1}{2} \left (8-5 e^2\right ) e^{-x}-\frac {1}{2} \left (6-5 e^2\right ) e^{-x}+e^{-x} \log (x)-\frac {1}{2} e^{-x} \left (-2 x-5 e^2+6\right ) \log (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2176
Rule 2178
Rule 2194
Rule 2199
Rule 2554
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \left (\frac {e^{-x} \left (-4+5 e^2+\left (6-5 e^2\right ) x-\left (8-5 e^2\right ) x^2+2 x^3\right )}{2 x}-\frac {1}{2} e^{-x} \left (-6+5 e^2+2 x\right ) \log (x)\right ) \, dx\\ &=\frac {1}{2} \int \frac {e^{-x} \left (-4+5 e^2+\left (6-5 e^2\right ) x-\left (8-5 e^2\right ) x^2+2 x^3\right )}{x} \, dx-\frac {1}{2} \int e^{-x} \left (-6+5 e^2+2 x\right ) \log (x) \, dx\\ &=e^{-x} \log (x)-\frac {1}{2} e^{-x} \left (6-5 e^2-2 x\right ) \log (x)+\frac {1}{2} \int \frac {e^{-x} \left (4-5 e^2-2 x\right )}{x} \, dx+\frac {1}{2} \int \left (e^{-x} \left (6-5 e^2\right )+\frac {e^{-x} \left (-4+5 e^2\right )}{x}-e^{-x} \left (8-5 e^2\right ) x+2 e^{-x} x^2\right ) \, dx\\ &=e^{-x} \log (x)-\frac {1}{2} e^{-x} \left (6-5 e^2-2 x\right ) \log (x)+\frac {1}{2} \int \left (-2 e^{-x}+\frac {e^{-x} \left (4-5 e^2\right )}{x}\right ) \, dx+\frac {1}{2} \left (6-5 e^2\right ) \int e^{-x} \, dx+\frac {1}{2} \left (-8+5 e^2\right ) \int e^{-x} x \, dx+\frac {1}{2} \left (-4+5 e^2\right ) \int \frac {e^{-x}}{x} \, dx+\int e^{-x} x^2 \, dx\\ &=-\frac {1}{2} e^{-x} \left (6-5 e^2\right )+\frac {1}{2} e^{-x} \left (8-5 e^2\right ) x-e^{-x} x^2-\frac {1}{2} \left (4-5 e^2\right ) \text {Ei}(-x)+e^{-x} \log (x)-\frac {1}{2} e^{-x} \left (6-5 e^2-2 x\right ) \log (x)+2 \int e^{-x} x \, dx+\frac {1}{2} \left (4-5 e^2\right ) \int \frac {e^{-x}}{x} \, dx+\frac {1}{2} \left (-8+5 e^2\right ) \int e^{-x} \, dx-\int e^{-x} \, dx\\ &=e^{-x}-\frac {1}{2} e^{-x} \left (6-5 e^2\right )+\frac {1}{2} e^{-x} \left (8-5 e^2\right )-2 e^{-x} x+\frac {1}{2} e^{-x} \left (8-5 e^2\right ) x-e^{-x} x^2+e^{-x} \log (x)-\frac {1}{2} e^{-x} \left (6-5 e^2-2 x\right ) \log (x)+2 \int e^{-x} \, dx\\ &=-e^{-x}-\frac {1}{2} e^{-x} \left (6-5 e^2\right )+\frac {1}{2} e^{-x} \left (8-5 e^2\right )-2 e^{-x} x+\frac {1}{2} e^{-x} \left (8-5 e^2\right ) x-e^{-x} x^2+e^{-x} \log (x)-\frac {1}{2} e^{-x} \left (6-5 e^2-2 x\right ) \log (x)\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.14, size = 25, normalized size = 1.14 \begin {gather*} -\frac {1}{2} e^{-x} \left (-4+5 e^2+2 x\right ) (x-\log (x)) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.83, size = 45, normalized size = 2.05 \begin {gather*} -{\left (x^{2} - 2 \, x\right )} e^{\left (-x\right )} - x e^{\left (-x + \log \left (\frac {5}{2}\right ) + 2\right )} + {\left ({\left (x - 2\right )} e^{\left (-x\right )} + e^{\left (-x + \log \left (\frac {5}{2}\right ) + 2\right )}\right )} \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 1.00, size = 52, normalized size = 2.36 \begin {gather*} -x^{2} e^{\left (-x\right )} + x e^{\left (-x\right )} \log \relax (x) + 2 \, x e^{\left (-x\right )} - \frac {5}{2} \, x e^{\left (-x + 2\right )} - 2 \, e^{\left (-x\right )} \log \relax (x) + \frac {5}{2} \, e^{\left (-x + 2\right )} \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.07, size = 33, normalized size = 1.50
method | result | size |
norman | \(\left (x \ln \relax (x )+\left (-\frac {5 \,{\mathrm e}^{2}}{2}+2\right ) x +\left (\frac {5 \,{\mathrm e}^{2}}{2}-2\right ) \ln \relax (x )-x^{2}\right ) {\mathrm e}^{-x}\) | \(33\) |
risch | \(\frac {\left (5 \,{\mathrm e}^{2}-4+2 x \right ) {\mathrm e}^{-x} \ln \relax (x )}{2}-\frac {x \left (5 \,{\mathrm e}^{2}-4+2 x \right ) {\mathrm e}^{-x}}{2}\) | \(35\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} {\left (x + 1\right )} e^{\left (-x\right )} \log \relax (x) - {\left (x^{2} + 2 \, x + 2\right )} e^{\left (-x\right )} - \frac {5}{2} \, {\left (x e^{2} + e^{2}\right )} e^{\left (-x\right )} + 4 \, {\left (x + 1\right )} e^{\left (-x\right )} - 3 \, e^{\left (-x\right )} \log \relax (x) + \frac {5}{2} \, e^{\left (-x + 2\right )} \log \relax (x) + {\rm Ei}\left (-x\right ) - 3 \, e^{\left (-x\right )} + \frac {5}{2} \, e^{\left (-x + 2\right )} - \int \frac {{\left (x + 1\right )} e^{\left (-x\right )}}{x}\,{d x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.55, size = 21, normalized size = 0.95 \begin {gather*} -\frac {{\mathrm {e}}^{-x}\,\left (x-\ln \relax (x)\right )\,\left (2\,x+5\,{\mathrm {e}}^2-4\right )}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [B] time = 0.45, size = 39, normalized size = 1.77 \begin {gather*} \frac {\left (- 2 x^{2} + 2 x \log {\relax (x )} - 5 x e^{2} + 4 x - 4 \log {\relax (x )} + 5 e^{2} \log {\relax (x )}\right ) e^{- x}}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________