[Math] Are there singular matrices such that if we change any entry it will be non-singular

determinantlinear algebramatrices

Prove or disprove: for each natural $n$ there exists an $n \times n$ matrix
with real entries such that its determinant is zero, but if one changes any single
entry one gets a matrix with non-zero determinant.

I think we may be able to construct such matrices.

Best Answer

Choose any matrix with rank $n-1$ that does not have any of the standard unit vectors in its column space.

Added in response to the comment by alex.jordan.

Let $A$ be an $n \times n$ matrix with $rank(A) = n-1$ such that there are vectors $a, \, \tilde a$ with $Aa = 0, \tilde a^T A = 0$ that have all entries $ a_i , \tilde a_i \ne 0$. Then any matrix $B$ that differs from $A$ in exactly one entry has full rank, i.e. $\det B \ne 0$.

To prove this, consider such a $B$. After permuting rows and columns and rescaling, we may assume that $B_{1,1} = A_{1,1} + 1$.

First note that the first column of $A$ is a linear combination of columns $2, \dots, n$, since $Aa = 0$ and $a_1 \ne 0$. The column space of $B$ certainly contains the column space of $A$ and thus $rank(B) \ge n-1$.

If $rank(B) < n$, then $A$ and $B$ must therefore have the same column space. Hence the standard unit vector $e_1$ is in the column space of $A$, that is $Ac = e_1$ for some vector $c$. But then $0 = \tilde a^TAc = \tilde a e_1 = \tilde a_1$, contradicting the assumptions for the left and right null vectors of $A$.

Therefore $rank(B) > n-1$ and $\det B \ne 0$.

Related Question