Optimal. Leaf size=30 \[ -\frac {3}{5} e^{-x-\frac {x^2}{2}}-3 e \left (1+\frac {3 \log (3)}{x}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.68, antiderivative size = 26, normalized size of antiderivative = 0.87, number of steps
used = 15, number of rules used = 10, integrand size = 52, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.192, Rules used = {12, 6873,
6874, 2267, 2266, 2236, 2276, 2272, 6820, 30} \begin {gather*} -\frac {3}{5} e^{-\frac {x^2}{2}-x}-\frac {9 e \log (3)}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 30
Rule 2236
Rule 2266
Rule 2267
Rule 2272
Rule 2276
Rule 6820
Rule 6873
Rule 6874
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\frac {1}{5} \int \frac {e^{\frac {1}{2} \left (-2 x-x^2\right )} \left (3 x^2+3 x^3+45 e^{1+\frac {1}{2} \left (2 x+x^2\right )} \log (3)\right )}{x^2} \, dx\\ &=\frac {1}{5} \int \frac {3 e^{\frac {1}{2} (-2-x) x} \left (x^2+x^3+15 e^{1+x+\frac {x^2}{2}} \log (3)\right )}{x^2} \, dx\\ &=\frac {3}{5} \int \frac {e^{\frac {1}{2} (-2-x) x} \left (x^2+x^3+15 e^{1+x+\frac {x^2}{2}} \log (3)\right )}{x^2} \, dx\\ &=\frac {3}{5} \int \left (e^{\frac {1}{2} (-2-x) x}+e^{\frac {1}{2} (-2-x) x} x+\frac {15 e^{1+x+\frac {1}{2} (-2-x) x+\frac {x^2}{2}} \log (3)}{x^2}\right ) \, dx\\ &=\frac {3}{5} \int e^{\frac {1}{2} (-2-x) x} \, dx+\frac {3}{5} \int e^{\frac {1}{2} (-2-x) x} x \, dx+(9 \log (3)) \int \frac {e^{1+x+\frac {1}{2} (-2-x) x+\frac {x^2}{2}}}{x^2} \, dx\\ &=\frac {3}{5} \int e^{-x-\frac {x^2}{2}} \, dx+\frac {3}{5} \int e^{-x-\frac {x^2}{2}} x \, dx+(9 \log (3)) \int \frac {e}{x^2} \, dx\\ &=-\frac {3}{5} e^{-x-\frac {x^2}{2}}-\frac {3}{5} \int e^{-x-\frac {x^2}{2}} \, dx+\frac {1}{5} \left (3 \sqrt {e}\right ) \int e^{-\frac {1}{2} (-1-x)^2} \, dx+(9 e \log (3)) \int \frac {1}{x^2} \, dx\\ &=-\frac {3}{5} e^{-x-\frac {x^2}{2}}+\frac {3}{5} \sqrt {\frac {e \pi }{2}} \text {erf}\left (\frac {1+x}{\sqrt {2}}\right )-\frac {9 e \log (3)}{x}-\frac {1}{5} \left (3 \sqrt {e}\right ) \int e^{-\frac {1}{2} (-1-x)^2} \, dx\\ &=-\frac {3}{5} e^{-x-\frac {x^2}{2}}-\frac {9 e \log (3)}{x}\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A]
time = 0.11, size = 25, normalized size = 0.83 \begin {gather*} \frac {3}{5} \left (-e^{-\frac {1}{2} x (2+x)}-\frac {15 e \log (3)}{x}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.06, size = 23, normalized size = 0.77
method | result | size |
risch | \(-\frac {9 \,{\mathrm e} \ln \left (3\right )}{x}-\frac {3 \,{\mathrm e}^{-\frac {x \left (2+x \right )}{2}}}{5}\) | \(20\) |
default | \(-\frac {3 \,{\mathrm e}^{-\frac {1}{2} x^{2}-x}}{5}-\frac {9 \,{\mathrm e} \ln \left (3\right )}{x}\) | \(23\) |
norman | \(\frac {\left (-\frac {3 x}{5}-9 \,{\mathrm e} \ln \left (3\right ) {\mathrm e}^{\frac {1}{2} x^{2}+x}\right ) {\mathrm e}^{-\frac {1}{2} x^{2}-x}}{x}\) | \(33\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [C] Result contains higher order function than in optimal. Order 4 vs. order
3.
time = 0.51, size = 83, normalized size = 2.77 \begin {gather*} \frac {3}{10} \, \sqrt {2} \sqrt {\pi } \operatorname {erf}\left (\frac {1}{2} \, \sqrt {2} x + \frac {1}{2} \, \sqrt {2}\right ) e^{\frac {1}{2}} + \frac {3}{10} i \, \sqrt {2} {\left (\frac {i \, \sqrt {\pi } {\left (x + 1\right )} {\left (\operatorname {erf}\left (\sqrt {\frac {1}{2}} \sqrt {{\left (x + 1\right )}^{2}}\right ) - 1\right )}}{\sqrt {{\left (x + 1\right )}^{2}}} + i \, \sqrt {2} e^{\left (-\frac {1}{2} \, {\left (x + 1\right )}^{2}\right )}\right )} e^{\frac {1}{2}} - \frac {9 \, e \log \left (3\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.39, size = 34, normalized size = 1.13 \begin {gather*} -\frac {3 \, {\left (x e + 15 \, e^{\left (\frac {1}{2} \, x^{2} + x + 2\right )} \log \left (3\right )\right )} e^{\left (-\frac {1}{2} \, x^{2} - x - 1\right )}}{5 \, x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.04, size = 24, normalized size = 0.80 \begin {gather*} - \frac {3 e^{- \frac {x^{2}}{2} - x}}{5} - \frac {9 e \log {\left (3 \right )}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.42, size = 24, normalized size = 0.80 \begin {gather*} -\frac {3 \, {\left (x e^{\left (-\frac {1}{2} \, x^{2} - x\right )} + 15 \, e \log \left (3\right )\right )}}{5 \, x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.20, size = 22, normalized size = 0.73 \begin {gather*} -\frac {3\,{\mathrm {e}}^{-\frac {x^2}{2}-x}}{5}-\frac {9\,\mathrm {e}\,\ln \left (3\right )}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________