Finding constant to make integrals converge
Solution 1:
The integral is $$I=\int_0^\infty \frac{(3-C)x^2+3x-C}{(x^2+1)(3x+1)}\,dx\ .$$ The integrand is continuous for $x\ge0$, so the only possible problem is the infinite interval. If $C=3$ then the integrand is of the order of $x^{-2}$ and the integral converges. If $C\ne3$ then it is of order $x^{-1}$ and the integral diverges.
Evaluating the integral by standard methods gives $$I=\lim_{A\to\infty}\ln\frac{\sqrt{A^2+1}}{3A+1} =\lim_{A\to\infty}\ln\frac{1+A^{-2}}{3+A^{-1}}=-\ln3\ .$$