Optimal. Leaf size=112 \[ -\frac {1}{4} \log \left (x^4+1\right )+\frac {x^2}{2}+\frac {\log \left (x^2-\sqrt {2} x+1\right )}{4 \sqrt {2}}-\frac {\log \left (x^2+\sqrt {2} x+1\right )}{4 \sqrt {2}}-\frac {1}{2} \tan ^{-1}\left (x^2\right )+\log (x)-\frac {\tan ^{-1}\left (1-\sqrt {2} x\right )}{2 \sqrt {2}}+\frac {\tan ^{-1}\left (\sqrt {2} x+1\right )}{2 \sqrt {2}} \]
________________________________________________________________________________________
Rubi [A] time = 0.11, antiderivative size = 112, normalized size of antiderivative = 1.00, number of steps used = 18, number of rules used = 13, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.812, Rules used = {1593, 1833, 297, 1162, 617, 204, 1165, 628, 1834, 1248, 635, 203, 260} \begin {gather*} \frac {x^2}{2}+\frac {\log \left (x^2-\sqrt {2} x+1\right )}{4 \sqrt {2}}-\frac {\log \left (x^2+\sqrt {2} x+1\right )}{4 \sqrt {2}}-\frac {1}{4} \log \left (x^4+1\right )-\frac {1}{2} \tan ^{-1}\left (x^2\right )+\log (x)-\frac {\tan ^{-1}\left (1-\sqrt {2} x\right )}{2 \sqrt {2}}+\frac {\tan ^{-1}\left (\sqrt {2} x+1\right )}{2 \sqrt {2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 203
Rule 204
Rule 260
Rule 297
Rule 617
Rule 628
Rule 635
Rule 1162
Rule 1165
Rule 1248
Rule 1593
Rule 1833
Rule 1834
Rubi steps
\begin {align*} \int \frac {1+x^3+x^6}{x+x^5} \, dx &=\int \frac {1+x^3+x^6}{x \left (1+x^4\right )} \, dx\\ &=\int \left (\frac {x^2}{1+x^4}+\frac {1+x^6}{x \left (1+x^4\right )}\right ) \, dx\\ &=\int \frac {x^2}{1+x^4} \, dx+\int \frac {1+x^6}{x \left (1+x^4\right )} \, dx\\ &=-\left (\frac {1}{2} \int \frac {1-x^2}{1+x^4} \, dx\right )+\frac {1}{2} \int \frac {1+x^2}{1+x^4} \, dx+\int \left (\frac {1}{x}+x+\frac {x \left (-1-x^2\right )}{1+x^4}\right ) \, dx\\ &=\frac {x^2}{2}+\log (x)+\frac {1}{4} \int \frac {1}{1-\sqrt {2} x+x^2} \, dx+\frac {1}{4} \int \frac {1}{1+\sqrt {2} x+x^2} \, dx+\frac {\int \frac {\sqrt {2}+2 x}{-1-\sqrt {2} x-x^2} \, dx}{4 \sqrt {2}}+\frac {\int \frac {\sqrt {2}-2 x}{-1+\sqrt {2} x-x^2} \, dx}{4 \sqrt {2}}+\int \frac {x \left (-1-x^2\right )}{1+x^4} \, dx\\ &=\frac {x^2}{2}+\log (x)+\frac {\log \left (1-\sqrt {2} x+x^2\right )}{4 \sqrt {2}}-\frac {\log \left (1+\sqrt {2} x+x^2\right )}{4 \sqrt {2}}+\frac {1}{2} \operatorname {Subst}\left (\int \frac {-1-x}{1+x^2} \, dx,x,x^2\right )+\frac {\operatorname {Subst}\left (\int \frac {1}{-1-x^2} \, dx,x,1-\sqrt {2} x\right )}{2 \sqrt {2}}-\frac {\operatorname {Subst}\left (\int \frac {1}{-1-x^2} \, dx,x,1+\sqrt {2} x\right )}{2 \sqrt {2}}\\ &=\frac {x^2}{2}-\frac {\tan ^{-1}\left (1-\sqrt {2} x\right )}{2 \sqrt {2}}+\frac {\tan ^{-1}\left (1+\sqrt {2} x\right )}{2 \sqrt {2}}+\log (x)+\frac {\log \left (1-\sqrt {2} x+x^2\right )}{4 \sqrt {2}}-\frac {\log \left (1+\sqrt {2} x+x^2\right )}{4 \sqrt {2}}-\frac {1}{2} \operatorname {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,x^2\right )-\frac {1}{2} \operatorname {Subst}\left (\int \frac {x}{1+x^2} \, dx,x,x^2\right )\\ &=\frac {x^2}{2}-\frac {1}{2} \tan ^{-1}\left (x^2\right )-\frac {\tan ^{-1}\left (1-\sqrt {2} x\right )}{2 \sqrt {2}}+\frac {\tan ^{-1}\left (1+\sqrt {2} x\right )}{2 \sqrt {2}}+\log (x)+\frac {\log \left (1-\sqrt {2} x+x^2\right )}{4 \sqrt {2}}-\frac {\log \left (1+\sqrt {2} x+x^2\right )}{4 \sqrt {2}}-\frac {1}{4} \log \left (1+x^4\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.05, size = 101, normalized size = 0.90 \begin {gather*} \frac {1}{8} \left (-2 \log \left (x^4+1\right )+4 x^2+\sqrt {2} \log \left (x^2-\sqrt {2} x+1\right )-\sqrt {2} \log \left (x^2+\sqrt {2} x+1\right )+8 \log (x)-2 \left (\sqrt {2}-2\right ) \tan ^{-1}\left (1-\sqrt {2} x\right )+2 \left (2+\sqrt {2}\right ) \tan ^{-1}\left (\sqrt {2} x+1\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
IntegrateAlgebraic [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {1+x^3+x^6}{x+x^5} \, dx \end {gather*}
Verification is not applicable to the result.
[In]
[Out]
________________________________________________________________________________________
fricas [C] time = 4.32, size = 515, normalized size = 4.60
result too large to display
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.39, size = 92, normalized size = 0.82 \begin {gather*} \frac {1}{2} \, x^{2} + \frac {1}{4} \, {\left (\sqrt {2} + 2\right )} \arctan \left (\frac {1}{2} \, \sqrt {2} {\left (2 \, x + \sqrt {2}\right )}\right ) + \frac {1}{4} \, {\left (\sqrt {2} - 2\right )} \arctan \left (\frac {1}{2} \, \sqrt {2} {\left (2 \, x - \sqrt {2}\right )}\right ) - \frac {1}{8} \, \sqrt {2} \log \left (x^{2} + \sqrt {2} x + 1\right ) + \frac {1}{8} \, \sqrt {2} \log \left (x^{2} - \sqrt {2} x + 1\right ) - \frac {1}{4} \, \log \left (x^{4} + 1\right ) + \log \left ({\left | x \right |}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.01, size = 79, normalized size = 0.71 \begin {gather*} \frac {x^{2}}{2}-\frac {\arctan \left (x^{2}\right )}{2}+\frac {\sqrt {2}\, \arctan \left (\sqrt {2}\, x -1\right )}{4}+\frac {\sqrt {2}\, \arctan \left (\sqrt {2}\, x +1\right )}{4}+\ln \relax (x )+\frac {\sqrt {2}\, \ln \left (\frac {x^{2}-\sqrt {2}\, x +1}{x^{2}+\sqrt {2}\, x +1}\right )}{8}-\frac {\ln \left (x^{4}+1\right )}{4} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 2.06, size = 99, normalized size = 0.88 \begin {gather*} \frac {1}{4} \, \sqrt {2} {\left (\sqrt {2} + 1\right )} \arctan \left (\frac {1}{2} \, \sqrt {2} {\left (2 \, x + \sqrt {2}\right )}\right ) - \frac {1}{4} \, \sqrt {2} {\left (\sqrt {2} - 1\right )} \arctan \left (\frac {1}{2} \, \sqrt {2} {\left (2 \, x - \sqrt {2}\right )}\right ) - \frac {1}{8} \, \sqrt {2} {\left (\sqrt {2} + 1\right )} \log \left (x^{2} + \sqrt {2} x + 1\right ) - \frac {1}{8} \, \sqrt {2} {\left (\sqrt {2} - 1\right )} \log \left (x^{2} - \sqrt {2} x + 1\right ) + \frac {1}{2} \, x^{2} + \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 2.23, size = 170, normalized size = 1.52 \begin {gather*} \ln \relax (x)+\left (\sum _{k=1}^4\ln \left (\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )\,\left (8\,\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )+x+\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )\,x\,96+{\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )}^2\,x\,240+{\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )}^3\,x\,320-16\,{\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )}^2+8\right )\right )\,\mathrm {root}\left (z^4+z^3+\frac {z^2}{2}+\frac {z}{16}+\frac {1}{256},z,k\right )\right )+\frac {x^2}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.96, size = 61, normalized size = 0.54 \begin {gather*} \frac {x^{2}}{2} + \log {\relax (x )} + \operatorname {RootSum} {\left (256 t^{4} + 256 t^{3} + 128 t^{2} + 16 t + 1, \left (t \mapsto t \log {\left (\frac {1792 t^{4}}{73} + \frac {704 t^{3}}{219} - \frac {3152 t^{2}}{219} - \frac {2584 t}{219} + x - \frac {344}{219} \right )} \right )\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________