Optimal. Leaf size=24 \[ -\log \left (x^2+1\right )-\frac{1}{x}+2 \log (1-x)+\tan ^{-1}(x) \]
[Out]
_______________________________________________________________________________________
Rubi [A] time = 0.31502, antiderivative size = 24, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 4, integrand size = 24, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167 \[ -\log \left (x^2+1\right )-\frac{1}{x}+2 \log (1-x)+\tan ^{-1}(x) \]
Antiderivative was successfully verified.
[In] Int[(-1 + x + 4*x^3)/((-1 + x)*x^2*(1 + x^2)),x]
[Out]
_______________________________________________________________________________________
Rubi in Sympy [A] time = 85.723, size = 19, normalized size = 0.79 \[ 2 \log{\left (- x + 1 \right )} - \log{\left (x^{2} + 1 \right )} + \operatorname{atan}{\left (x \right )} - \frac{1}{x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] rubi_integrate((4*x**3+x-1)/(-1+x)/x**2/(x**2+1),x)
[Out]
_______________________________________________________________________________________
Mathematica [A] time = 0.0143346, size = 24, normalized size = 1. \[ -\log \left (x^2+1\right )-\frac{1}{x}+2 \log (1-x)+\tan ^{-1}(x) \]
Antiderivative was successfully verified.
[In] Integrate[(-1 + x + 4*x^3)/((-1 + x)*x^2*(1 + x^2)),x]
[Out]
_______________________________________________________________________________________
Maple [A] time = 0.01, size = 23, normalized size = 1. \[ 2\,\ln \left ( -1+x \right ) -{x}^{-1}-\ln \left ({x}^{2}+1 \right ) +\arctan \left ( x \right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] int((4*x^3+x-1)/(-1+x)/x^2/(x^2+1),x)
[Out]
_______________________________________________________________________________________
Maxima [A] time = 0.893454, size = 30, normalized size = 1.25 \[ -\frac{1}{x} + \arctan \left (x\right ) - \log \left (x^{2} + 1\right ) + 2 \, \log \left (x - 1\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((4*x^3 + x - 1)/((x^2 + 1)*(x - 1)*x^2),x, algorithm="maxima")
[Out]
_______________________________________________________________________________________
Fricas [A] time = 0.274551, size = 35, normalized size = 1.46 \[ \frac{x \arctan \left (x\right ) - x \log \left (x^{2} + 1\right ) + 2 \, x \log \left (x - 1\right ) - 1}{x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((4*x^3 + x - 1)/((x^2 + 1)*(x - 1)*x^2),x, algorithm="fricas")
[Out]
_______________________________________________________________________________________
Sympy [A] time = 0.355072, size = 19, normalized size = 0.79 \[ 2 \log{\left (x - 1 \right )} - \log{\left (x^{2} + 1 \right )} + \operatorname{atan}{\left (x \right )} - \frac{1}{x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((4*x**3+x-1)/(-1+x)/x**2/(x**2+1),x)
[Out]
_______________________________________________________________________________________
GIAC/XCAS [A] time = 0.26134, size = 31, normalized size = 1.29 \[ -\frac{1}{x} + \arctan \left (x\right ) -{\rm ln}\left (x^{2} + 1\right ) + 2 \,{\rm ln}\left ({\left | x - 1 \right |}\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((4*x^3 + x - 1)/((x^2 + 1)*(x - 1)*x^2),x, algorithm="giac")
[Out]