I would like to know if there's any equivalence to:
$$\sum_{k=1}^n \frac{1}{k} = \log n + \gamma + \frac{1}{2n} - \sum_{k=1}^\infty \frac{B_{2k}}{2kn^{2k}}$$
But to define $E(n)$ in:
$$\sum_{k=1}^n \frac{1}{k^{1/2}} =2 \sqrt{n} + \zeta(\frac{1}{2}) + \frac{1}{2\sqrt{n}} + E(n)$$
(For $n$ an integer $n>1$)
I would like to express the error term as a sum/series rather than an integral. I did not find anything on the Internet but error terms using big-O notation. The only exact formula I found is:
$$\sum_{k=1}^n \frac{1}{k^{1/2}} = \zeta(\frac{1}{2}) - \zeta (\frac{1}{2}, n+1)$$
I do not know hoy to get from there to $E(x)$. Any help?
Thank you.
According to the Euler-Maclaurin summation formula, we have
$$\sum_{k=1}^n\frac1{\sqrt k}=2\sqrt n+\zeta(1/2)+\frac1{2\sqrt n}+\sum_{k=1}^\infty\frac{B_{2k}}{(2k)!}\binom{-1/2}{2k-1}n^{\frac12-2k}$$
Notice that all the constant terms get turned into $\zeta(1/2)$, which follows since:
$$\zeta(1/2)=\lim_{n\to\infty}\sum_{k=1}^n\frac1{\sqrt k}-\int_0^n\frac1{\sqrt x}\ dx\\\zeta(1/2)=\lim_{n\to\infty}\sum_{k=1}^n\frac1{\sqrt k}-\int_0^n\frac1{\sqrt x}\ dx-\underbrace{\frac1{2\sqrt n}-\sum_{k=1}^\infty\frac{B_{2k}}{(2k)!}\binom{-1/2}{2k-1}n^{\frac12-2k}}_{\to0}$$
Notice the similarity to your other result for $\sum\frac1n$.