Prove that $\lim_{N\rightarrow\infty}(1/N)\sum_{n=1}^N f(nx)=\int_{0}^1f(t)dt$ Suppose $f$ is continuous and periodic on the reals with period 1. Prove that if $x\in[0,1]$ is an irrational number, then
$$\lim_{N\rightarrow\infty}\frac{1}{N}\sum_{n=1}^N f(nx)=\int_{0}^1f(t)dt$$ 
Suggestion: First consider $f(t) = e^{2\pi(ikt)}$ where k is an integer. 
I can see that this is a limit of a weighted average, but the suggestion throws me off. I've seen the suggestion in fourier transforms but it's not clicking at the moment. Any help would be welcome.
 A: Using the hint you were given, it is easy to verify that
$$
  \int_0^1 e^{2\pi i k t} \, \mathrm{d}t = \left\{ 
      \begin{array}{lr}
         1 & :\  k = 0 \\
         0 & :\  k \neq 0
      \end{array}
   \right.
$$
Similarly, for $k \neq 0$ and irrational $x [0,1]$, using geometric series
$$
\begin{align*}
   \lim_{N \to \infty} \frac{1}{N} \left| \sum_{n=1}^N e^{2 \pi i k n x} \right| &= \lim_{N \to \infty} \frac{1}{N} \left| e^{2 \pi i k x} \frac{e^{2 \pi i k N x} - 1}{e^{2 \pi i k x} - 1} \right| \\
   &\leq \lim_{N \to \infty} \frac{1}{N} \frac{2}{|e^{2 \pi i k x} - 1|} \\
   &= 0
\end{align*}
$$
noting that since $x$ is irrational $e^{2 \pi i k x} \neq 1$ for any $k \neq 0$. On the other hand, for $k = 0$ we have $e^0 = 1$, so
$$
   \lim_{N \to \infty} \frac{1}{N} \sum_{n = 1}^N 1 = 1.
$$
It follows that
$$
   \lim_{N \to \infty} \frac{1}{N} \sum_{n = 1}^N e^{2 \pi i k n x} = \int_0^1 e^{2 \pi i k t} \, \mathrm{d}t.
$$
Now for any continuous function $f$ on $\mathbb{R}$ with period $1$, there is a sequence of complex numbers $\{c_k\}_{-\infty}^\infty$ such that
$$
   f(t) = \sum_{k = -\infty}^\infty c_k e^{2 \pi i k t}.
$$
So with a little justification of the interchange between sum and integral,
$$
\begin{align*}
   \int_0^1 f(t) \, \mathrm{d}t &= \int_0^1 \sum_{k = -\infty}^\infty c_k e^{2 \pi i k t} \, \mathrm{d}t \\
   &= \sum_{k = -\infty}^\infty c_k \int_0^1 e^{2 \pi i k t} = c_0.
\end{align*}
$$
And correspondingly, for irrational $x \in [0,1]$,
$$
\begin{align*}
   \lim_{N \to \infty} \frac{1}{N} \sum_{n = 1}^N f(n x) &= \lim_{N \to \infty} \frac{1}{N} \sum_{n = 1}^N \sum_{k = -\infty}^\infty c_k e^{2 \pi i k n x} \\
   &= \sum_{k = -\infty}^\infty c_k \lim_{N \to \infty} \frac{1}{N} \sum_{n = 1}^N e^{2 \pi i k n x} \\
   &= c_0.
\end{align*}
$$
It follows that
$$
   \lim_{N \to \infty} \frac{1}{N} \sum_{n = 1}^N f(n x) = \int_0^1 f(t)\, \mathrm{d}t.
$$
A: Here's a sketch of another way to try to do it, if for some odd reason you don't want to try the better way using Stone-Weierstrass.
Assume that you have the conclusion of the hint, as demonstrated in the previous answer.
Consider the family of functions, for $N = 1, 2, 3, \dots$
$$
h_N(t)
= \frac{1}{N}\{ f(t+\alpha) + f(t+2\alpha) + \dots + f(t+N\alpha) \}
- \int_0^1 f(t)\ dt
$$
Using the hint, show that the sequence
$$\widehat{h_N}(k) = \int_0^1 h_N(t)\ dt$$
converges to $0$ in $l^2(\mathbb{Z})$.
We know $l^2(\mathbb{Z})$ and $L^2([0, 1])$ are Hilbert space isometric, because the trigonometric polynomials are dense in $L^2([0, 1])$, and so it follows that $h_N$ converges to $0$ in $L^2([0, 1])$.
We have to show that in fact this yields pointwise convergence, which is general not true but in this case is because of the continuity of $f$.
Here's an easy fact to verify: Suppose you have a sequence and a value, such that every subsequence has a sub-subsequence which converges to that value. Then, the original sequence also converges to that value.
Pick $t_*$ in $[0, 1]$, and pick an arbitrary subsequence of $\{h_N(t_*)\}$.
The corresponding subsequence of $\{h_N\}$ converges in $L^2$ to $0$, since $\{h_N\}$ itself does.
We know from $L^2$-space theory that there is a sub-subsequence which converges pointwise almost everywhere to $0$.  
There are a couple of different ways to proceed from here. One way is to notice that the sub-subsequence of $\{h_N\}$ is equicontinuous. Then you can apply Arzela's theorem to find a sub-sub-subsequence which converges uniformly to a continuous limit function $\phi(t)$ on $[0, 1]$.
By Dominated Convergece, this sub-sub-subsequence also converges in $L^2$ to $\phi$.
So, $\phi$ equals $0$ almost everywhere, and by continuity they are in fact equal everywhere.
The upshot is that $\phi(t) = 0$ for all $t$, so for our arbitrary $t_*$ and our arbitrary subsequence of $\{h_N(t_*)\}$, we found a sub-sub-subsequence which converges pointwise at $t_*$ to $0$.
So $\{h_N(t_*)\}$ converges to $0$, but $t_*$ was arbitrary so $\{h_N(t)\}$ converges to $0$ for every $t$.
Choosing $t = 0$ gives the result we are looking for.
