# How to prove any closed set in $\mathbb{R}$ is $G_\delta$

Is there a general approach to show that any closed set in $\mathbb{R}$ is $G_\delta$?

To show any open set is $F_\sigma$, the approach is:

1. Show all open intervals are $F_\sigma$
2. Show all open sets are countable disjoint union of open intervals

3. Show all countable union of $F_\sigma$ is $F_\sigma$

Is there an equivalent way of doing this for $G_\sigma$. I could not find a reference to this anywhere.

For a metric space we can do the following: let $A$ be a non-empty subset of $(X,d)$.

Then define $f(x) = d(x,A) = \inf \{d(x,a): a \in A \}$. This is a continuous function from $X$ to $\mathbb{R}$. See this answer, e.g.

When $A$ is also closed, $A$ is exactly the set of all points with $f(x) = 0$. E.g. see this answer.

So $A = f^{-1}[\{0\}] = \cap_n f^{-1}[(-\frac{1}{n},\frac{1}{n})]$ is the countable intersection of open sets.

• Correct me if I'm wrong, but shouldn't you assume that $A$ is a non-empty closed subset of $(X,d)$? – sqtrat May 2 '16 at 11:27
• The first definition is for all $A$, then specialise for closed sets specifically – Henno Brandsma May 2 '16 at 15:03
• Yes, now I agree. – sqtrat May 2 '16 at 17:13

open is $F_\sigma$ $\iff$ closed is $G_\delta$, what prove the claim ! So your approach to show that any open set is $F_\sigma$ gives you automatically the result for closed set are $G_\delta$... what else ?

• But this relies on having proven all opens are $F_\sigma$ first. Is there equivalent ways to show that all closed are $G_\delta$ – Carlos - the Mongoose - Danger Apr 29 '16 at 16:16
• To directly show that any closed set is $G_{\delta}$: Let $C$ be closed and let $n$ be a positive integer. For each $x \in C,$ let $\left(x - \frac{1}{n}, \; x + \frac{1}{n}\right)$ be the open interval of radius $\frac{1}{n}$ with center $x.$ Note that the union of all these open intervals is an open set that contains $C.$ Now take the intersection over all positive integers $n$ of these open sets containing $C.$ This will be a $G_{\delta}$ set (obviously), so your goal will be accomplished if you can show that this $G_{\delta}$ set is equal to $C.$ – Dave L. Renfro Apr 29 '16 at 16:46