During the course of looking at the Euler–Mascheroni constant I have run across the following result:
$$\gamma = \int \limits_1^\infty \Bigg( \frac{1}{\lfloor x \rfloor} - \frac{1}{x} \Bigg) \ dx = \int \limits_1^\infty \Bigg( \frac{\lceil x \rceil}{x^2} - \frac{1}{x} \Bigg) \ dx.$$
Representation of this constant using the first integral is a well-known result. What is the simplest way to prove the equivalence of the two integrals?
This is actually easier than it seems, since for any positive integer $k$, \begin{align*} \int_k^{k+1} \bigg( \frac{\lceil x \rceil}{x^2} - \frac{1}{x} \bigg) \, dx &= \int_k^{k+1} \bigg( \frac{k+1}{x^2} - \frac{1}{x} \bigg) \, dx = \frac1k - \log\bigg( 1+\frac1k \bigg) \\ \int_k^{k+1} \bigg( \frac{1}{\lfloor x \rfloor} - \frac{1}{x} \bigg) \, dx &= \int_k^{k+1} \bigg( \frac{1}{k} - \frac{1}{x} \bigg) \, dx = \frac1k - \log\bigg( 1+\frac1k \bigg). \end{align*} Then one can sum both sides over all positive integers $k$ (yielding the Euler–Mascheroni constant as it turns out).