# Convergence of $\sum_{k=1}^{n} f(k) - \int_{1}^{n} f(x) dx$

I had asked this question sometime ago here. Now I have a question which I think is related to it.

Let $f$ be an increasing function (continuous, of course!) with $f(1)=0$.

Consider the sequence $s_{n}= ( \sum\limits_{k=1}^{n} f(k) - \int\limits_{1}^{n} f(x) dx )$.

When does $s_{n}$ converge?

-
This question seems far too general to me, but en.wikipedia.org/wiki/Euler%E2%80%93Maclaurin_formula is probably relevant. – Qiaochu Yuan Aug 27 '10 at 0:47
@Qiaochu Yuan: Thanks for the link +1 :). – anonymous Aug 27 '10 at 1:26

Qiaochu was on the right track to use an integral-to-sum formula, but it sounds like you want the Abel-Plana summation formula:

$$\lim_{n\to\infty}\left(\sum_{k=m}^n f(k)-\int_m^n f(u)\mathrm{d}u\right)=\frac{f(m)}{2}-\int_{-\infty}^\infty \left(\frac{|t|}{\exp(|2\pi t|)-1}\right)\left(\frac{f(m+it)-f(m-it)}{2it}\right)\mathrm{d}t$$

This is used for instance to evaluate the Stieltjes constants. If the expression on the right hand side is convergent, then it is equivalent to the left hand side.

Definitely $f(z)$ should be analytic, or at least analytic in the region where $\Re z\geq m$. Per Henrici's "Applied and Computational Complex Analysis", the additional conditions are

$$\lim_{t\to\infty}f(u\pm it)=0$$

uniformly in $u$, and that

$$\lim_{t\to\infty}|f(u\pm it)|\exp(\mp 2\pi t)=0$$

uniformly in $u$.

EDIT:

For those scratching their head on just how Abel-Plana and Euler-Maclaurin are connected, the identity

$$\int_{-\infty}^\infty \left(\frac{|t|}{\exp(|2\pi t|)-1}\right)|t|^{2n-2}\mathrm{d}t=\frac{|B_{2n}|}{2n}$$

might be of interest.

-
Mangaldan: So when is the expression on the right hand side convergent! – anonymous Aug 27 '10 at 1:59
@J. Mangaldan: I don't see the need for analyticity. For example, let f be piecewise linear with vertices at (n, 1-exp(-(n-1))) for n = 1, 2, ... . It increases continuously with f(1)=0. The series is obviously bounded and increasing, so the limit exists (and equals 1/2), but f is not analytic. – whuber Aug 27 '10 at 3:04
Hmm... the proof of Abel-Plana in Henrici started with the analyticity assumption. Unfortunately I've not sufficient complex analysis machinery to show that a weaker condition than analyticity can be used. – J. M. Aug 27 '10 at 3:14
@J. M. This is a beautiful formula you have shared with us; thank you. My point above is that it (of course) requires that f be analytic, but the original problem statement imposes no such restriction. Thus this formula can identify some convergent situations but not necessary all. – whuber Dec 14 '10 at 20:42

The question implicitly asks for a "simpler" or "more interesting" criterion for convergence. I doubt there is one. Intuitively, f can do almost anything between (n, f(n)) and (n+1, f(n+1)) provided it is increasing. Thus the terms of (s(n)) can be anything. Convergence therefore is determined by fairly arbitrary properties of f(n) as n becomes arbitrarily large. If you don't severely restrict f--e.g., require it to be analytic or bounded and concave or something like that--you shouldn't expect to find any simpler answer than "(s(n)) converges when it converges."

-

The following theorem (which I read in Number theory: algebraic numbers and functions By Helmut Koch)

$$\sum\limits_{n=1}^{N} g(n) = g(1) + \int\limits_{1}^{N} g(x) \mathrm{d}x + \int\limits_{1}^{N} (x - [x]) g'(x) \mathrm{d}x$$

tells us that the difference converges when $$\int\limits_{1}^{N} (x - [x]) g'(x) \mathrm{d}x$$ does.

-

Note that $$s_{n+1}-s_n =f(n+1)- \int_{n}^{n+1} f(x) dx \,.$$

Let $$a_n:= f(n+1)- \int_{n}^{n+1} f(x) dx = \int_n^{n+1} [f(n+1)-f(x)] dx \,.$$

Then your sequence is exactly the sequence of partial sums of the positive series $$\sum_n a_n \,.$$

When is this convergent? It is convergent if and only if $a_n \to 0$ "fast enough".

Basically your question asks: under what conditions does $\int_n^{n+1} [f(n+1)-f(x)] dx$ converge to zero fast enough so that the corresponding series is absolutely convergent?

Here is a simple condition, but it is probably completelly useless for practical applications: Let $c_n \in (n,n+1)$ be so that $\int_n^{n+1}f(x)dx =f(c_n)$. Then your sequence is convergent if and only if $\sum _n [ f(n+1)-f(c_n)]$ is convergent...

P.S. Probably a better question to ask is the following:

Define $g_n : [0,1] \rightarrow R$ by $g_n(x) = f(n+1)-f(n+1-x)$. Then $g_n$ is continuous on $[0,1]$, increasing and $g_n(0)=0$. Keep in mind that any such $g_n$ lead to an unique $f$ which verifies your conditions.

Then, the question you ask becomes equivalent to the following:

Let $g_n : [0,1] \rightarrow R$ be continuous, increasing and $g_n(0)=0$. Under what extra conditions is

$$\sum_n \left( \int_0^1 g_n(x) dx \right)$$ convergent?

-