Measure and Lebesgue Integral I got this exercise as homework and I found some problems in solving it. So I hope that someone can help me.
Let $f:[0,1] \rightarrow R$ Lebesgue measurable and $S=\{x \in [0,1]:f(x) \in Z\}$.
Show that:
$\lambda(S)=\lim_{n \rightarrow \infty} \int_0^1 \lvert \cos(\pi f(x))\rvert^n \,d\lambda$
 A: Hint: What is the limit of $\lvert\cos(\pi f(x))\rvert^n$ as $n\to\infty$?
A: Try splitting your integral over two sets: $\{\delta<f<1-\delta\}$ and its complement.
A: Let $f_n(x):=|\cos(\pi f(x))|$: it's a measurable function, the sequence $\{f_n(x)\}$ is decreasing for all $x$ and converges to $g:=\chi_S(x)$ for all $x$. Apply monotone convergence theorem to $g-f_n$ to get the wanted result. 
A: I'm going to sum up a complete answer:  
$\lambda(S)={x \in [0,1]:f(x) \in Z}$
considering : $\lim_{n \rightarrow \infty} \int_0^1 \vert \cos(\pi f(x))\vert^n d\lambda$
 so $0 \leq \vert \cos(\pi f(x))\vert^n \leq 1$.
If $\vert \cos(\pi f(x))\vert=1$ it means that $f(x)=2k,2k+1\qquad k \in N \forall x \in [0,1]$ so $\lim_{n \rightarrow \infty} \int_0^1 \vert \cos(\pi f(x))\vert^n d\lambda=\int_0^1 1 d\lambda=1$  
At the same time if $f(x)=2k,2k+1\qquad k \in N \forall x \in [0,1]$ it means that $2k,2k+1 \in Z$ and so $\lambda(S)=\lambda([0,1])=1$.    
If $\vert\cos(\pi f(x))\vert \neq 1$ you get $\lim_{n \rightarrow \infty} \int_0^1 \vert \cos(\pi f(x))\vert^n d\lambda=\int_0^1  d\lambda=0$ and in this case S has cardinality as maximum numerable so it could be considered as union of singletons of null measure since we get that S has measure zero too.
So I can use this convergence to apply the monotone convergenze theorem to $g-f_n$ as suggested by Davide Giraudo.
