Prove that $\lim_{n\to\infty}\int_{0}^{1}\cos^n\left(\frac{1}{x}\right)\,dx=0$ Prove that:$$\lim_{n\to\infty}\int_{0}^{1}\cos^n\left(\frac{1}{x}\right)\,dx=0$$
I have a idea about this,but I can't complete proof.
Hint:
We can split the integral into two parts,then estimate the two parts separately.
I tried to let $t=1/x$,but there are many difficulties in the proof.
Any help would be greatly appreciated :-)
 A: Let $\Omega= 1/\pi\mathbb N$.
$$|\cos(1/x)|<1\qquad{x\in (0,1] \setminus \Omega}$$
Also, $\Omega$ is countable, thus its measure is zero.
Hence, $$\lim_{n\to\infty}\int_{(0,1]}\cos^{n}(1/x)dx=\lim_{n\to\infty}\int_{(0,1]\setminus\Omega}\cos^n(1/x)dx$$
By dominated convergence theorem, the integration and the limit can be switched,
$$\lim_{n\to\infty}\int_{(0,1]\setminus\Omega}\cos^n(1/x)dx= \int_{(0,1]\setminus\Omega}\lim_{n\to\infty}\cos^n(1/x)dx=\int_{(0,1]\setminus\Omega}0dx=\color{red}{0}$$ 
Note that the fact $|\cos(1/x)|<1\implies \lim_{n\to\infty}\cos^n(1/x)=0$ is used.
A: This is an elementary proof.
Let $\epsilon, \delta, M > 0$ and divide $[0, 1]$ into intervals as follows: for each $k \in \{1, \ldots, M\}$, consider an interval of length $2\epsilon$ around $\frac1{\pi k}$, and let $I$ be the union of these intervals. Let $J = [0, \delta] - I$ and let $K$ be the rest, the largest portion.
The idea is that, for fixed $\delta$, the $n$th power makes the integral over $K$ small. The integral over $I$ can be bounded trivially by $2M \epsilon$. Finetuning $\epsilon \to 0$ and $M \to \infty$ as $n \to \infty$ should give that the limsup of the integral is at most $\delta$ (the integral of $1$ over $J$). Because $\delta$ is arbitrary, the limit is then $0$.
If you want a hint, you can stop reading here.

Note that $||\cos(y)| - 1| \leq \frac12 y^2$. (Indeed, $|\cos(y)-1| \leq \frac12|\cos^2(y) - 1| = \frac12 \sin^2(y) \leq \frac12 y^2$.) Replacing $y$ by $d(y, \pi \mathbb Z)$ does not change the LHS, so we have $|\cos(y)| \leq 1- \frac12 d(y, \pi \mathbb Z)^2$.
Assume that $(M\pi)^{-1} < \delta$, so that $K$ contains no numbers of the form $(k \pi)^{-1}$. When $x \in K$, we have that $$d(x^{-1}, \pi \mathbb Z) \leq \frac{d(x^{-1}, \pi \mathbb N)}{x^{-1} (x^{-1}-\epsilon)} \leq \frac{\epsilon}{\delta (\delta - \epsilon)}$$
if $\epsilon < \delta$. Suppose $\epsilon < \delta / 2$, then
$$\begin{align*} |\cos^n(1/x)|
& \ll (1-2\epsilon^2\delta^{-2})^n \\
& \leq \exp(-2\epsilon^2 n \delta^{-2})
\end{align*}$$
Hence the integral over $K$ is at most $\exp(-2\epsilon^2 n \delta^{-2})$. The integral over $I$ is, trivially, at most $2 M \epsilon$ (there are $M$ intervals of length $2 \epsilon$) and the integral over $J$ is at most $\delta$. Thus
$$\left| \int_0^1 \cos(1/x)^n dx \right| \leq \exp(-2\epsilon^2 n \delta^{-2}) + 2 M \epsilon + \delta$$
Now choose $\epsilon = n^{-0.02}$, and let $M = \lceil n^{0.01} \rceil$. Then for $\delta$ fixed and $n$ sufficiently large so that $\epsilon < \delta /2$ and $(M\pi)^{-1} < \delta$, we have that
$$\left| \int_0^1 \cos(1/x)^n dx \right|\leq \exp(-2 n^{1.96} \delta^{-2}) + 2 n^{-0.02} \lceil n^{0.01} \rceil + \delta$$
Taking $n \to \infty$ yields
$$\limsup_{n \to \infty} \left|\int_0^1 \cos(1/x)^n dx \right| \leq \delta$$
Thus 
$$\lim_{n \to \infty} \int_0^1 \cos(1/x)^n dx = 0$$
A: Hint: dominated convergence. The limit of $\cos^n(1/x)$ is $0$ almost everywhere (why?).
