Optimal. Leaf size=28 \[ -\left (e^{\left (e^{-1+x}+2 x\right )^2}+x\right )^2+\frac {\log ^2(x)}{x} \]
________________________________________________________________________________________
Rubi [B] time = 1.08, antiderivative size = 129, normalized size of antiderivative = 4.61, number of steps used = 9, number of rules used = 5, integrand size = 145, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.034, Rules used = {14, 6706, 2288, 2304, 2305} \begin {gather*} -x^2-e^{8 x^2+8 e^{x-1} x+2 e^{2 x-2}}-\frac {2 e^{4 x^2+4 e^{x-1} x+e^{2 x-2}-2} \left (2 e^{x+1} x^2+4 e^2 x^2+e^{2 x} x+2 e^{x+1} x\right )}{2 e^{x-1} x+4 x+2 e^{x-1}+e^{2 x-2}}+\frac {\log ^2(x)}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 14
Rule 2288
Rule 2304
Rule 2305
Rule 6706
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \left (-4 e^{-2+2 e^{-2+2 x}+8 e^{-1+x} x+8 x^2} \left (2 e+e^x\right ) \left (e^x+2 e x\right )-2 e^{-2+e^{-2+2 x}+4 e^{-1+x} x+4 x^2} \left (e^2+2 e^{2 x} x+4 e^{1+x} x+8 e^2 x^2+4 e^{1+x} x^2\right )+\frac {-2 x^3+2 \log (x)-\log ^2(x)}{x^2}\right ) \, dx\\ &=-\left (2 \int e^{-2+e^{-2+2 x}+4 e^{-1+x} x+4 x^2} \left (e^2+2 e^{2 x} x+4 e^{1+x} x+8 e^2 x^2+4 e^{1+x} x^2\right ) \, dx\right )-4 \int e^{-2+2 e^{-2+2 x}+8 e^{-1+x} x+8 x^2} \left (2 e+e^x\right ) \left (e^x+2 e x\right ) \, dx+\int \frac {-2 x^3+2 \log (x)-\log ^2(x)}{x^2} \, dx\\ &=-e^{2 e^{-2+2 x}+8 e^{-1+x} x+8 x^2}-\frac {2 e^{-2+e^{-2+2 x}+4 e^{-1+x} x+4 x^2} \left (e^{2 x} x+2 e^{1+x} x+4 e^2 x^2+2 e^{1+x} x^2\right )}{2 e^{-1+x}+e^{-2+2 x}+4 x+2 e^{-1+x} x}+\int \left (-2 x+\frac {2 \log (x)}{x^2}-\frac {\log ^2(x)}{x^2}\right ) \, dx\\ &=-e^{2 e^{-2+2 x}+8 e^{-1+x} x+8 x^2}-x^2-\frac {2 e^{-2+e^{-2+2 x}+4 e^{-1+x} x+4 x^2} \left (e^{2 x} x+2 e^{1+x} x+4 e^2 x^2+2 e^{1+x} x^2\right )}{2 e^{-1+x}+e^{-2+2 x}+4 x+2 e^{-1+x} x}+2 \int \frac {\log (x)}{x^2} \, dx-\int \frac {\log ^2(x)}{x^2} \, dx\\ &=-e^{2 e^{-2+2 x}+8 e^{-1+x} x+8 x^2}-\frac {2}{x}-x^2-\frac {2 e^{-2+e^{-2+2 x}+4 e^{-1+x} x+4 x^2} \left (e^{2 x} x+2 e^{1+x} x+4 e^2 x^2+2 e^{1+x} x^2\right )}{2 e^{-1+x}+e^{-2+2 x}+4 x+2 e^{-1+x} x}-\frac {2 \log (x)}{x}+\frac {\log ^2(x)}{x}-2 \int \frac {\log (x)}{x^2} \, dx\\ &=-e^{2 e^{-2+2 x}+8 e^{-1+x} x+8 x^2}-x^2-\frac {2 e^{-2+e^{-2+2 x}+4 e^{-1+x} x+4 x^2} \left (e^{2 x} x+2 e^{1+x} x+4 e^2 x^2+2 e^{1+x} x^2\right )}{2 e^{-1+x}+e^{-2+2 x}+4 x+2 e^{-1+x} x}+\frac {\log ^2(x)}{x}\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.38, size = 32, normalized size = 1.14 \begin {gather*} \frac {-x \left (e^{\frac {\left (e^x+2 e x\right )^2}{e^2}}+x\right )^2+\log ^2(x)}{x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.67, size = 64, normalized size = 2.29 \begin {gather*} -\frac {x^{3} + 2 \, x^{2} e^{\left (4 \, x^{2} + 4 \, x e^{\left (x - 1\right )} + e^{\left (2 \, x - 2\right )}\right )} + x e^{\left (8 \, x^{2} + 8 \, x e^{\left (x - 1\right )} + 2 \, e^{\left (2 \, x - 2\right )}\right )} - \log \relax (x)^{2}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.31, size = 64, normalized size = 2.29 \begin {gather*} -\frac {x^{3} + 2 \, x^{2} e^{\left (4 \, x^{2} + 4 \, x e^{\left (x - 1\right )} + e^{\left (2 \, x - 2\right )}\right )} + x e^{\left (8 \, x^{2} + 8 \, x e^{\left (x - 1\right )} + 2 \, e^{\left (2 \, x - 2\right )}\right )} - \log \relax (x)^{2}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.11, size = 62, normalized size = 2.21
method | result | size |
risch | \(\frac {\ln \relax (x )^{2}}{x}-x^{2}-{\mathrm e}^{2 \,{\mathrm e}^{2 x -2}+8 x \,{\mathrm e}^{x -1}+8 x^{2}}-2 x \,{\mathrm e}^{{\mathrm e}^{2 x -2}+4 x \,{\mathrm e}^{x -1}+4 x^{2}}\) | \(62\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 0.84, size = 67, normalized size = 2.39 \begin {gather*} -x^{2} - \frac {2 \, x^{2} e^{\left (4 \, x^{2} + 4 \, x e^{\left (x - 1\right )} + e^{\left (2 \, x - 2\right )}\right )} + x e^{\left (8 \, x^{2} + 8 \, x e^{\left (x - 1\right )} + 2 \, e^{\left (2 \, x - 2\right )}\right )} - \log \relax (x)^{2}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.88, size = 77, normalized size = 2.75 \begin {gather*} \frac {{\ln \relax (x)}^2+2\,\ln \relax (x)+2}{x}-{\mathrm {e}}^{2\,{\mathrm {e}}^{2\,x}\,{\mathrm {e}}^{-2}+8\,x^2+8\,x\,{\mathrm {e}}^{-1}\,{\mathrm {e}}^x}-\frac {2\,\left (\ln \relax (x)+1\right )}{x}-x^2-2\,x\,{\mathrm {e}}^{{\mathrm {e}}^{2\,x}\,{\mathrm {e}}^{-2}+4\,x^2+4\,x\,{\mathrm {e}}^{-1}\,{\mathrm {e}}^x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [B] time = 0.57, size = 58, normalized size = 2.07 \begin {gather*} - x^{2} - 2 x e^{4 x^{2} + 4 x e^{x - 1} + e^{2 x - 2}} - e^{8 x^{2} + 8 x e^{x - 1} + 2 e^{2 x - 2}} + \frac {\log {\relax (x )}^{2}}{x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________