1. ## Topology

Let (X,d) be a metric space. X is said to be separable if there is a countable set Q contained in X such that Q is dense in X. Show that a separable metric space has a basis for its open sets consisting of a countable family of open sets.

I started by establishing the open ball B(q,1/n) where n = 1,2,...

I know I want to show that every open set is a union of these sets.

I'm not sure where to go from here. Any help would be great!

2. You're going to the good direction. Make a drawing in the case of metric space (IRē,||.||).

I know I want to show that every open set is a union of these sets.
in fact you need show it just for the open balls because the open balls form a basis of your metric space.

3. Let $\displaystyle O$ be an open set. We will prove that every $\displaystyle x$ in $\displaystyle O$ belongs to an open ball $\displaystyle B(q_{x},\frac{1}{n_{x}})$ with $\displaystyle q_{x} \in Q$ and $\displaystyle n_{x} \in \mathbb{N}$.
We know there exists $\displaystyle y \in X$, $\displaystyle r>0$ such that $\displaystyle x \in B(y,r)$, so $\displaystyle d(y,x)<r$.
We will note $\displaystyle \epsilon=r-d(x,y)$

Let $\displaystyle n$ be an integer such that $\displaystyle \frac{1}{n}<\frac{\epsilon}{2}$. Since $\displaystyle Q$ is dense in $\displaystyle X$, there is a $\displaystyle q_{x} \in Q\cap B(x,\frac{1}{n})$.

At this point, just visualize the scene, and try to conclude.