# Two matrices $A$ and $B$ with $AB+BA=0$

Question: There are two matrices $$A$$ and $$B$$ of order $$3\times3$$ with $$AB+BA=0$$, then is it necessary that $$AB=0$$?

I tried this problem but couldn't reach any conclusive answer. I didn't see any reason for $$AB=0$$, then I tried to get some counterexample. I couldn't find it.

Please give me some counterexample if it exists. Also, please tell me how you reached there? I suppose it is not just a matter to attempt with two matrices by trial only. There should be some thought process to find such matrices.

In case if you find $$AB=0$$, please prove it.

Thank you.

Take the following matrices: $$A=\begin{pmatrix} -1 & 0 & 0 \cr 0 & 0 & 0 \cr 0 & 0 & 1\end{pmatrix},\; B=\begin{pmatrix} 0 & 0 & 0 \cr 0 & 0 & 0 \cr 1 & 0 & 0\end{pmatrix}.$$ Then $$AB+BA=B-B=0$$ and $$AB=B\neq 0.$$ The idea is to take a diagonal matrix for $$A$$ and a nonzero matrix $$B$$ with $$AB=B$$ and $$BA=-B$$.

Let $$A=\begin{bmatrix}0 & 1 & 0\\ 1 & 0 & 0\\ 0 & 0 & 0 \end{bmatrix}$$, $$B=diag(1,-1,0)$$

$$AB=\begin{bmatrix}0 & -1 & 0\\ 1 & 0 & 0\\ 0 & 0 & 0 \end{bmatrix}$$

and $$BA=\begin{bmatrix}0 & 1 & 0\\ -1 & 0 & 0\\ 0 & 0 & 0 \end{bmatrix}$$

We have then found a counterexample.

I use a permutation matrix and play with the $$2$$ by $$2$$ case first before working on the $$3$$ by $$3$$ case.

Hint: embed the Pauli-Matrices $$\sigma_x$$ and $$\sigma_z$$ in the wanted space...

EDIT: in general this is called an anti-commutative property.

Suppose the entries of the matrices are taken from a field of characteristic $$\ne2$$. Let $$X=A+B$$ and $$Y=A-B$$. Then the statement $$AB+BA=0$$ is equivalent to $$X^2=Y^2$$, and the statement that $$AB=0$$ is equivalent to $$XY=YX$$.

So, to construct a counter-example, it suffices to find a pair of non-commuting matrices $$X,Y$$ such that $$X^2=Y^2$$. This is easy. E.g. Siong Thye Goh’s answer can be obtained by putting $$X=\pmatrix{0&2&0\\ 0&0&0\\ 0&0&0}, \ Y=\pmatrix{0&0&0\\ 2&0&0\\ 0&0&0}, \ A=\pmatrix{0&1&0\\ 1&0&0\\ 0&0&0}, \ B=\pmatrix{0&1&0\\ -1&0&0\\ 0&0&0},$$ while the answer by Dietrich Burde (up to permutations of rows and columns) may be obtained by putting $$X=\pmatrix{1&1&0\\ 0&-1&0\\ 0&0&0}, \ Y=\pmatrix{1&-1&0\\ 0&-1&0\\ 0&0&0}, \ A=\pmatrix{1&0&0\\ 0&-1&0\\ 0&0&0}, \ B=\pmatrix{0&1&0\\ 0&0&0\\ 0&0&0}.$$ By carefully picking $$X$$ and $$Y$$, one may obtain a counter-example with a nice but rather non-trivial appearance. E.g. take two pairs of linearly independent real integer vectors $$\{u,x\}$$ and $$\{v,y\}$$ such that $$\langle u,v\rangle=\langle x,y\rangle=0\ne\langle x,v\rangle$$. Put $$X=2uv^T$$ and $$Y=2xy^T$$. Then $$X^2=Y^2=0$$ but $$XY\ne YX$$. Hence $$A=\frac12(X+Y)=uv^T+xy^T$$ and $$B=\frac12(X-Y)=uv^T-xy^T$$ constitute a counterexample. E.g. $$u=\pmatrix{1\\ 1\\ 1}, \ v=\pmatrix{1\\ 2\\ -3}, \ x=\pmatrix{2\\ 3\\ 5}, \ y=\pmatrix{1\\ 1\\ -1}, \ A=\pmatrix{3&4&-5\\ 4&5&-6\\ 6&7&-8}, \ B=\pmatrix{-1&0&-1\\ -2&-1&0\\ -4&-3&2}.$$

Hint: take $$B$$ non-zero that is conjugate to $$-B$$. Possibilities: $$B$$ with eigenvalues $$-1$$, $$0$$, $$1$$. Or $$B$$ a $$3\times 3$$ Jordan cell corresponding to $$\lambda=0$$. So there exists $$A$$ ( can be found explicitly) such that $$A B A^{-1} = -B$$