Optimal. Leaf size=30 \[ \frac {1}{2} x \log \left (\frac {e^{2 x} x^2}{4 \left (-5+e^3\right )^2 (1+x)^2}\right ) \]
________________________________________________________________________________________
Rubi [A] time = 0.09, antiderivative size = 32, normalized size of antiderivative = 1.07, number of steps used = 8, number of rules used = 4, integrand size = 72, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.056, Rules used = {6688, 698, 2548, 12} \begin {gather*} \frac {1}{2} x \log \left (\frac {e^{2 x} x^2}{4 \left (5-e^3\right )^2 (x+1)^2}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 698
Rule 2548
Rule 6688
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \left (\frac {1+x+x^2}{1+x}+\frac {1}{2} \log \left (\frac {e^{2 x} x^2}{4 \left (-5+e^3\right )^2 (1+x)^2}\right )\right ) \, dx\\ &=\frac {1}{2} \int \log \left (\frac {e^{2 x} x^2}{4 \left (-5+e^3\right )^2 (1+x)^2}\right ) \, dx+\int \frac {1+x+x^2}{1+x} \, dx\\ &=\frac {1}{2} x \log \left (\frac {e^{2 x} x^2}{4 \left (5-e^3\right )^2 (1+x)^2}\right )-\frac {1}{2} \int \frac {2 \left (1+x+x^2\right )}{1+x} \, dx+\int \left (x+\frac {1}{1+x}\right ) \, dx\\ &=\frac {x^2}{2}+\frac {1}{2} x \log \left (\frac {e^{2 x} x^2}{4 \left (5-e^3\right )^2 (1+x)^2}\right )+\log (1+x)-\int \frac {1+x+x^2}{1+x} \, dx\\ &=\frac {x^2}{2}+\frac {1}{2} x \log \left (\frac {e^{2 x} x^2}{4 \left (5-e^3\right )^2 (1+x)^2}\right )+\log (1+x)-\int \left (x+\frac {1}{1+x}\right ) \, dx\\ &=\frac {1}{2} x \log \left (\frac {e^{2 x} x^2}{4 \left (5-e^3\right )^2 (1+x)^2}\right )\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.04, size = 33, normalized size = 1.10 \begin {gather*} \frac {1}{2} \left (1+x \log \left (\frac {e^{2 x} x^2}{4 \left (-5+e^3\right )^2 (1+x)^2}\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.61, size = 48, normalized size = 1.60 \begin {gather*} \frac {1}{2} \, x \log \left (\frac {x^{2} e^{\left (2 \, x\right )}}{4 \, {\left (25 \, x^{2} + {\left (x^{2} + 2 \, x + 1\right )} e^{6} - 10 \, {\left (x^{2} + 2 \, x + 1\right )} e^{3} + 50 \, x + 25\right )}}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.46, size = 54, normalized size = 1.80 \begin {gather*} x^{2} + \frac {1}{2} \, x \log \left (\frac {x^{2}}{4 \, {\left (x^{2} e^{6} - 10 \, x^{2} e^{3} + 25 \, x^{2} + 2 \, x e^{6} - 20 \, x e^{3} + 50 \, x + e^{6} - 10 \, e^{3} + 25\right )}}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.36, size = 53, normalized size = 1.77
method | result | size |
norman | \(\frac {x \ln \left (\frac {x^{2} {\mathrm e}^{2 x}}{\left (4 x^{2}+8 x +4\right ) {\mathrm e}^{6}+\left (-40 x^{2}-80 x -40\right ) {\mathrm e}^{3}+100 x^{2}+200 x +100}\right )}{2}\) | \(53\) |
default | \(\frac {x^{2}}{2}+\ln \left (x +1\right )+\frac {625 x}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}-\frac {25 x^{2}}{2 \left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )}-\frac {625 \ln \left (x +1\right )}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}-\frac {25 x}{{\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25}+\frac {x \ln \left (\frac {x^{2} {\mathrm e}^{2 x}}{\left (4 x^{2}+8 x +4\right ) {\mathrm e}^{6}+\left (-40 x^{2}-80 x -40\right ) {\mathrm e}^{3}+100 x^{2}+200 x +100}\right )}{2}+\frac {10 \,{\mathrm e}^{3} x}{{\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25}-\frac {{\mathrm e}^{6} x}{{\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25}+\frac {500 \,{\mathrm e}^{3} \ln \left (x +1\right )}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}-\frac {150 \,{\mathrm e}^{6} \ln \left (x +1\right )}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}+\frac {20 \,{\mathrm e}^{9} \ln \left (x +1\right )}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}-\frac {{\mathrm e}^{12} \ln \left (x +1\right )}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}+\frac {5 \,{\mathrm e}^{3} x^{2}}{{\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25}-\frac {{\mathrm e}^{6} x^{2}}{2 \left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )}-\frac {500 \,{\mathrm e}^{3} x}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}+\frac {150 \,{\mathrm e}^{6} x}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}-\frac {20 \,{\mathrm e}^{9} x}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}+\frac {{\mathrm e}^{12} x}{\left ({\mathrm e}^{6}-10 \,{\mathrm e}^{3}+25\right )^{2}}\) | \(363\) |
risch | \(-x \ln \relax (2)+x \ln \relax (x )-x \ln \left ({\mathrm e}^{3}-5\right )+x \ln \left ({\mathrm e}^{x}\right )-x \ln \left (x +1\right )+\frac {i x \pi \,\mathrm {csgn}\left (\frac {i}{\left (x +1\right )^{2}}\right ) \mathrm {csgn}\left (\frac {i {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )^{2}}{4}+\frac {i x \pi \,\mathrm {csgn}\left (i {\mathrm e}^{2 x}\right ) \mathrm {csgn}\left (\frac {i {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )^{2}}{4}-\frac {i x \pi \mathrm {csgn}\left (\frac {i {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )^{3}}{4}+\frac {i x \pi \,\mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (\frac {i x^{2} {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )^{2}}{4}+\frac {i x \pi \,\mathrm {csgn}\left (\frac {i {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right ) \mathrm {csgn}\left (\frac {i x^{2} {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )^{2}}{4}+\frac {i x \pi \,\mathrm {csgn}\left (i {\mathrm e}^{x}\right ) \mathrm {csgn}\left (i {\mathrm e}^{2 x}\right )^{2}}{2}+\frac {i x \pi \mathrm {csgn}\left (i \left (x +1\right )^{2}\right )^{3}}{4}-\frac {i x \pi \mathrm {csgn}\left (\frac {i x^{2} {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )^{3}}{4}-\frac {i x \pi \mathrm {csgn}\left (i {\mathrm e}^{x}\right )^{2} \mathrm {csgn}\left (i {\mathrm e}^{2 x}\right )}{4}-\frac {i x \pi \mathrm {csgn}\left (i {\mathrm e}^{2 x}\right )^{3}}{4}-\frac {i x \pi \,\mathrm {csgn}\left (i x^{2}\right ) \mathrm {csgn}\left (\frac {i {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right ) \mathrm {csgn}\left (\frac {i x^{2} {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )}{4}-\frac {i x \pi \mathrm {csgn}\left (i x \right )^{2} \mathrm {csgn}\left (i x^{2}\right )}{4}-\frac {i x \pi \,\mathrm {csgn}\left (\frac {i}{\left (x +1\right )^{2}}\right ) \mathrm {csgn}\left (i {\mathrm e}^{2 x}\right ) \mathrm {csgn}\left (\frac {i {\mathrm e}^{2 x}}{\left (x +1\right )^{2}}\right )}{4}-\frac {i x \pi \mathrm {csgn}\left (i x^{2}\right )^{3}}{4}-\frac {i x \pi \,\mathrm {csgn}\left (i \left (x +1\right )\right ) \mathrm {csgn}\left (i \left (x +1\right )^{2}\right )^{2}}{2}+\frac {i x \pi \mathrm {csgn}\left (i \left (x +1\right )\right )^{2} \mathrm {csgn}\left (i \left (x +1\right )^{2}\right )}{4}+\frac {i x \pi \,\mathrm {csgn}\left (i x \right ) \mathrm {csgn}\left (i x^{2}\right )^{2}}{2}\) | \(444\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 1.01, size = 32, normalized size = 1.07 \begin {gather*} x^{2} - x {\left (\log \relax (2) + \log \left (e^{3} - 5\right )\right )} - {\left (x + 1\right )} \log \left (x + 1\right ) + x \log \relax (x) + \log \left (x + 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.36, size = 56, normalized size = 1.87 \begin {gather*} \frac {x\,\left (2\,x-\ln \left (200\,x-40\,{\mathrm {e}}^3+4\,{\mathrm {e}}^6-80\,x\,{\mathrm {e}}^3+8\,x\,{\mathrm {e}}^6-40\,x^2\,{\mathrm {e}}^3+4\,x^2\,{\mathrm {e}}^6+100\,x^2+100\right )+\ln \left (x^2\right )\right )}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [B] time = 0.45, size = 70, normalized size = 2.33 \begin {gather*} - \frac {x}{6} + \left (\frac {x}{2} + \frac {1}{12}\right ) \log {\left (\frac {x^{2} e^{2 x}}{100 x^{2} + 200 x + \left (- 40 x^{2} - 80 x - 40\right ) e^{3} + \left (4 x^{2} + 8 x + 4\right ) e^{6} + 100} \right )} - \frac {\log {\relax (x )}}{6} + \frac {\log {\left (x + 1 \right )}}{6} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________