Integration using only two rules and by parts. I need to integrate a few fractions of form $\frac{p(x)}{q(x)}$ where ${p(x)}$ is a polynomial of degree 1 or and $q(x)$ being a polynomial of degree 2 only using integration by parts and following two rules:
$$\int \frac{f'(x)}{f(x)}\, dx = \ln| f(x)|+C$$
$$\int \frac{a}{a^2+x^2}\, dx = \arctan\left(\frac{x}{a}\right)+C$$
Would someone be able to integrate $\frac{3x-1}{x^2-2x+5}$ as an example for me using only these three ways? Thanks in advance.

$$I=\int\frac{3x-1}{x^2-2x+5}$$
$$\int\frac{ 2x-2}{(x-1)^2+4}+\int\frac{ x+1}{(x-1)^2+4}$$
$$\int\frac{( 2x-2)dx}{(x-1)^2+4}+\int\frac{ (z+2)dz}{z^2+4}$$
$$I=\frac 3 2\int\frac{ (2z)dz}{z^2+4}+\int\frac{ 2dz}{z^2+4}$$
Where $z=x-1$
