# Is $[0,1] \cap \Bbb Q$ a compact subset of $\Bbb Q$?

Is $[0,1] \cap \Bbb Q$ a compact subset of $\Bbb Q$? I get the feeling it isn't compact, but I can't figure out a way to prove this. I understand that, in $\Bbb Q$, any open set $U = \Bbb Q \cap O_i$ such that $O_i \subseteq R$. But I can't figure out a way to construct a finite set that doesn't contain the intersection set.

Compact spaces have the property that they are closed in any Hausdorff superspace. Since ${\bf R}$ is Hausdorff and $[0,1]\cap {\bf Q}$ is not closed in ${\bf R}$, it cannot be compact.

To see that directly, you do the same as you would with, say $[0,1]\setminus \{\sqrt{1/2}\}$.

A set in a metric space is compact iff it's complete and totally bounded. $\Bbb{Q}\cap [0,1]$ is not complete.

Let $$r$$ be an irrational number in $$[0,1]$$. There exists $$N \in \mathbb{N}$$ such that $$\frac{1}{N} \leq \min\{r, 1-r\} = \text{dist}\big(r, \mathbb{R}\backslash [0,1]\big).$$ The sets $$U_n := \left(-1, r-\frac{1}{n}\right) \cup \left( r+ \frac{1}{n}, 2\right),~~~~~n \geq N$$ are open. The collection of $$U_n$$ forms an open covering of $$[0,1] \cap \mathbb{Q}$$ with no finite sub-covering. Hence $$[0,1] \cap \mathbb{Q}$$ is not compact in $$\mathbb{Q}$$.

A set is sequentially compact if every sequence contained in the set have a subsequence that converges to a point of the set.

Because the set proposed is only composed of rational numbers then any sequence that converges to some irrational number doesn't have any subsequence that converges to a point of the set (because for convergent sequences every subsequence converges to the same point).

Well, let's figure it out knowing it can't be true.

In R a set is compact iff it is closed and bounded. [0,1] restricted to Q is bounded but it isn't closed. (Which is enough... we are done. But ...yeah, I know, it doesn't feel we are done. It'd feel better if we could find an open cover that has no finite cover.)

Well, let's find a limit point of [0,1] restricted that isn't in the set. Well, that'd be any irrational $x; 0 <x <1$. Let's make an open cover that "tends" toward x in a "limit pointy sort of way".

Oh, all right ... I'll out and say it. Let's use the 1/n to get open sets that come within 1/n of x. As x is a limit point, these will get arbitrarily close to x and cover all but x. But as x isn't in the set it will cover the set.

Okay, let's formalize that.

Let $U_n = (-\infty, x -1/n)\cup (x+1/n,\infty)$. This collection $\{U_n\}$ is an open cover as it covers everything but $x$ which wasn't in the set to begin with. Any finite subcollection, $\{U_{n_i}\}$ will have an $m=\max (n_i)$ and so $[x-1/m,x+1/m]\cap [0,1]\cap \mathbb Q \subset [0,1]\cap \mathbb Q$ will not be covered.

So that's an open cover with no finite subcover.

• Oh, this is basically what Masacroso posted while I was typing. – fleablood May 31 '16 at 20:54

This is a particular case of a more general affirmation, namely: Every compact set in $\mathbb{Q}$ has an empty interior.

To prove this use the fact that in any open interval $(a,b)\subseteq\mathbb{R}$ there is a sequence of rationals converging to an irrational (which will of course contain no subsequence converging to a rational), and recall that in any compact space every sequence contains a convergent subsquence.