<s>[INST] $ \int \frac{1}{(x-a)(x+b)} dx $ Could you please explain how to integrate this integral:
$$   \int \frac{1}{(x-a)(x+b)} dx   $$
 [/INST] Since there is linear factor in denominator, 
$$\int \frac{1}{(x-a)(x+b)} dx=\int \frac{1}{(x-a)(a+b)}+\frac{1}{(-b-a)(x+b)} dx$$
Factor out $\frac{1}{a+b}$,
$$=\frac{1}{a+b}\int \frac{1}{x-a}-\frac{1}{x+b} dx$$
The anti-derivatives of $\ln{(x+k)}$ is $\frac{1}{x+k}$
$$=\frac{1}{a+b}\bigg[\ln{(x-a)}-\ln{(x+b)}\bigg]+C$$
Simplify them will give you,
$$=\frac{1}{a+b}\ln{\frac{x-a}{x+b}}+C$$
</s>