[Math] Open Set is $G_{\delta}$ set

analysisfunctional-analysisgeneral-topology

In any metric space prove that every open set is $G_{\delta}$ set and every closed set is $F_{\sigma}$ set.(Hint: use the continuity of $x\longmapsto d(x,A)$.)

I tried to prove this by saying: If $U$ is a open set, consider $\bigcup_{i=0}^{\infty} A_{n}$, where $A_{n}=\bigcup_{x\in U} B(x,1+1/n)$ and $A_{0}=U$.

Hence every Open set is $G_{\delta}$ set.

Also I didn't get how to use the hint to solve the problem.
Thanks in advance.

Best Answer

You must have switched things. There is no need for metrizability to prove that open sets are $G_\delta$, nor that closed sets are $F_\sigma$--both of these follow immediately from the definitions of $G_\delta$ and $F_\sigma$.

Now, since a set is $G_\delta$ if and only if its complement is $F_\sigma$, and closed if and only if its complement is open, then we need only prove that every closed set in a metric space is $G_\delta$.

Take any closed set $A$ in a metric space $X$. Let $f(x)=d(x,A)$, so continuity of $f$ means that preimages of open sets are open. In particular, for each integer $n\geq 1$, let $A_n$ be the preimage of $(-1/n,1/n)$. The intersection of all the $A_n$ is then precisely the set of all $x\in X$ such that $f(x)=d(x,A)=0$. Since $A$ is closed, then $d(x,A)=0$ if and only if $x\in A$. Thus, $A=\bigcap_{n=1}^\infty A_n$, so $A$ is $G_\delta$.