I'm interested in optimization problems that exhibit no spurious local minimizers. By Lemma 3 in this preprint, this behavior occurs whenever the objective function is the composition of an open map with a convex function. In my application, I'm working with a particular collection of open maps on compact manifolds. When the image is homeomorphic to a closed ball in $\mathbb{R}^n$, I can use the above technology to get nice objective functions: just post-compose with any homeomorphism with any $n$-dimensional convex body before applying any convex function. This suggests the following question:
Question: Is there an invariant that determines whether a given topological space is homeomorphic to a closed ball in $\mathbb{R}^n$?
This question seems fundamental, so I assume the answer is well known. Presumably, every compact $n$-dimensional space with enough trivial homology and homotopy groups is necessarily homeomorphic to a closed ball in $\mathbb{R}^n$. But maybe this isn't easy, since replacing "closed ball" with "sphere" in my question points to the Poincaré conjecture. Is my question the subject of an open problem? Maybe there's an explicit conjectural solution to my question?
Edit: This question is related (and the relationship to Brouwer's fixed-point theorem is interesting), but it doesn't focus on the compact case.