# If $A$, $B$ idempotent and $AB=0$, then $A+B$ idempotent.

We know that if $$A,B$$ idempotent then we have (see edit) $$(A+B)^2=A+B\implies AB=0,$$ and I'm wondering whether the converse, i.e. that if $$A,B$$ idempotent and $$AB=0$$ then $$A+B$$ idempotent is true. Expanding we get $$(A+B)^2=A^2+AB+BA+B^2=A+B+BA$$ so we just need to show that $$BA=0$$. It certainly isn't true in general that $$AB=0\implies BA=0$$, but I couldn't think of an example where $$A$$ and $$B$$ are idempotent. For orthogonal projections at least I think that the statement is true (by thinking geometrically), but I need to consider general projections.

My intuition is that this statement probably is true. Is this correct, and if so how can I show this?

Edit: $$(A+B)^2=A+B\implies AB=-BA$$, but then $$BAB=-BA$$ and $$AB=-BAB$$, so $$AB=BA$$ and therefore $$AB=BA=0$$.

• $\det AB = \det A \cdot \det B = \det B \cdot \det A = \det BA$ since the matrices are square and conformable. $\det A^2 = \det A = \det A\cdot \det A$ so $\det A = 0$ or $1$. Does that help? Commented Apr 27, 2021 at 14:09
• Why do we know that $(A+B)^2=A+B$ implies that $AB=0$? In fact, as you show, only $AB+BA=0$ follows. Commented Apr 27, 2021 at 14:11
• @RobertTheTutor An invertible idempotent must be the identity: $A = AAA^{-1} = AA^{-1} = I$. Commented Apr 27, 2021 at 14:12
• @DietrichBurde A proof is given as an aside in the accepted answer to math.stackexchange.com/questions/1605229/… Commented Apr 27, 2021 at 14:15
• @DietrichBurde I'll edit the question to be more clear here. It isn't an obvious consequence but as saulspatz's link shows, it does follow. Commented Apr 27, 2021 at 14:17

What if $$A =\left(\begin{matrix} 1 & 0 \\ 0 & 0 \end{matrix}\right)$$ and $$B =\left(\begin{matrix} 0 & 0 \\ 1 & 1 \end{matrix}\right)$$?
$$AB = 0$$, but $$BA = \left(\begin{matrix} 0 & 0 \\ 1 & 0 \end{matrix}\right)$$.
And $$A+B = \left(\begin{matrix} 1 & 0 \\ 1 & 1 \end{matrix}\right)$$ is not idempotent since $$(A+B)^2 = \left(\begin{matrix} 1 & 0 \\ 2 & 1 \end{matrix}\right)$$.
Counterexample: Let $$A = \begin{bmatrix} 0 & -1 \\ 0 & 1 \end{bmatrix} \qquad B = \begin{bmatrix} 1 & 0 \\ 0 & 0 \end{bmatrix}$$ Both matrices are idempotent. Then $$AB = 0$$ but $$BA \neq 0$$.
Thinking about this in terms of general projections: $$A$$ projects a vector along a horizontal line to the line $$x = -y$$, while $$B$$ projects along a vertical line to the line $$y = 0$$ (the $$x$$-axis). Applying $$B$$ and then $$A$$ always yields the zero vector, since $$Bv$$ always yields a vector with no $$y$$-component. But applying $$A$$ and then $$B$$ does not necessarily yield the zero vector, since $$Av$$ will usually have a non-zero $$x$$-component.