# Locally compact metric space

I'm trying to prove that a metric space is locally compact iff every closed ball is compact, using the more general definition that applies to Hausdorff spaces, that every point has a compact neighbourhood. So call $X$ my space. The only non trivial thing to prove is that every closed ball is compact, assuming $X$ is locally compact. So consider $N$ a compact neighbourhood of some $x\in X$. Then as a neighbourhood, it contains $B(x,r)$ for some $r$. So it contains $\bar{B}(x,r/2)$. This is closed inside $N$ which is compact, so it's also compact. So I've proven that at any point there is a compact closed neighbourhood ball. Surely it's not too hard to prove all the bigger closed balls are compact ?

• This is not true. Consider $\mathbb{R}$ with a metric $d(x, y) = min(1, |x - y|)$. It generates the regular topology on $\mathbb{R}$, but the closed ball $B(0, 2) = \mathbb{R}$ is clearly not compact. – xyzzyz Oct 10 '16 at 18:42
• This is not true. For instance, let us consider in $R$ the distance $d(x,y):=|x-y|\wedge 1$. This distant induces the usual topology. However, any ball with radious grater than $1$ is all the space, which is not compact. – user178826 Oct 10 '16 at 18:45
• I have just seen, that xyzzyz posted the same answer before me. – user178826 Oct 10 '16 at 18:46
• The correct theorem is "if $X$ is a complete locally compact geodesic metric space then every closed metric ball in $X$ is compact. This is a form of the classical Hopf-Rinow theorem from Riemannian geometry. A metric space is geodesic if between any pair of points there is a path whose length is the distance between the points. – Moishe Kohan Oct 13 '16 at 16:14

Consider $R^2-\{(0,0)\}$ endowed with the canonical metric, it is locally compact. But $B((0,1);2)$ is not compact.
But the result is true if $X$ is endowed with a norm.