Finding the derivative of function f (x) = (x ^ 2-5x + 6) / (x ^ 2 + 1)~

Finding the derivative of function f (x) = (x ^ 2-5x + 6) / (x ^ 2 + 1)~

f(x)
=1+(-5x+5)/(x^2+1)
∴f'(x)=0+[-5(x^2+1)-2x(-5x+5)]/(x^2+1)^2
=5(x^2-2x-1)/(x^2+1)^2