Optimal. Leaf size=41 \[ \frac {1}{1+x}+\frac {4}{3} \sqrt {2} \tan ^{-1}\left (\frac {x}{\sqrt {2}}\right )-\frac {1}{3} \log (1+x)+\frac {2}{3} \log \left (2+x^2\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.06, antiderivative size = 41, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 5, integrand size = 33, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.152, Rules used = {1608, 2100,
649, 209, 266} \begin {gather*} \frac {4}{3} \sqrt {2} \text {ArcTan}\left (\frac {x}{\sqrt {2}}\right )+\frac {2}{3} \log \left (x^2+2\right )+\frac {1}{x+1}-\frac {1}{3} \log (x+1) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 209
Rule 266
Rule 649
Rule 1608
Rule 2100
Rubi steps
\begin {align*} \int \frac {6 x+4 x^2+x^3}{2+4 x+3 x^2+2 x^3+x^4} \, dx &=\int \frac {x \left (6+4 x+x^2\right )}{2+4 x+3 x^2+2 x^3+x^4} \, dx\\ &=\int \left (-\frac {1}{(1+x)^2}-\frac {1}{3 (1+x)}+\frac {4 (2+x)}{3 \left (2+x^2\right )}\right ) \, dx\\ &=\frac {1}{1+x}-\frac {1}{3} \log (1+x)+\frac {4}{3} \int \frac {2+x}{2+x^2} \, dx\\ &=\frac {1}{1+x}-\frac {1}{3} \log (1+x)+\frac {4}{3} \int \frac {x}{2+x^2} \, dx+\frac {8}{3} \int \frac {1}{2+x^2} \, dx\\ &=\frac {1}{1+x}+\frac {4}{3} \sqrt {2} \tan ^{-1}\left (\frac {x}{\sqrt {2}}\right )-\frac {1}{3} \log (1+x)+\frac {2}{3} \log \left (2+x^2\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.02, size = 41, normalized size = 1.00 \begin {gather*} \frac {1}{1+x}+\frac {4}{3} \sqrt {2} \tan ^{-1}\left (\frac {x}{\sqrt {2}}\right )-\frac {1}{3} \log (1+x)+\frac {2}{3} \log \left (2+x^2\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.02, size = 33, normalized size = 0.80
method | result | size |
default | \(\frac {1}{1+x}-\frac {\ln \left (1+x \right )}{3}+\frac {2 \ln \left (x^{2}+2\right )}{3}+\frac {4 \arctan \left (\frac {x \sqrt {2}}{2}\right ) \sqrt {2}}{3}\) | \(33\) |
risch | \(\frac {1}{1+x}-\frac {\ln \left (1+x \right )}{3}+\frac {2 \ln \left (x^{2}+2\right )}{3}+\frac {4 \arctan \left (\frac {x \sqrt {2}}{2}\right ) \sqrt {2}}{3}\) | \(33\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 2.01, size = 32, normalized size = 0.78 \begin {gather*} \frac {4}{3} \, \sqrt {2} \arctan \left (\frac {1}{2} \, \sqrt {2} x\right ) + \frac {1}{x + 1} + \frac {2}{3} \, \log \left (x^{2} + 2\right ) - \frac {1}{3} \, \log \left (x + 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.55, size = 44, normalized size = 1.07 \begin {gather*} \frac {4 \, \sqrt {2} {\left (x + 1\right )} \arctan \left (\frac {1}{2} \, \sqrt {2} x\right ) + 2 \, {\left (x + 1\right )} \log \left (x^{2} + 2\right ) - {\left (x + 1\right )} \log \left (x + 1\right ) + 3}{3 \, {\left (x + 1\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.06, size = 39, normalized size = 0.95 \begin {gather*} - \frac {\log {\left (x + 1 \right )}}{3} + \frac {2 \log {\left (x^{2} + 2 \right )}}{3} + \frac {4 \sqrt {2} \operatorname {atan}{\left (\frac {\sqrt {2} x}{2} \right )}}{3} + \frac {1}{x + 1} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.79, size = 33, normalized size = 0.80 \begin {gather*} \frac {4}{3} \, \sqrt {2} \arctan \left (\frac {1}{2} \, \sqrt {2} x\right ) + \frac {1}{x + 1} + \frac {2}{3} \, \log \left (x^{2} + 2\right ) - \frac {1}{3} \, \log \left ({\left | x + 1 \right |}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.25, size = 49, normalized size = 1.20 \begin {gather*} \frac {1}{x+1}-\frac {\ln \left (x+1\right )}{3}-\ln \left (x-\sqrt {2}\,1{}\mathrm {i}\right )\,\left (-\frac {2}{3}+\frac {\sqrt {2}\,2{}\mathrm {i}}{3}\right )+\ln \left (x+\sqrt {2}\,1{}\mathrm {i}\right )\,\left (\frac {2}{3}+\frac {\sqrt {2}\,2{}\mathrm {i}}{3}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________