Let $A,B$ be $n\times n$ matrix
If $(A^2)(B^2) = (B^2)(A^2)$ , is $AB=BA$?
Let $A,B$ be $n\times n$ matrix
If $(A^2)(B^2) = (B^2)(A^2)$ , is $AB=BA$?
It is not true in general that $A^2B^2=B^2A^2$ implies $AB=BA$. For example let $$A = \begin{pmatrix} 0 & 1 \\ 0 & 0 \end{pmatrix} \quad \text{and} \quad B = \begin{pmatrix} 0 & 0 \\ 1 & 0 \end{pmatrix}$$
No, just take the matrix (hope no miscalculations)
$ A = \bigg(\begin{array}{ll} 0 & 1 \\ 0 & 0 \end{array}\bigg) $ and $ B = \bigg(\begin{array}{ll} 0 & 0 \\1 & 0 \end{array}\bigg) $