# Proof that difference of compact and closed sets is also closed [duplicate]

This question already has an answer here:

I am trying to prove that for any $A$ compact, $B$ closed sets $\Rightarrow A-B = \{a-b | a\in A, b\in B\}$ is also closed, where A and B are subsets of a topological vector space $X$.

## marked as duplicate by saz, user147263, Mark Bennet, 6005, André NicolasJan 2 '15 at 19:53

This result holds for any Hausdorff topological group $G$. Indeed, let $c\in G\setminus AB^{-1}$ be an arbitrary point. It follows that the sets $cB$ and $A$ are disjoint. For every point $x\in A$ there exists a neighborhood $V(x)$ of the unit such that $V(x)x\cap cB=\varnothing$. Let $U(x)$ be a neighborhood of the unit such that $U(x)^2\subset V(x)$. There exists a finite family $\mathcal X$ such that $A\subset\bigcup\{U(x)x:x\in\mathcal X\}$. Put $U=\bigcap\{U(x):x\in\mathcal X\}$. Then $$UA\cap cB\subset U\bigcup\{U(x)x:x\in\mathcal X\}\cap cB \subset \bigcup\{U(x)^2x:x\in\mathcal X\}\cap cB=\varnothing.$$ Then $U^{-1}c$ is a neighborhood of the point $c$, which does not intersect with the set $AB^{-1}$