Disjoint compact sets in a Hausdorff space can be separated I want to show that any two disjoint compact sets in a Hausdorff space $X$ can be separated by disjoint open sets. Can you please let me know if the following is correct? Not for homework, just studying for a midterm. I'm trying to improve my writing too.
My work:
Let $C$,$D$ be disjoint compact sets in a Hausdorff space $X$. Now fix $y \in D$ and for each $x \in C$ we can find (using Hausdorffness) disjoint open sets $U_{x}(y)$ and $V_{x}(y)$ such that $x \in U_{x}(y)$ and $y \in V_{x}(y)$. Now the collection $\{U_{x}: x \in C\}$ covers $C$ so by compactness we can find some natural k such that
$C \subseteq \bigcup_{i=1}^{k} U_{x_{i}}(y)$ 
Now for simplicity let $U = \bigcup_{i=1}^{k} U_{x_{i}}(y)$, then $C \subseteq U$ and let $W(y) = \bigcap_{i=1}^{k} V_{x_{i}}(y)$. Then $W(y)$ is a neighborhood of $y$ and disjoint from $U$.
Now consider the collection $\{W(y): y \in D\}$, this covers D so by compactness we can find some natural q such that $D \subseteq \bigcup_{j=1}^{q} W_{y_{j}}$.
Finally set $V = \bigcup_{j=1}^{q} W_{y_{j}}$, then $U$ and $V$ are disjoint open sets containing $C$ and $D$ respectively. 
What do you think?
 A: First prove the lemma:

Let $X$ be Hausdorff and $A$ be compact and $p \notin A$. Then there exist open sets $U$ and $V$ such that $A \subseteq U$, $p \in V$ and $U \cap V = \emptyset$.

The proof follows your idea: for each $a \in A$ we pick $U(a)$ open and $V(a)$ open and disjoint such that $a \in U(a), p \in V(a)$ by Hausdorffness.
The $\{U(a): a \in A\}$ cover $A$ by construction so by compactness of $A$, we have finitely many $a_1, \ldots a_n$ such that 
$$A \subseteq U:=\bigcup_{i=1}^n U(a_i)$$
and as we have finitely many corresponding $V(a_i)$ as well, $p \in V:= \bigcap_{i=1}^n V(a_i)$ which is then open. And no point is in $U \cap V$ or it would be in some $U(a_i)$ (from $U$ being a union) and also in the same $V(a_i)$ ($V$ being the intersection), contradicting how they were chosen. So $U$ and $V$ are as required. QED for the lemma.
Now apply the lemma repeatedly for $c \in C$ and $D$ when these are disjoint compact. We get $U(c)$ and $V(c)$ disjoint neighbourhoods of $c$ and $D$ (!) now, compactness lets us take a finite union of $U(c)$ as $U$ and the corresponding intersection of $V(c)$'s will work again, same argument essentially.
So in two steps is cleanest. Make the inbetween step visible.
A: This is a very good start, but there is a slight problem with your argument: as you change $y$, your $U$ changes as well (since $U$ is constructed in terms of $y$); you should really call it $U(y)$. 
Your construction gives you an open neighborhood $W(y)$ of $y$ for each $y$; $W(y)$ is disjoint from $U(y)$. But for all you know, $W(y)$ may fail to be disjoint from $U(y')$ with $y'\neq y$.
So you really still have a bit more to go before you are done. 
A: $U=⋃k_i=Ux_i(y)$ might meet $V$, so to avoid this problem use compactness of the second set. I think if your prove is completely correct, we don't need to suppose compactness of the two. and we consider simply $V=⋃w(y)$; $y$ in $D$
