# Prove a subspace is separable

Given a Hilbert space $$H$$ and let $$K$$ be a compact set in $$H$$. Let $$X$$ be the smallest closed subspace containing $$K$$. Prove that $$X$$ is separable.

Compact implies that $$K$$ is totally bounded. But how to use this prove $$X$$ is separable? And how to make use of the smallest closed subspace?

• Hint: A compact metric space is separable. – Math1000 Dec 9 '18 at 0:13
• @Math1000 So it suffices to prove that $X$ is compact? would you mind explain a bit more how to prove that? It is not so obvious to me. – whereamI Dec 9 '18 at 0:59
• $X$ won't be compact (it is unbounded). @Math1000 is referring to $K$ being the compact metric space. – user25959 Dec 9 '18 at 1:18
• Reference for the fact that $K$ is separable here: math.stackexchange.com/questions/974233/… – user25959 Dec 9 '18 at 1:18

Once you have proven the hint in the comments, let $$(x_1,x_2,\ldots)$$ be a countable dense sequence of $$K$$. Let $$Q$$ denote the rationals (or if you are working over $$\mathbb{C}$$, the set of complex numbers of the form $$p+qi$$ for $$p,q$$ rational). Observe that the set $$Qx_1 := \{qx_1: q\in Q\}$$ is countable. As is $$Qx_1+Qx_2 := \{u+v:u\in Qx_1, v\in Qx_2\}$$, and more generally, the set $$C:=$$ finite $$Q$$-linear combinations of $$\{x_i\}$$ is countable (this follows because a countable union of countable sets is countable).
Side claim: $$X =$$ closure of set of all finite linear combinations of elements of $$K$$, i.e. $$X=\overline{\{x \in H: x=\sum_{i=1}^{N} \alpha_i k_i \text{ for some } N\in \mathbb{N},\alpha_i\in \mathbb{F},k_i\in K\}}$$ (this is an easy proof).
Now what remains is to show that $$C$$ is dense in $$X$$. You can do this by showing that within $$\varepsilon/2$$ of any $$v\in X$$, there is some $$u=$$ a finite $$\mathbb{F}$$-linear combination of elements of $$K$$; and within $$\varepsilon/2$$ of $$u$$ there is an element $$c$$ of $$C$$.
• Thanks a lot! I forget that the smallest closed subspace can be written as the closure of linear combinations of elements of $K$. – whereamI Dec 9 '18 at 1:22