<s>[INST] Invertibility of a Matrix Given Some Conditions Let $A$ and $B$ be different $n\times n$  matrices with real entries. Suppose that $A^3=B^3$ and $A^2B=B^2A$, can $A^2+B^2$ be invertible?
 [/INST] Let $C = A^2 + B^2$. By assumption, $A-B \neq 0$, but
$$C(A-B) = (A^2+B^2)(A-B) = A^3 + B^2A - A^2B - B^3 = 0,$$
so $C$ is not invertible.
</s>