Prove that the set $M$ of $n\times n$ matrices with rank $n-1$ is a hypersurface in $\mathbb{R}^{n²}$ and find the tangent space at $A=(a_{ij})$ where $a_{ij}=\begin{cases} \delta_{ij} \ \text{if} \ (i,j)\neq(n,n) \\ 0 \ \ \ \text{if} \ (i,j)=(n,n) \end{cases}$
The teacher left this problem along with others to study for the test (a graduate course in multivariable calculus). If I find a function $f:\mathbb{R}^{n²} \rightarrow \mathbb{R}\in C^1$ such that $M=f^{-1}(c)$ and $grad \ f(x)\neq 0 \ (\forall x;f(x)=c$) do the problem becomes a merely computation but I can't find such function. Can anybody help me?
Thanks in advance.
Call $H \subset \mathbb{R}^{n^2}$ the set of matrices of rank $n-1$. Then the matrix $A$ of the OP belongs to $H$ (obvious). I claim that there is a neighborhood $U \subset \mathbb{R}^{n^2}$ of $A$ such that $U \cap H$ is a smooth hypersurface. To see this let $U$ to be the subset of matrices such that the minor $P$ given by the first $n-1$ rows and $n-1$ columns is different from zero. It is then clear that $U$ is open and $A \in U$. Consider now the restriction $f_U$ to $U$ of the function $f(X):= \det(X)$. Since the minor $P$ is not zero it is not difficult to check that the rank of the differential $df$ is 1 on the whole $U$. So the preimage $f_U^{-1}(0) = U \cap H$ is a hypersurface due to the implicit function theorem. To show that $H$ is a hypersurface at any member $B \in H$ just recall that if $B$ has rank $n-1$ then there are two invertible matrices $n \times n$, say $R,L$, such that $B = R A L$. Then the map $X \to R X L$ is a diffeomorphism of $\mathbb{R}^{n^2}$ which preserves $H$ and take the neighborhood $U$ of $A$, where $H \cap U$ is a hypersurface, to a neighborhood of $B$. So $H$ is also a hypersurface near $B$. Thus $H$ is indeed a smooth hypersurface of $\mathbb{R}^{n^2}$. The tangent space $T_A H$ can be computed by using the derivative formula for the determinant. Namely, if $A(t)=(a_{ij}(t))$ is a smooth curve in $H$ through $A$ at $t=0$ we have $$\frac{d }{dt}\det A(t)|_{t=0} = \frac{d}{dt} a_{nn}(t)|_{t=0} = 0$$ Then the tangent space at $A$ is the set of all $n \times n$ matrix with zero in the $(n,n)$ entry.
Here is another proof that $H$ is a hypersurface without using the implicit function theorem. This proof is in the vein of algebraic geometry. Let $P_{ij}(X)$ be the minor of matrix $X \in \mathbb{R}^{n^2}$ obtained by removing row $i$ and column $j$. Let $U_{ij} := \{ X \in \mathbb{R^{n^2}} : P_{ij}(X) \neq 0 \} $ . Observe that $H \subset \cup_{ij} U_{ij} $. Now we are going to give a parametrization of $H \cap U_{ij}$ by expressing the entry $x_{ij} $ of $X$ as smooth function of the other entries. So take $X \in H \cap U_{ij}$ and notice that by Laplace expansion of $\det(X)$ along the $i$ row give us: $$0 = \det(X) = x_{ij} (-1)^{i+j} P_{ij}(X) + E(X) $$ where $E(X)$ is a polynomial in the entries of $X$ that not contains the entry $x_{ij}$. So $$x_{ij} = (-1)^{i+j+1} \frac{E(X)}{P_{ij}(X)} \, \, (*)$$ which shows that on each $H \cap U_{ij}$ is parameterized by a rational map $$\psi_{ij} : GL(n-1, \mathbb{R}) \times \mathbb{R}^{n-1} \times \mathbb{R}^{n-1} \to H$$ defined as follows. The matrix $\psi_{i,j}(A,v,w)$ reconstructed from $A$ to get all the rows and columns up to the rows $i,j$. the row $i$ up to the entry $i,j$ is the vector $v$ and the column $j$ is the vector $w$. Then the entry $x_{ij}$ is given by the above formula (*) by using $A,v,w$. Now should be clear that $H$ is indeed a hypersurface $\mathbb{R}^{n^2}$.