$$\displaystyle\int_1^{\infty}\frac{\{x\}-\frac{1}{2}}{x}\ \mathrm dx$$
where $\{x\}$ denotes the fractional part of x (for example- $\{3.141\}=0.141)$
I'm looking for alternative methods (maybe also ones which are shorter) to what I already know (method I have used below), to Evaluate this.
The only method I know:
$$\ln(n!)=\sum_{k=2}^{n} \ln k$$
$$\ln(n!)=\sum_{k=2}^{n} \color{brown}{\int_1^k \frac{dx}{x}}$$
Since: $$\color{brown}{\int_1^k \frac{dx}{x}}=\sum_{j=1}^{k-1} \int_j^{j+1} \frac{dx}{x}$$
$$\ln(n!)=\sum_{k=2}^{n} {\Bigg\{\sum_{j=1}^{k-1} \int_j^{j+1} \frac{dx}{x}}\Bigg\}$$
$$\ln(n!)=(n-1)\int_1^2 \frac{dx}{x}+(n-2)\int_2^3 \frac{dx}{x}+\cdots+\int_{n-1}^n \frac{dx}{x}$$
$$ln(n!)=\int_1^2 \frac{(n-1) dx}{x}+\int_2^3 \frac{(n-2)dx}{x}+\cdots+\int_{n-1}^n \frac{dx}{x}$$
The general form of the terms in the last summation is, with $1\leq j\leq n-1$
$$\int_j^{j+1} \frac{(n-j)}{x}dx=\int_j^{j+1} \frac{(n-[x])}{x} dx$$
where the notation $[x]$ means the integer part of $x$
because, for the integration interval $j\leq x <j+1$
$$\ln(n!)=\int_1^n \frac{n-[x]}{x} dx$$
Now :
$$x=[x]+\{x\}\implies[x]=x-\{x\}$$
$$\Large{\color{orange}{\ln(n!)}} = \int_1^n \frac{n-x+\{x\}}{x}dx=n\ln(n)-n+1+\int_1^n \frac{\{x\}}{x}dx$$
$$=n\ln(n)-n+1+\frac{1}{2}\ln(n)+\int_1^n \frac{\{x\}-\frac{1}{2}}{x}dx$$ $$\left(n+\frac{1}{2}\right)\ln(n)-n+1+\int_1^n \frac{\{x\}-\frac{1}{2}}{x} dx$$
$$=\ln\left(n^{n+\frac{1}{2}}\right)+\ln(e^{-n})+1+\int_1^n \frac{\{x\}-\frac{1}{2}}{x} dx$$
$$=\ln\left(e^{-n}n^{n+\frac{1}{2}}\right)+\ln\left(e^{1+\int_1^n \frac{\{x\}-\frac{1}{2}}{x}dx}\right)$$
$$=\color{crimson}{\Large{\ln\left(e^{-n}n^{n+\frac{1}{2}}e^{1+\int_1^n \frac{\{x\}-\frac{1}{2}}{x}dx}\right)}}$$
$$\Large{\color{orange}{n!}=\color{Crimson}{e^{-n}n^{n+\frac{1}{2}}e^{1+\int_1^n \frac{\{x\}-\frac{1}{2}}{x}dx}}}$$
$$\Large{e^{1+\int_1^n \frac{\{x\}-\frac{1}{2}}{x}dx}=\frac{n!}{e^{-n}n^{n+\frac{1}{2}}}}$$
If we let $n\to \infty$ And using Stirling's formula, we have:
$$\Large{e^{1+\int_1^{\infty} \frac{\{x\}-\frac{1}{2}}{x}dx}}=\sqrt{2\pi}$$
Thus, $$1+\int_1^{\infty} \frac{\{x\}-\frac{1}{2}}{x}dx=\ln(\sqrt{2\pi})$$
$$\bbox[8pt,border:2px #0099FF solid]{\int_1^{\infty}\frac{\{x\}-\frac{1}{2}}{x} dx=-1+\ln(\sqrt{2\pi})}$$