TITLE: If $x\notin\mathbb{Q}$, then $\left|x-\frac{p}{q}\right|<\frac{1}{q^{2+\epsilon}}$ for infinitely many $\frac{p}{q}$?
QUESTION [6 upvotes]: This appears on Problem 1 of Chapter 1 in Stein & Shakarchi's Real Analysis:

Given an irrational $x$, one can show (using the pigeon-hole principle, for example) that there are infinitely many fractions $p/q$, with relatively prime integers $p$ and $q$ such that $$\left|x-\frac{p}{q}\right|\leq\frac{1}{q^2}.$$
  However, prove that the set of all $x\in\mathbb R$ such that there exist infinitely many fractions $p/q$, with relatively prime integers $p$ and $q$ such that $$\left|x-\frac{p}{q}\right|\leq\frac{1}{q^{3}} \text{ (or} \leq 1/q^{\epsilon+2})$$ is a set of measure zero.

By the hint, I am trying to prove this using the Borel-Cantelli lemma. As my family of countable sets, I'm considering $E_{q} = \{x : \exists p. |x - p/q| < 1/q^{2+\epsilon} \}$.
I'm having trouble showing that the sum of the measures of $E_{q}$ converges. I can show that $E_q$ is the union of intervals of length $2/q^{2 + \epsilon}$, but I can't put a bound on the total number of intervals because the problem statement says $x \in \mathbb{R}$ so $p$ could be arbitrarily large.
I found a similar problem statement in this question, but there the bound comes from the fact that $x \in [0,1]$.
Am I considering the wrong family of sets for this problem, mis-interpreting the problem statement, or encountering some other issue?

REPLY [2 votes]: As @user172377 has pointed out, there is a problem in @clark's answer. The same $q_i$ in fact should appear an infinite number of times in the sum, because there are an infinite number of $p$'s that are relative primes to $q_i$. We need to also interate over these $p$'s, for each $q_i$.
(Furthermore, @clark's argument would have worked for $\epsilon=0$. But we know it's not true.)
Instead, we can focus on the intervals $[i,i+1)$, where $i$ is an integer, one at a time.
Define $E_{i,q} \equiv E_q \cap [i,i+1)$. You can show that $\cup_q E_{i,q}$ has measure 0 for each $i$. Therefore $\cup_i (\cup_q E_q)$ also has measure zero by Theorem 3.2 in Stein and Shakarchi.