# the rationals as a metric space, closed and open sets

If we consider the rationals, $\mathbb{Q}$, as a metric space with the usual metric of the real line, then is the set $B=\{q\in\mathbb{Q} \mid {q^2}\lt 2\}$ a closed set? I know the definition of a closed set is a set that contains all its limit points. And I understand that here $\sqrt{2}$ is a limit point but it's not in our set but it's also not in the rationals so it's not in our metric space at all. Then, does $B$ contain all its limit points?

Alternatively, we can say $B$ every point in $B$ is an interior point (has a neighbourhood contained in $B$) so that makes $B$ open.

So then is $B$ both open and closed?

Thanks

• Yes, $[-\sqrt2,\sqrt2]\cap\Bbb Q$ is both an open and closed set, considered as a subset of $\Bbb Q$. Commented Oct 18, 2015 at 15:47

## 3 Answers

You must have proved that a set is open in the induced metric iff it is the intersection of an open set with the subspace, and the analogous statement holds for closed sets (note that this is the definition of induced topology, if you know topology).

Since we have that $B=[-\sqrt2, \sqrt 2] \cap \mathbb{Q}=(-\sqrt{2}, \sqrt{2}) \cap \mathbb{Q}$, it follows that $B$ is closed (by the first equality) and open (by the last).

let $x$ in the complementary of the set, $x^2\geq 2$, thus $x\geq \sqrt(2)$, since $x\in Q$, $x>\sqrt(2)$ and there exist $\sqrt(2)<y<x$ since $Q$ is dense in $R$, $]y,+\infty[$ is in the complementary of $\{q^2<2\}$ and is an open neighborhood of $x$ in the complementary of $\{q^2<2\}$. Thus this complementary is henceforth open.

If $\sqrt 2$ doesn't exist in our metric space, it doesn't exist in our metric space. $\sqrt 2$ is not a limit point because it doesn't exist in our metric space any more.

Consider this theorem. If A is open (or closed) in metric space X, then A intersect B is open (or closed) in metric space B intersect X.

If B = [0,1] U [2, 3] U ...., then A = [0, 1] is open. The points 1 and 0 are now interior points.