TITLE: How to show $\sum_{n=2}^N g\left(\frac{1}{n}\right)\frac{n}{N} \rightarrow g'(0) $?
QUESTION [6 upvotes]: For any smooth function $g$ that satisfies $g(0)=0$, the following weirdly seems to hold:
$$\sum_{n=2}^N g\left(\frac{1}{n}\right)\frac{n}{N} \rightarrow g'(0) $$ as $N \rightarrow \infty$
Can anyone explain or prove?

REPLY [4 votes]: From the definition of the derivative, we have
$$g(x) = g(0) + g'(0)x + xr(x)= g'(0)x + xr(x),$$ where $\lim_{x\to 0} r(x) = 0.$ Thus
$$\sum_{n=1}^{N}g(1/n)(n/N) = \sum_{n=1}^{N}[g'(0)(1/n) + (1/n)r(1/n)](n/N) = g'(0) + (1/N)\sum_{n=1}^{N}r(1/n).$$
Because $r(1/n)\to 0$ as $n\to \infty,$ the Cesaro means of this sequence $\to 0,$ which is the same as saying $(1/N)\sum_{n=1}^{N}r(1/n) \to 0,$ giving the result.