Optimal. Leaf size=77 \[ 3 x \tan ^{-1}(x)-\frac {3}{2} \tan ^{-1}(x)^2-\frac {1}{2} x^2 \tan ^{-1}(x)^2-\frac {3}{2} \log \left (1+x^2\right )-x \tan ^{-1}(x) \log \left (1+x^2\right )+\frac {1}{2} \left (1+x^2\right ) \tan ^{-1}(x)^2 \log \left (1+x^2\right )+\frac {1}{4} \log ^2\left (1+x^2\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.16, antiderivative size = 77, normalized size of antiderivative = 1.00, number of steps
used = 13, number of rules used = 10, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.833, Rules used = {4946, 5036,
4930, 266, 5004, 5143, 5129, 2525, 2437, 2338} \begin {gather*} -\frac {1}{2} x^2 \text {ArcTan}(x)^2+\frac {1}{2} \left (x^2+1\right ) \text {ArcTan}(x)^2 \log \left (x^2+1\right )-x \text {ArcTan}(x) \log \left (x^2+1\right )-\frac {3 \text {ArcTan}(x)^2}{2}+3 x \text {ArcTan}(x)+\frac {1}{4} \log ^2\left (x^2+1\right )-\frac {3}{2} \log \left (x^2+1\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 266
Rule 2338
Rule 2437
Rule 2525
Rule 4930
Rule 4946
Rule 5004
Rule 5036
Rule 5129
Rule 5143
Rubi steps
\begin {align*} \int x \tan ^{-1}(x)^2 \log \left (1+x^2\right ) \, dx &=-\frac {1}{2} x^2 \tan ^{-1}(x)^2+\frac {1}{2} \left (1+x^2\right ) \tan ^{-1}(x)^2 \log \left (1+x^2\right )+\int \frac {x^2 \tan ^{-1}(x)}{1+x^2} \, dx-\int \tan ^{-1}(x) \log \left (1+x^2\right ) \, dx\\ &=-\frac {1}{2} x^2 \tan ^{-1}(x)^2-x \tan ^{-1}(x) \log \left (1+x^2\right )+\frac {1}{2} \left (1+x^2\right ) \tan ^{-1}(x)^2 \log \left (1+x^2\right )+2 \int \frac {x^2 \tan ^{-1}(x)}{1+x^2} \, dx+\int \tan ^{-1}(x) \, dx-\int \frac {\tan ^{-1}(x)}{1+x^2} \, dx+\int \frac {x \log \left (1+x^2\right )}{1+x^2} \, dx\\ &=x \tan ^{-1}(x)-\frac {1}{2} \tan ^{-1}(x)^2-\frac {1}{2} x^2 \tan ^{-1}(x)^2-x \tan ^{-1}(x) \log \left (1+x^2\right )+\frac {1}{2} \left (1+x^2\right ) \tan ^{-1}(x)^2 \log \left (1+x^2\right )+\frac {1}{2} \text {Subst}\left (\int \frac {\log (1+x)}{1+x} \, dx,x,x^2\right )+2 \int \tan ^{-1}(x) \, dx-2 \int \frac {\tan ^{-1}(x)}{1+x^2} \, dx-\int \frac {x}{1+x^2} \, dx\\ &=3 x \tan ^{-1}(x)-\frac {3}{2} \tan ^{-1}(x)^2-\frac {1}{2} x^2 \tan ^{-1}(x)^2-\frac {1}{2} \log \left (1+x^2\right )-x \tan ^{-1}(x) \log \left (1+x^2\right )+\frac {1}{2} \left (1+x^2\right ) \tan ^{-1}(x)^2 \log \left (1+x^2\right )+\frac {1}{2} \text {Subst}\left (\int \frac {\log (x)}{x} \, dx,x,1+x^2\right )-2 \int \frac {x}{1+x^2} \, dx\\ &=3 x \tan ^{-1}(x)-\frac {3}{2} \tan ^{-1}(x)^2-\frac {1}{2} x^2 \tan ^{-1}(x)^2-\frac {3}{2} \log \left (1+x^2\right )-x \tan ^{-1}(x) \log \left (1+x^2\right )+\frac {1}{2} \left (1+x^2\right ) \tan ^{-1}(x)^2 \log \left (1+x^2\right )+\frac {1}{4} \log ^2\left (1+x^2\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.02, size = 58, normalized size = 0.75 \begin {gather*} \frac {1}{4} \left (-4 x \tan ^{-1}(x) \left (-3+\log \left (1+x^2\right )\right )+\left (-6+\log \left (1+x^2\right )\right ) \log \left (1+x^2\right )+2 \tan ^{-1}(x)^2 \left (-3-x^2+\left (1+x^2\right ) \log \left (1+x^2\right )\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
3.
time = 2.35, size = 1134, normalized size = 14.73
method | result | size |
default | \(\text {Expression too large to display}\) | \(1134\) |
risch | \(\text {Expression too large to display}\) | \(113915\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 3.14, size = 67, normalized size = 0.87 \begin {gather*} -\frac {1}{2} \, {\left (x^{2} - {\left (x^{2} + 1\right )} \log \left (x^{2} + 1\right ) + 1\right )} \arctan \left (x\right )^{2} - {\left (x \log \left (x^{2} + 1\right ) - 3 \, x + 2 \, \arctan \left (x\right )\right )} \arctan \left (x\right ) + \arctan \left (x\right )^{2} + \frac {1}{4} \, \log \left (x^{2} + 1\right )^{2} - \frac {3}{2} \, \log \left (x^{2} + 1\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.97, size = 52, normalized size = 0.68 \begin {gather*} -\frac {1}{2} \, {\left (x^{2} + 3\right )} \arctan \left (x\right )^{2} + 3 \, x \arctan \left (x\right ) + \frac {1}{2} \, {\left ({\left (x^{2} + 1\right )} \arctan \left (x\right )^{2} - 2 \, x \arctan \left (x\right ) - 3\right )} \log \left (x^{2} + 1\right ) + \frac {1}{4} \, \log \left (x^{2} + 1\right )^{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.48, size = 87, normalized size = 1.13 \begin {gather*} \frac {x^{2} \log {\left (x^{2} + 1 \right )} \operatorname {atan}^{2}{\left (x \right )}}{2} - \frac {x^{2} \operatorname {atan}^{2}{\left (x \right )}}{2} - x \log {\left (x^{2} + 1 \right )} \operatorname {atan}{\left (x \right )} + 3 x \operatorname {atan}{\left (x \right )} + \frac {\log {\left (x^{2} + 1 \right )}^{2}}{4} + \frac {\log {\left (x^{2} + 1 \right )} \operatorname {atan}^{2}{\left (x \right )}}{2} - \frac {3 \log {\left (x^{2} + 1 \right )}}{2} - \frac {3 \operatorname {atan}^{2}{\left (x \right )}}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.26, size = 78, normalized size = 1.01 \begin {gather*} \frac {{\ln \left (x^2+1\right )}^2}{4}-\frac {3\,\ln \left (x^2+1\right )}{2}-\frac {3\,{\mathrm {atan}\left (x\right )}^2}{2}+\frac {\ln \left (x^2+1\right )\,{\mathrm {atan}\left (x\right )}^2}{2}+x\,\left (3\,\mathrm {atan}\left (x\right )-\ln \left (x^2+1\right )\,\mathrm {atan}\left (x\right )\right )-x^2\,\left (\frac {{\mathrm {atan}\left (x\right )}^2}{2}-\frac {\ln \left (x^2+1\right )\,{\mathrm {atan}\left (x\right )}^2}{2}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________