Optimal. Leaf size=23 \[ (-3+x)^2 \left (3+\frac {e^{-2 x} (x+\log (3 e))}{x^3}\right ) \]
________________________________________________________________________________________
Rubi [C] time = 1.86, antiderivative size = 145, normalized size of antiderivative = 6.30, number of steps used = 16, number of rules used = 6, integrand size = 65, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.092, Rules used = {6741, 6742, 2199, 2194, 2177, 2178} \begin {gather*} 2 (1-\log (177147)) \text {Ei}(-2 x)-2 (24+\log (729)) \text {Ei}(-2 x)+(10-\log (9)) \text {Ei}(-2 x)+36 (1+\log (3)) \text {Ei}(-2 x)+\frac {9 e^{-2 x} (1+\log (3))}{x^3}+\frac {e^{-2 x} (24+\log (729))}{2 x^2}-\frac {9 e^{-2 x} (1+\log (3))}{x^2}+3 (3-x)^2+e^{-2 x}+\frac {e^{-2 x} (1-\log (177147))}{x}-\frac {e^{-2 x} (24+\log (729))}{x}+\frac {18 e^{-2 x} (1+\log (3))}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2177
Rule 2178
Rule 2194
Rule 2199
Rule 6741
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {e^{-2 x} (3-x) \left (2 x^3-6 e^{2 x} x^4-4 x^2 \left (1-\frac {\log (3)}{2}\right )-11 x \left (1+\frac {5 \log (3)}{11}\right )-9 (1+\log (3))\right )}{x^4} \, dx\\ &=\int \left (6 (-3+x)+\frac {e^{-2 x} (3-x) \left (2 x^3-9 (1+\log (3))-x^2 (4-\log (9))-x (11+\log (243))\right )}{x^4}\right ) \, dx\\ &=3 (3-x)^2+\int \frac {e^{-2 x} (3-x) \left (2 x^3-9 (1+\log (3))-x^2 (4-\log (9))-x (11+\log (243))\right )}{x^4} \, dx\\ &=3 (3-x)^2+\int \left (-2 e^{-2 x}-\frac {27 e^{-2 x} (1+\log (3))}{x^4}+\frac {e^{-2 x} (10-\log (9))}{x}+\frac {e^{-2 x} (-24-\log (729))}{x^3}+\frac {e^{-2 x} (-1+\log (177147))}{x^2}\right ) \, dx\\ &=3 (3-x)^2-2 \int e^{-2 x} \, dx-(27 (1+\log (3))) \int \frac {e^{-2 x}}{x^4} \, dx+(10-\log (9)) \int \frac {e^{-2 x}}{x} \, dx+(-24-\log (729)) \int \frac {e^{-2 x}}{x^3} \, dx+(-1+\log (177147)) \int \frac {e^{-2 x}}{x^2} \, dx\\ &=e^{-2 x}+3 (3-x)^2+\frac {9 e^{-2 x} (1+\log (3))}{x^3}+\text {Ei}(-2 x) (10-\log (9))+\frac {e^{-2 x} (24+\log (729))}{2 x^2}+\frac {e^{-2 x} (1-\log (177147))}{x}+(18 (1+\log (3))) \int \frac {e^{-2 x}}{x^3} \, dx+(24+\log (729)) \int \frac {e^{-2 x}}{x^2} \, dx+(2 (1-\log (177147))) \int \frac {e^{-2 x}}{x} \, dx\\ &=e^{-2 x}+3 (3-x)^2+\frac {9 e^{-2 x} (1+\log (3))}{x^3}-\frac {9 e^{-2 x} (1+\log (3))}{x^2}+\text {Ei}(-2 x) (10-\log (9))+\frac {e^{-2 x} (24+\log (729))}{2 x^2}-\frac {e^{-2 x} (24+\log (729))}{x}+\frac {e^{-2 x} (1-\log (177147))}{x}+2 \text {Ei}(-2 x) (1-\log (177147))-(18 (1+\log (3))) \int \frac {e^{-2 x}}{x^2} \, dx-(2 (24+\log (729))) \int \frac {e^{-2 x}}{x} \, dx\\ &=e^{-2 x}+3 (3-x)^2+\frac {9 e^{-2 x} (1+\log (3))}{x^3}-\frac {9 e^{-2 x} (1+\log (3))}{x^2}+\frac {18 e^{-2 x} (1+\log (3))}{x}+\text {Ei}(-2 x) (10-\log (9))+\frac {e^{-2 x} (24+\log (729))}{2 x^2}-\frac {e^{-2 x} (24+\log (729))}{x}-2 \text {Ei}(-2 x) (24+\log (729))+\frac {e^{-2 x} (1-\log (177147))}{x}+2 \text {Ei}(-2 x) (1-\log (177147))+(36 (1+\log (3))) \int \frac {e^{-2 x}}{x} \, dx\\ &=e^{-2 x}+3 (3-x)^2+\frac {9 e^{-2 x} (1+\log (3))}{x^3}-\frac {9 e^{-2 x} (1+\log (3))}{x^2}+\frac {18 e^{-2 x} (1+\log (3))}{x}+36 \text {Ei}(-2 x) (1+\log (3))+\text {Ei}(-2 x) (10-\log (9))+\frac {e^{-2 x} (24+\log (729))}{2 x^2}-\frac {e^{-2 x} (24+\log (729))}{x}-2 \text {Ei}(-2 x) (24+\log (729))+\frac {e^{-2 x} (1-\log (177147))}{x}+2 \text {Ei}(-2 x) (1-\log (177147))\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [B] time = 0.92, size = 60, normalized size = 2.61 \begin {gather*} \frac {e^{-2 x} \left (2 x^3-36 e^{2 x} x^4+6 e^{2 x} x^5+2 x^2 (-5+\log (3))-3 x (-2+\log (81))+2 (9+\log (19683))\right )}{2 x^3} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.66, size = 47, normalized size = 2.04 \begin {gather*} \frac {{\left (x^{3} - 5 \, x^{2} + 3 \, {\left (x^{5} - 6 \, x^{4}\right )} e^{\left (2 \, x\right )} + {\left (x^{2} - 6 \, x + 9\right )} \log \relax (3) + 3 \, x + 9\right )} e^{\left (-2 \, x\right )}}{x^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.34, size = 72, normalized size = 3.13 \begin {gather*} \frac {3 \, x^{5} - 18 \, x^{4} + x^{3} e^{\left (-2 \, x\right )} + x^{2} e^{\left (-2 \, x\right )} \log \relax (3) - 5 \, x^{2} e^{\left (-2 \, x\right )} - 6 \, x e^{\left (-2 \, x\right )} \log \relax (3) + 3 \, x e^{\left (-2 \, x\right )} + 9 \, e^{\left (-2 \, x\right )} \log \relax (3) + 9 \, e^{\left (-2 \, x\right )}}{x^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.08, size = 46, normalized size = 2.00
method | result | size |
risch | \(3 x^{2}-18 x +\frac {\left (x^{2} \ln \relax (3)+x^{3}-6 x \ln \relax (3)-5 x^{2}+9 \ln \relax (3)+3 x +9\right ) {\mathrm e}^{-2 x}}{x^{3}}\) | \(46\) |
norman | \(\frac {\left (x^{3}+\left (3-6 \ln \relax (3)\right ) x +\left (\ln \relax (3)-5\right ) x^{2}+3 x^{5} {\mathrm e}^{2 x}-18 \,{\mathrm e}^{2 x} x^{4}+9 \ln \relax (3)+9\right ) {\mathrm e}^{-2 x}}{x^{3}}\) | \(52\) |
default | \(3 x^{2}-18 x +{\mathrm e}^{-2 x}+\frac {9 \,{\mathrm e}^{-2 x}}{x^{3}}+\frac {3 \,{\mathrm e}^{-2 x}}{x^{2}}-\frac {5 \,{\mathrm e}^{-2 x}}{x}+\frac {9 \,{\mathrm e}^{-2 x} \ln \relax (3)}{x^{3}}-\frac {6 \,{\mathrm e}^{-2 x} \ln \relax (3)}{x^{2}}+\frac {{\mathrm e}^{-2 x} \ln \relax (3)}{x}\) | \(73\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [C] time = 0.50, size = 80, normalized size = 3.48 \begin {gather*} 3 \, x^{2} - 2 \, {\rm Ei}\left (-2 \, x\right ) \log \left (3 \, e\right ) - 22 \, \Gamma \left (-1, 2 \, x\right ) \log \left (3 \, e\right ) + 24 \, \Gamma \left (-2, 2 \, x\right ) \log \left (3 \, e\right ) + 216 \, \Gamma \left (-3, 2 \, x\right ) \log \left (3 \, e\right ) - 18 \, x + 12 \, {\rm Ei}\left (-2 \, x\right ) + e^{\left (-2 \, x\right )} + 24 \, \Gamma \left (-1, 2 \, x\right ) + 72 \, \Gamma \left (-2, 2 \, x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.11, size = 52, normalized size = 2.26 \begin {gather*} \frac {{\mathrm {e}}^{-2\,x}\,\left (9\,\ln \relax (3)-x\,\left (6\,\ln \relax (3)-3\right )+x^2\,\left (\ln \relax (3)-5\right )-18\,x^4\,{\mathrm {e}}^{2\,x}+3\,x^5\,{\mathrm {e}}^{2\,x}+x^3+9\right )}{x^3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [B] time = 0.18, size = 48, normalized size = 2.09 \begin {gather*} 3 x^{2} - 18 x + \frac {\left (x^{3} - 5 x^{2} + x^{2} \log {\relax (3 )} - 6 x \log {\relax (3 )} + 3 x + 9 + 9 \log {\relax (3 )}\right ) e^{- 2 x}}{x^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________