3.46 \(\int x \tan ^{-1}(x)^2 \log \left (1+x^2\right ) \, dx\)

Optimal. Leaf size=77 \[ \frac{1}{4} \log ^2\left (x^2+1\right )-\frac{3}{2} \log \left (x^2+1\right )-\frac{1}{2} x^2 \tan ^{-1}(x)^2+\frac{1}{2} \left (x^2+1\right ) \log \left (x^2+1\right ) \tan ^{-1}(x)^2-x \log \left (x^2+1\right ) \tan ^{-1}(x)-\frac{3}{2} \tan ^{-1}(x)^2+3 x \tan ^{-1}(x) \]

[Out]

3*x*ArcTan[x] - (3*ArcTan[x]^2)/2 - (x^2*ArcTan[x]^2)/2 - (3*Log[1 + x^2])/2 - x
*ArcTan[x]*Log[1 + x^2] + ((1 + x^2)*ArcTan[x]^2*Log[1 + x^2])/2 + Log[1 + x^2]^
2/4

_______________________________________________________________________________________

Rubi [A]  time = 0.32338, antiderivative size = 77, normalized size of antiderivative = 1., number of steps used = 13, number of rules used = 10, integrand size = 12, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.833 \[ \frac{1}{4} \log ^2\left (x^2+1\right )-\frac{3}{2} \log \left (x^2+1\right )-\frac{1}{2} x^2 \tan ^{-1}(x)^2+\frac{1}{2} \left (x^2+1\right ) \log \left (x^2+1\right ) \tan ^{-1}(x)^2-x \log \left (x^2+1\right ) \tan ^{-1}(x)-\frac{3}{2} \tan ^{-1}(x)^2+3 x \tan ^{-1}(x) \]

Antiderivative was successfully verified.

[In]  Int[x*ArcTan[x]^2*Log[1 + x^2],x]

[Out]

3*x*ArcTan[x] - (3*ArcTan[x]^2)/2 - (x^2*ArcTan[x]^2)/2 - (3*Log[1 + x^2])/2 - x
*ArcTan[x]*Log[1 + x^2] + ((1 + x^2)*ArcTan[x]^2*Log[1 + x^2])/2 + Log[1 + x^2]^
2/4

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 170.557, size = 87, normalized size = 1.13 \[ \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} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(x*atan(x)**2*ln(x**2+1),x)

[Out]

x**2*log(x**2 + 1)*atan(x)**2/2 - x**2*atan(x)**2/2 - x*log(x**2 + 1)*atan(x) +
3*x*atan(x) + log(x**2 + 1)**2/4 + log(x**2 + 1)*atan(x)**2/2 - 3*log(x**2 + 1)/
2 - 3*atan(x)**2/2

_______________________________________________________________________________________

Mathematica [A]  time = 0.0225726, size = 58, normalized size = 0.75 \[ \frac{1}{4} \left (\left (\log \left (x^2+1\right )-6\right ) \log \left (x^2+1\right )+2 \left (-x^2+\left (x^2+1\right ) \log \left (x^2+1\right )-3\right ) \tan ^{-1}(x)^2-4 x \left (\log \left (x^2+1\right )-3\right ) \tan ^{-1}(x)\right ) \]

Antiderivative was successfully verified.

[In]  Integrate[x*ArcTan[x]^2*Log[1 + x^2],x]

[Out]

(-4*x*ArcTan[x]*(-3 + Log[1 + x^2]) + (-6 + Log[1 + x^2])*Log[1 + x^2] + 2*ArcTa
n[x]^2*(-3 - x^2 + (1 + x^2)*Log[1 + x^2]))/4

_______________________________________________________________________________________

Maple [C]  time = 1.375, size = 3138, normalized size = 40.8 \[ \text{output too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(x*arctan(x)^2*ln(x^2+1),x)

[Out]

1/2*I*csgn(I/((1+I*x)^2/(x^2+1)+1)^2)*csgn(I*(1+I*x)^2/(x^2+1))*csgn(I*(1+I*x)^2
/(x^2+1)/((1+I*x)^2/(x^2+1)+1)^2)*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/(x^2+1))*csgn(I*(1+I*x)^2
/(x^2+1)/((1+I*x)^2/(x^2+1)+1)^2)^2*Pi*arctan(x)^2*x^2+1/4*I*csgn(I*(1+I*x)^2/(x
^2+1))*csgn(I*(1+I*x)^2/(x^2+1)/((1+I*x)^2/(x^2+1)+1)^2)^2*Pi*arctan(x)^2+1/4*I*
csgn(I/((1+I*x)^2/(x^2+1)+1)^2)*csgn(I*(1+I*x)^2/(x^2+1)/((1+I*x)^2/(x^2+1)+1)^2
)^2*Pi*arctan(x)^2

_______________________________________________________________________________________

Maxima [A]  time = 1.68685, size = 90, normalized size = 1.17 \[ -\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 ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x*arctan(x)^2*log(x^2 + 1),x, algorithm="maxima")

[Out]

-1/2*(x^2 - (x^2 + 1)*log(x^2 + 1) + 1)*arctan(x)^2 - (x*log(x^2 + 1) - 3*x + 2*
arctan(x))*arctan(x) + arctan(x)^2 + 1/4*log(x^2 + 1)^2 - 3/2*log(x^2 + 1)

_______________________________________________________________________________________

Fricas [A]  time = 0.216174, size = 70, normalized size = 0.91 \[ -\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} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x*arctan(x)^2*log(x^2 + 1),x, algorithm="fricas")

[Out]

-1/2*(x^2 + 3)*arctan(x)^2 + 3*x*arctan(x) + 1/2*((x^2 + 1)*arctan(x)^2 - 2*x*ar
ctan(x) - 3)*log(x^2 + 1) + 1/4*log(x^2 + 1)^2

_______________________________________________________________________________________

Sympy [A]  time = 4.58137, size = 87, normalized size = 1.13 \[ \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} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x*atan(x)**2*ln(x**2+1),x)

[Out]

x**2*log(x**2 + 1)*atan(x)**2/2 - x**2*atan(x)**2/2 - x*log(x**2 + 1)*atan(x) +
3*x*atan(x) + log(x**2 + 1)**2/4 + log(x**2 + 1)*atan(x)**2/2 - 3*log(x**2 + 1)/
2 - 3*atan(x)**2/2

_______________________________________________________________________________________

GIAC/XCAS [F]  time = 0., size = 0, normalized size = 0. \[ \int x \arctan \left (x\right )^{2} \log \left (x^{2} + 1\right )\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x*arctan(x)^2*log(x^2 + 1),x, algorithm="giac")

[Out]

integrate(x*arctan(x)^2*log(x^2 + 1), x)