How do I integrate this:
$$\int_{1}^{2} \frac{dx}{(x-1)(x^2-2x+5)}$$
This is how I tried:
$$\frac{1}{(x-1)(x^2-2x+5)} = \frac{A}{x-1} + \frac{B+Cx}{x^2-2x+5} \iff 1 = A(x^2-2x+5) + (B+Cx)(x-1)$$
By changing $x$'s to get some terms zero etc. I get $A, B, C$ to be:
$$A= \frac{1}{4}, B = \frac{1}{4}, C = -\frac{1}{4}$$
So now I can rewrite the integral again with terms as :
$$\int_{1}^{2} \left(\frac{1}{4(x-1)} + \frac{1-x}{4(x^2-2x+5)}\right)\,dx $$
As you can see the last term is still not easy to integrate so I do this:
$u = x^2-2x+5$ and then $du = (2x-2) dx = -2(1-x)dx$, $$\int \frac{1-x}{x^2-2x+5} \cdot -2(1-x)dx = \int \frac{1}{-2u}du = \frac{\ln u}2=-\ln\left(\frac{x^2-2x+5}2\right)$$
Now I integrate the entire function and get
$$\frac14 \left[\ln(x-1) - \frac{\ln(x^2-2x+5)}2\right]_{1}^{2}$$
So finally my problem is that when I put $x=1$, I get $\ln0$ which is wrong, so I wonder if I am totally wrong or how to move on?
Let : $$t := x - 1$$ $$\int_{1}^{2} \frac{1}{(x-1)(x^2-2x+5)} dx = \int_{0}^{1} \frac{1}{t(t^2+4)} dt = \frac{1}{4} \int_{0}^{1} \frac{1}{t} - \frac{t}{t^2+4} dt = \frac{1}{4}\left(({\ln(|t|})-\ln({\sqrt{t^2+4}})\right)_0^1 =+\infty $$