\[\sum_{j=a}^{n}f(j)=\int_{a}^{n}f(x)\,\mathrm{d}x+\tfrac{1}{2}f(a)+\tfrac{1}{2}%
f(n)-2\int_{0}^{\infty}\frac{\Im\left(f(a+iy)\right)}{e^{2\pi y}-1}\,\mathrm{d%
}y+\sum_{s=1}^{m}\frac{B_{2s}}{(2s)!}f^{(2s-1)}(n)+2\frac{(-1)^{m}}{(2m)!}\int%
_{0}^{\infty}\Im\left(f^{(2m)}(n+i\vartheta_{n}y)\right)\frac{y^{2m}\,\mathrm{%
d}y}{e^{2\pi y}-1},\]