3.262 \(\int \frac{-1+2 x^2}{(-1+4 x) \left (1+x^2\right )} \, dx\)

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

[Out]

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

_______________________________________________________________________________________

Rubi [A]  time = 0.0737282, antiderivative size = 27, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 4, integrand size = 22, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.182 \[ \frac{6}{17} \log \left (x^2+1\right )-\frac{7}{34} \log (1-4 x)+\frac{3}{17} \tan ^{-1}(x) \]

Antiderivative was successfully verified.

[In]  Int[(-1 + 2*x^2)/((-1 + 4*x)*(1 + x^2)),x]

[Out]

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

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 8.09436, size = 26, normalized size = 0.96 \[ - \frac{7 \log{\left (- 4 x + 1 \right )}}{34} + \frac{6 \log{\left (x^{2} + 1 \right )}}{17} + \frac{3 \operatorname{atan}{\left (x \right )}}{17} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((2*x**2-1)/(-1+4*x)/(x**2+1),x)

[Out]

-7*log(-4*x + 1)/34 + 6*log(x**2 + 1)/17 + 3*atan(x)/17

_______________________________________________________________________________________

Mathematica [A]  time = 0.0165882, size = 38, normalized size = 1.41 \[ -\frac{7}{34} \log (4 x-1)+\frac{6}{17} \log \left ((4 x-1)^2+2 (4 x-1)+17\right )+\frac{3}{17} \tan ^{-1}(x) \]

Antiderivative was successfully verified.

[In]  Integrate[(-1 + 2*x^2)/((-1 + 4*x)*(1 + x^2)),x]

[Out]

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

_______________________________________________________________________________________

Maple [A]  time = 0.008, size = 22, normalized size = 0.8 \[{\frac{6\,\ln \left ({x}^{2}+1 \right ) }{17}}+{\frac{3\,\arctan \left ( x \right ) }{17}}-{\frac{7\,\ln \left ( -1+4\,x \right ) }{34}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((2*x^2-1)/(-1+4*x)/(x^2+1),x)

[Out]

6/17*ln(x^2+1)+3/17*arctan(x)-7/34*ln(-1+4*x)

_______________________________________________________________________________________

Maxima [A]  time = 0.982327, size = 28, normalized size = 1.04 \[ \frac{3}{17} \, \arctan \left (x\right ) + \frac{6}{17} \, \log \left (x^{2} + 1\right ) - \frac{7}{34} \, \log \left (4 \, x - 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((2*x^2 - 1)/((x^2 + 1)*(4*x - 1)),x, algorithm="maxima")

[Out]

3/17*arctan(x) + 6/17*log(x^2 + 1) - 7/34*log(4*x - 1)

_______________________________________________________________________________________

Fricas [A]  time = 0.256568, size = 28, normalized size = 1.04 \[ \frac{3}{17} \, \arctan \left (x\right ) + \frac{6}{17} \, \log \left (x^{2} + 1\right ) - \frac{7}{34} \, \log \left (4 \, x - 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((2*x^2 - 1)/((x^2 + 1)*(4*x - 1)),x, algorithm="fricas")

[Out]

3/17*arctan(x) + 6/17*log(x^2 + 1) - 7/34*log(4*x - 1)

_______________________________________________________________________________________

Sympy [A]  time = 0.313382, size = 26, normalized size = 0.96 \[ - \frac{7 \log{\left (x - \frac{1}{4} \right )}}{34} + \frac{6 \log{\left (x^{2} + 1 \right )}}{17} + \frac{3 \operatorname{atan}{\left (x \right )}}{17} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((2*x**2-1)/(-1+4*x)/(x**2+1),x)

[Out]

-7*log(x - 1/4)/34 + 6*log(x**2 + 1)/17 + 3*atan(x)/17

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.264672, size = 30, normalized size = 1.11 \[ \frac{3}{17} \, \arctan \left (x\right ) + \frac{6}{17} \,{\rm ln}\left (x^{2} + 1\right ) - \frac{7}{34} \,{\rm ln}\left ({\left | 4 \, x - 1 \right |}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((2*x^2 - 1)/((x^2 + 1)*(4*x - 1)),x, algorithm="giac")

[Out]

3/17*arctan(x) + 6/17*ln(x^2 + 1) - 7/34*ln(abs(4*x - 1))