Show that: Let $(M,g)$ be a compact Riemannian manifold, then the distance function $r(x) := \operatorname{dist}(x, p)$ can not be smooth on $M$\{$p$}.
(1)As i know, by Hopf-Rinow theorem, $M$ must be complete, however, i don't know how to describe the smooth of distance function. It is easy to show the function is not smooth near $p$ as one can choose normal coordinates around p.... But how about other point? How to deal with that?
(2)If we consider one special case: simply-connected compact Manifold with non-negative sectional curvature, $r^2$ is smooth because of Cartan-Hardmard theorem, why $r$ can not be smooth?