Matrices such that $M^2+M^T=I_n$ are invertible

Let $M$ be an $n\times n$ real matrix such that $M^2+M^T=I_n$. Prove that $M$ is invertible

Here is my progress:

  • Playing with determinant:

one has $\det(M^2)=\det(I_n-M^T)$ hence $\det(M)^2=\det(I_n-M)$

and $\det(M^T)=\det(I_n-M^2)$, hence $\det(M)=\det(I_n-M)\det(I_n+M)$

Combining both equalities yield $$\det(I_n-M)(\det(I_n-M)\det(I_n+M)-1)=0$$

  • Playing with the original assumption:

transposing yields $(M^T)^2+M=I_n$, and combining gives $(M^2-I_n)^2=I_n-M$

that is $M^4-2M^2+M=0$.

$M$ is therefore diagonalizable and its eigenvalues lie in the set $\{0,1,-\frac{1+\sqrt{5}}{2},\frac{1-\sqrt{5}}{2}\}$

  • Misc

Multiplying $M^2+M^T=I_n$ by $M$ in two different ways, one has $MM^T=M^TM$

  • Looking for a contradiction ?

Supposing $M$ is not invertible, there is some $X$ such that $MX=0$. This in turn implies $M^TX=X$... So what ?


suppose $Mx = 0.$ then multiplying $$M^2 + M^T = I$$ on the left by $x,$ we get $$M^T x = x. \tag 1$$ again multiply $(1)$ by $M$ on the left gives $$MM^T x = 0 \tag 2 $$ multiplying (2) by $x^T$ on the left gives $$ 0 =x^T M M^T x = (M^\top x)^T (M^T x) = |M^T x|^2 \to M^Tx = 0 \tag 3$$ together with $(1)$ impies $x = 0.$ that is $$ Mx = 0 \implies x = 0.$$ that is equivalent to $M$ being invertible.


as a footnote, just to look at the simplest cases:

in dimension 1 $m^2 + m - 1=0$ so $m=\frac12(-1 \pm \sqrt{5})$

in 2 dimensions, set $M=\begin{pmatrix} a & b \\c & d \end{pmatrix}$ so $$ M^{\mathrm{T}}=\begin{pmatrix} a & c \\b & d \end{pmatrix} $$ and $$ M^2 = \begin{pmatrix} a^2+bc & b(a+d) \\c(a+d) & d^2+bc \end{pmatrix} $$ so the matrix condition $M^2+M^{\mathrm{T}}=I$ gives the conditions: $$ a^2+bc +a =1 \\ d^2+bc +d = 1 \\ b(a+d)+c= 0 \\ c(a+d)+b=0 $$ since $a$ and $d$ are both roots of $x^2+x+(bc-1)=0$ we require $ad=bc-1$ hence $$ |M|=-1 $$ and $M$ is non-singular.

since we also have $a+d=-1$ this forces $b=c$ and we obtain a 1-parameter family of solutions: $$ a,d=\frac12 \left(-1\pm\sqrt{5-4b^2} \right) $$


We can find explicitly the real matrices $M$ that satisfies $M^2+M^*=I$. According to the DODOM's post, $M$ is a normal matrix, and consequently, is diagonalizable over $\mathbb{C}$ by a unitary change of basis. Then $M=Pdiag((m_i)_i)P^{-1}$ where, for every $i$, $m_i^2+\overline{m_i}=1$. Since $M$ is real, there is a unitary $P$ s.t. $M=Pdiag(\lambda_1,\cdots,\lambda_k,p_1+iq_1,p_1-iq_1,\cdots,p_r+iqr,p_r-iq_r)P^{-1}$ where $n=k+2r$ and the $(\lambda_j,p_s,q_s\not=0)$ are real; morover $\lambda_j^2+\lambda_j=1$ (that implies $\lambda_j=(-1\pm\sqrt{5})/2)$ and $p_s^2-q_s^2+p_s+i(2p_sq_s-q_s)=1$ (that implies $p_s=1/2,q_s^2=-1/4$, that has no solutions).

Finally, there is an orthogonal matrix $Q$ s.t. $M=Qdiag(((-1+\sqrt{5})/2)I_p,((-1-\sqrt{5})/2)I_q)Q^{-1}$ where $p+q=n$. Note that $M$ is necessarily symmetric.


This problem statement

Let $M$ be an $n\times n$ real matrix such that $M^2+M^T=I_n$. Prove that $M$ is invertible

is actually a special case of a much more general assertion, which is in fact just about as easy to prove:

Let $p(x) = \sum_0^m p_i x^i \in \Bbb C[x]$ be a complex polynomial with non-vanishing constant coefficient $p_0$, and $M$ be an $n \times n$ complex matrix satisfying $ M^\dagger = p(M)$. Then $M$ is invertible.

We prove this as follows:

Suppose $M$ is not invertible. Then there is some non-zero vector $v \in \Bbb C^n$ with

$Mv = 0; \tag{1}$

it follows that

$M^\dagger v = p(M)v = \sum_0^m p_i M^iv = p_0 v; \tag{2}$

thus, taking the (hermitian) inner product of each side with $v$:

$\langle v, M^\dagger v \rangle = \langle v, p_0 v \rangle, \tag{3}$

whence, using (1),

$0 = \langle Mv, v \rangle = p_0\langle v, v \rangle \ne 0; \tag{3}$

this contradiction shows that (1) cannot bind for $v \ne 0$. Hence, $\ker M = 0$ and $M$ is invertible. QED.

If we now take $M$ real and $p(x) = 1 - x^2$ the specific problem at hand is solved.