I need to show that $$ \lim_{n\to+\infty}\frac{1}{n}\sum_{k=1}^nf(2\pi k \gamma)=\int_T f(t)\,dt. $$
Here $\gamma$ is any irrational number on the real line and $f(t)$ is any continuous periodic function defined on $T = [-π, π]$.
I have to show this equality, but I have absolutely no idea how to approach...I can't even figure out the reason why $\gamma$ has to be irrational.
Could anyone please help me with this problem?
First, as pointed out in the comments above, the right hand side needs a factor of $(2\pi)^{-1}$. With that in mind, here we go.
Let's pick our favorite $2\pi$ periodic functions. Namely, for $j=0,1,2,\dots$ let $f_j(x)=e^{ijx}$ (where $i$ is the imaginary constant). Now let's see if the equality holds for these functions. For $j=0$, it is easy to see that both sides equal $1$. The hard case is $j\neq 0$. I'll leave it to you to check that the following holds for $j\neq0$: $$ \int_{-\pi}^\pi e^{ijx}=0. $$ Now consider the partial sums on the left hand side. We have $$ \frac{1}{N}\sum_{k=1}^N e^{2\pi i k\gamma j}=e^{2\pi i\gamma j}\frac{1-e^{2\pi i N\gamma j}}{N(1-e^{2\pi i\gamma j})} $$ Let us consider $$ \lim_{N\to\infty}\frac{1-e^{2\pi i N\gamma j}}{N(1-e^{2\pi i\gamma j})} $$ As the function $e^{ijx}$ is periodic, the numerator is bounded in magnitude, as $$ |e^{2\pi i N\gamma j}|\leq \sup_{y\in T} |e^{ijy}|. $$ Moreover, as $\gamma$ is irrational, $j\gamma$ is never an integer for $j=1,2,\dots$ meaning that $$ 1-e^{2\pi i \gamma j}\neq 0. $$ Therefore we get $$ \lim_{N\to\infty}\frac{1-e^{2\pi i N\gamma j}}{N(1-e^{2\pi i\gamma j})}=0 $$ and working back through we can see that this implies $$ \lim_{N\to\infty}\frac{1}{N}\sum_{k=1}^N e^{2\pi i k\gamma j}=0 $$ as desired.
So we have shown that the identity holds for all $f_j(x)$. By linearity of the sums and integrals, we can see that it will hold for any trigonometric polynomial, i.e. any function that can be written as $$ \sum_{j=0}a_jf_j(x) $$ for some scalars $a_j$. Now we are in luck, because we can approximate all continuous functions arbitrarily well using trigonometric polynomials. Can you use the Stone-Weierstrass approximation to go from here? If not, let me know and I can add a detailed follow up :)
Edit: finishing the problem.
Let $\epsilon>0$, and let $f(x)$ be an arbitrary function meeting your restrictions. Using Stone-Weierstrass, we can find a trig polynomial $g(x)$ such that $$ \sup_{y}|f(y)-g(y)|<\epsilon/2. $$ Now consider $$ \left|\lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^nf(2\pi k\gamma)-\frac{1}{2\pi}\int_{-\pi}^\pi f(t)dt\right|. $$ Using the fact that the equality holds for our trig polynomial, this is equal to $$ \left|\lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^nf(2\pi k\gamma)-\lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^ng(2\pi k\gamma)+\frac{1}{2\pi}\int_{-\pi}^\pi g(t)dt-\frac{1}{2\pi}\int_{-\pi}^\pi f(t)dt\right|. $$ Using the triangle inequality, we can bound this by $$ \left|\lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^nf(2\pi k\gamma)-\lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^ng(2\pi k\gamma)\right|+\left|\frac{1}{2\pi}\int_{-\pi}^\pi g(t)dt-\frac{1}{2\pi}\int_{-\pi}^\pi f(t)dt\right|, $$ or equivalently $$ \left|\lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^n[f(2\pi k\gamma)-g(2\pi k\gamma)]\right|+\left|\frac{1}{2\pi}\int_{-\pi}^\pi [g(t)-f(t)]dt\right|. $$ This can now be bounded by $$ \lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^n|f(2\pi k\gamma)-g(2\pi k\gamma)|+\frac{1}{2\pi}\int_{-\pi}^\pi |g(t)-f(t)|dt $$ which in turn is bounded by $$ \lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^n\sup_{y}|f(y)-g(y)|+\frac{1}{2\pi}\int_{-\pi}^\pi\sup_{y}|f(y)-g(y)|. $$ By choice of our trig polynomial, this is less than $$ \lim_{n\to\infty}\frac{1}{n}\sum_{k=1}^n\epsilon/2+\frac{1}{2\pi}\int_{-\pi}^\pi\epsilon/2=\epsilon. $$
Now take $\epsilon$ to zero.