TITLE: When is the determinant a Morse function?
QUESTION [9 upvotes]: This might be ridiculously obvious, but...
For each $n \in \mathbb{N}$, let $M_n$ denote the manifold of $n \times n$ matrices with real entries. It is well known that the $n$-dimensional determinant function $d_n:M_n \to \mathbb{R}$ is a Morse function if and only if $n = 2$ since the zero matrix is a degenerate critical point of $d_n$ whenever $n > 2$. (See the simple homework exercise in this pdf for a proof).
My question is as follows:

For a given $n$, is there a characterization of the sub-manifolds of $M_n$ for which $d_n$ is a Morse function?

Just to be clear, by Morse function I mean that $d_n$ must have:

Isolated critical points (not necessarily finitely many), and
Non-degenerate Hessian at each critical point.

For general subspaces of $M_n$ it seems that the critical set of $d_n$ would not be isolated (one can easily construct examples of critical subspaces), so if there is a Morse-Bott theory for submanifolds of $M_n$ that would be good to know as well.

REPLY [4 votes]: Suppose that $M$ is a manifold, $S$ is a submanifold and $\newcommand{\bR}{\mathbb{R}}$ $f: M\to\bR$ is a smooth function.  Let $T_S^*M\subset T^*M$ be the conormal bundle of $S$.  Let $\Gamma_{df}\subset T^*M$  denote  the graph of the differential of $f$, $df: M\to T^*M$, $\Gamma_{df}=df(M)$.
Then  both $T^*_SM$ and $\Gamma_{df}$ are lagrangian submanifolds of $T^*M$.  The function $f|_S$  is Morse iff the above two Lagrangian submanifolds intersect transversally. For a proof, see page 3 of these notes.