3.158 \(\int \frac{2-3 x+4 x^2}{3-4 x+4 x^2} \, dx\)

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

[Out]

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

_______________________________________________________________________________________

Rubi [A]  time = 0.0592986, antiderivative size = 38, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 5, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.217 \[ \frac{1}{8} \log \left (4 x^2-4 x+3\right )+x+\frac{\tan ^{-1}\left (\frac{1-2 x}{\sqrt{2}}\right )}{4 \sqrt{2}} \]

Antiderivative was successfully verified.

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

[Out]

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

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 5.67476, size = 32, normalized size = 0.84 \[ x + \frac{\log{\left (4 x^{2} - 4 x + 3 \right )}}{8} - \frac{\sqrt{2} \operatorname{atan}{\left (\sqrt{2} \left (x - \frac{1}{2}\right ) \right )}}{8} \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Mathematica [A]  time = 0.0168122, size = 38, normalized size = 1. \[ \frac{1}{8} \log \left (4 x^2-4 x+3\right )+x-\frac{\tan ^{-1}\left (\frac{2 x-1}{\sqrt{2}}\right )}{4 \sqrt{2}} \]

Antiderivative was successfully verified.

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

[Out]

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

_______________________________________________________________________________________

Maple [A]  time = 0.009, size = 32, normalized size = 0.8 \[ x+{\frac{\ln \left ( 4\,{x}^{2}-4\,x+3 \right ) }{8}}-{\frac{\sqrt{2}}{8}\arctan \left ({\frac{ \left ( 8\,x-4 \right ) \sqrt{2}}{8}} \right ) } \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Maxima [A]  time = 1.51412, size = 42, normalized size = 1.11 \[ -\frac{1}{8} \, \sqrt{2} \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x - 1\right )}\right ) + x + \frac{1}{8} \, \log \left (4 \, x^{2} - 4 \, x + 3\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Fricas [A]  time = 0.233421, size = 54, normalized size = 1.42 \[ \frac{1}{16} \, \sqrt{2}{\left (8 \, \sqrt{2} x + \sqrt{2} \log \left (4 \, x^{2} - 4 \, x + 3\right ) - 2 \, \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x - 1\right )}\right )\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

Sympy [A]  time = 0.119971, size = 34, normalized size = 0.89 \[ x + \frac{\log{\left (x^{2} - x + \frac{3}{4} \right )}}{8} - \frac{\sqrt{2} \operatorname{atan}{\left (\sqrt{2} x - \frac{\sqrt{2}}{2} \right )}}{8} \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

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

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.20602, size = 42, normalized size = 1.11 \[ -\frac{1}{8} \, \sqrt{2} \arctan \left (\frac{1}{2} \, \sqrt{2}{\left (2 \, x - 1\right )}\right ) + x + \frac{1}{8} \,{\rm ln}\left (4 \, x^{2} - 4 \, x + 3\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

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

[Out]

-1/8*sqrt(2)*arctan(1/2*sqrt(2)*(2*x - 1)) + x + 1/8*ln(4*x^2 - 4*x + 3)