Let $$A= \left[\begin{matrix} a & b & c \\ p & q & r \\ x & y & z \\ \end{matrix} \right]$$ be an idempotent matrix with rank 2. Then the rank of $$B= \left[ \begin{matrix} a-1 & b & c \\ p & q-1 & r \\ x & y & z-1 \\ \end{matrix} \right]$$ is?
Since the matrix $B$ can be written as $B=A-I$. And one of property of idempotent matrix says that the trace of an idempotent matrix = rank of matrix. this implies that $a+q+z=2$? and therefore, rank of $(a-1)+(q-1)+(z-1)=2-3=-1$? But how rank cannot be negative. Where am I going wrong?
Since $A$ is idempotent, then $A^2 = A$. This means that:
$$A^2 - A = 0 \Rightarrow A(A-I) = 0 \Rightarrow AB = 0.$$
For the Sylvester’s rank inequality, we have that:
$$\text{rank}(A) + \text{rank}(B) - n \leq \text{rank}(AB) \Rightarrow \\ 2 + \text{rank}(B) - 3 \leq 0 \Rightarrow\\ \text{rank}(B) \leq 1,$$
where $n=3$ is the dimension of the matrices involved. This means that $\text{rank}(B) = 0$ or $\text{rank}(B) = 1$.
It's clear that $\text{rank}(B) = 0$ if and only if $B = 0$. But in this case, we get:
$$0 = B = A-I \Rightarrow A = I,$$
which is a contradiction because $\text{rank}(A) = 2$. Then, we conclude that $$\text{rank}(B) = 1.$$