# In a non-Hausdorff space, can a compact subset fail to be closed?

In a Hausdorff space $X$, every compact subset $Y$ is closed. So if I relax the condition on $X$ being Hausdorff, is it possible compact subset $Y$ of $X$ not being closed?

-
The word "question' is redundant in titles. Please try writing better titles in the future. – ᴡᴏʀᴅs Aug 14 '14 at 0:28
Finite sets are always compact, in any topology, but need not be closed. – MJD Aug 14 '14 at 0:44
For any non-empty topological space $Y$, compact or not, we can topologize $X=Y\cup \{\ast\}$ so that $Y$ is a non-closed subspace of $X$. – Slade May 29 '15 at 19:12

For sure. Consider $X = \{a, b\}$ with topology $\tau = \{\emptyset, \{a\}, X\}$. Note that $(X, \tau)$ is not Hausdorff and that $\{a\}$ is compact (the open covers for $\{a\}$ are already finite), but not closed.

-
+1 for elegant simplicity. – triple_sec Aug 13 '14 at 23:57

Yes. Take a compact Hausdorff space with topology $\tau$ and weaken the topology, i.e. take any topology $\tau'$ strictly weaker than $\tau$, so that there is some set $U$ that is open in topology $\tau$ but not in $\tau'$.
But $U^c$ is still compact in $\tau'$ (because any open cover for $\tau'$ is still an open cover for $\tau$). So $U^c$ is a compact set that is not closed for topology $\tau'$.

-

Yes, it's possible. Let $X=(-1,1)\cup\{0'\}$, where the point $0'$ is a distinct “copy” of the point $0$. Let $\tau$ be the topology on $X$ generated by the sets $(-1,a)$, $(a,1)$, $((-1,b)\setminus\{0\})\cup\{0'\}$, and $((c,1)\setminus\{0\})\cup\{0'\}$, where $a\in(-1,1)$, $b\in(0,1)$, and $c\in(-1,0)$.

This topology is not Hausdorff and the set $[-1/2,1/2]$ is compact but not closed.

-