0

I'm a first year computer science student and I have a question which goes like this: let A be a $n \times n$ matrix $(n \in \mathbb{N})$ such that $A^2 + I = 0$. Prove that $n$ is even.

Now, I came to a conclusion that a matrix of this form can work:

$$ A = \begin{pmatrix} 0 & 0 & \cdots & 0 &-1 \\ 0 & 0 &\cdots & 1 & 0 \\ \vdots & \vdots & \ddots & \vdots & \vdots \\ 1 & 0 & \cdots & 0 & 0 \end{pmatrix} $$

(the degree of this matrix is even obviously) and of course I also tried a version with an odd degree which produced $I$ instead of $-I$. The question is how do I prove that?

Gonçalo
  • 15,869
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community May 22 '24 at 23:39
  • 1
    Welcome to Mathematics Stack Exchange. Can you use properties of determinants? – J. W. Tanner May 22 '24 at 23:44
  • 4
    You probably mean $A$ is a real matrix? If $A$ is allowed to have complex entries, this is definitely not true. For example, if you take $A=i I$, then $A^2+I=0$ regardless of $n$. – AnCar May 22 '24 at 23:59
  • 2
    Why is the degree “even obviously”? – Ted Shifrin May 23 '24 at 01:32

2 Answers2

9

Suppose $A^2+I_n=0$. Then $A^2=-I_n$. If $n$ is odd then $\det(-I_{n})=-1$ so $-1=\det(A^2)=\det(A)^2$ but $\det(A)\in\mathbb{R}$ so $\det(A)^2\ge 0$. This is a contradiction. ($I_n$ is the $n\times n$ identity matrix)

J. W. Tanner
  • 63,683
  • 4
  • 43
  • 88
  • 1
    Or: $A^2=-I_n$ implies $0 \le (\det(A))^2 = \det(A^2) = \det(-I_n) = (-1)^n$ and so $n$ is even. – lhf May 23 '24 at 00:28
0

No no! You have to show it in such a way that it can be called proof and answer for any situation. I mean that the solution you have to provide for these questions should always answer. For example, have it here:

Let $I$ be the identity and $O$ be the zero matrix belongs to $M_n(\mathbb{R})$ (the set of all the $n\times n$ matrices with real entries) and $$A^2 + I = O$$ so, $$A^2=-I$$ and because $det()$ is a function we have $$det(A^2)=det(-I)$$ so let's break the problem and find them! we know that $$det(-I) = \begin{cases}\text{1,} &\quad\text{n is even}\\\text{-1,} &\quad\text{n is odd} \\\end{cases}$$ on the other hand we know that $$det(A^2)=(det(A))^2$$ and by simplifying we have $$(det(A))^2 = \begin{cases}\text{1,} &\quad\text{n is even}\\\text{-1,} &\quad\text{n is odd} \\\end{cases}$$ and in other way $$det(A) = \begin{cases}\ \pm1 &\quad\text{n is even}\\ \pm i &\quad\text{n is odd} \\\end{cases}$$ but here in this case $det()$ is a real function and so at least $n$ must be even so that $det(A)$ be real.