Optimal. Leaf size=27 \[ x \left (4+\frac {e^{-2 x} \left (e^2+x\right )^2}{x^2}\right )-\frac {1}{\log (4)} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.43, antiderivative size = 47, normalized size of antiderivative = 1.74, number of steps
used = 11, number of rules used = 7, integrand size = 45, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.156, Rules used = {6, 6874, 2230,
2225, 2208, 2209, 2207} \begin {gather*} e^{-2 x} x+4 x+\frac {e^{-2 x}}{2}-\frac {1}{2} \left (1-4 e^2\right ) e^{-2 x}+\frac {e^{4-2 x}}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 6
Rule 2207
Rule 2208
Rule 2209
Rule 2225
Rule 2230
Rule 6874
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {e^{-2 x} \left (e^4 (-1-2 x)+4 e^{2 x} x^2+\left (1-4 e^2\right ) x^2-2 x^3\right )}{x^2} \, dx\\ &=\int \left (4+\frac {e^{-2 x} \left (-e^4-2 e^4 x+\left (1-4 e^2\right ) x^2-2 x^3\right )}{x^2}\right ) \, dx\\ &=4 x+\int \frac {e^{-2 x} \left (-e^4-2 e^4 x+\left (1-4 e^2\right ) x^2-2 x^3\right )}{x^2} \, dx\\ &=4 x+\int \left (e^{-2 x} \left (1-4 e^2\right )-\frac {e^{4-2 x}}{x^2}-\frac {2 e^{4-2 x}}{x}-2 e^{-2 x} x\right ) \, dx\\ &=4 x-2 \int \frac {e^{4-2 x}}{x} \, dx-2 \int e^{-2 x} x \, dx+\left (1-4 e^2\right ) \int e^{-2 x} \, dx-\int \frac {e^{4-2 x}}{x^2} \, dx\\ &=-\frac {1}{2} e^{-2 x} \left (1-4 e^2\right )+\frac {e^{4-2 x}}{x}+4 x+e^{-2 x} x-2 e^4 \text {Ei}(-2 x)+2 \int \frac {e^{4-2 x}}{x} \, dx-\int e^{-2 x} \, dx\\ &=\frac {e^{-2 x}}{2}-\frac {1}{2} e^{-2 x} \left (1-4 e^2\right )+\frac {e^{4-2 x}}{x}+4 x+e^{-2 x} x\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A]
time = 0.22, size = 31, normalized size = 1.15 \begin {gather*} 2 e^{2-2 x}+\frac {e^{4-2 x}}{x}+4 x+e^{-2 x} x \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 4 vs. order
3.
time = 0.57, size = 49, normalized size = 1.81
method | result | size |
risch | \(4 x +\frac {\left ({\mathrm e}^{4}+2 \,{\mathrm e}^{2} x +x^{2}\right ) {\mathrm e}^{-2 x}}{x}\) | \(24\) |
norman | \(\frac {\left (x^{3}+x \,{\mathrm e}^{4}+4 \,{\mathrm e}^{2 x} x^{3}+2 x^{2} {\mathrm e}^{2}\right ) {\mathrm e}^{-2 x}}{x^{2}}\) | \(36\) |
default | \(4 x +x \,{\mathrm e}^{-2 x}+2 \,{\mathrm e}^{2} {\mathrm e}^{-2 x}+2 \,{\mathrm e}^{4} \left (\frac {{\mathrm e}^{-2 x}}{2 x}-\expIntegral \left (1, 2 x \right )\right )+2 \,{\mathrm e}^{4} \expIntegral \left (1, 2 x \right )\) | \(49\) |
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.30, size = 46, normalized size = 1.70 \begin {gather*} -2 \, {\rm Ei}\left (-2 \, x\right ) e^{4} + \frac {1}{2} \, {\left (2 \, x + 1\right )} e^{\left (-2 \, x\right )} + 2 \, e^{4} \Gamma \left (-1, 2 \, x\right ) + 4 \, x - \frac {1}{2} \, e^{\left (-2 \, x\right )} + 2 \, e^{\left (-2 \, x + 2\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.36, size = 37, normalized size = 1.37 \begin {gather*} {\left (x^{3} + 2 \, x^{2} e^{2} + x e^{4} + 4 \, x e^{\left (2 \, x + 2 \, \log \left (x\right )\right )}\right )} e^{\left (-2 \, x - 2 \, \log \left (x\right )\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.05, size = 22, normalized size = 0.81 \begin {gather*} 4 x + \frac {\left (x^{2} + 2 x e^{2} + e^{4}\right ) e^{- 2 x}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.41, size = 33, normalized size = 1.22 \begin {gather*} \frac {x^{2} e^{\left (-2 \, x\right )} + 4 \, x^{2} + 2 \, x e^{\left (-2 \, x + 2\right )} + e^{\left (-2 \, x + 4\right )}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 5.14, size = 28, normalized size = 1.04 \begin {gather*} 4\,x+2\,{\mathrm {e}}^{2-2\,x}+x\,{\mathrm {e}}^{-2\,x}+\frac {{\mathrm {e}}^{4-2\,x}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________