Can you factor a difference of squares in matrices? Is $A^2 - B^2 = (A+B)(A-B)$?

834 Views Asked by At

Can you factorize quadratics like this with matrices?

$$A^2 - B^2 = (A+B)(A-B)$$

I think it's going to be wrong because such a factorization should work even if you switch the order of the terms on the right side, but matrix multiplication isn't commutative.

2

There are 2 best solutions below

0
On BEST ANSWER

$$ A^2-B^2 = (A+B)(A-B) \\ \iff A^2-B^2 = A^2-AB+BA-B^2 \\ \iff AB=BA $$ So, this holds iff $A$ and $B$ commute.

0
On

From the comments so far:

You are right as matrix multiplication isn't commutative, as you have said. $(A + B)(A - B) = A^2 - AB + BA - B^2$, so for this to be true, $AB = BA$ which is not necessarily true.

As a counterexample, take:

$$A = \begin{pmatrix} 1 & 1 \\ 1 & 1\\ \end{pmatrix}, B = \begin{pmatrix} 1 & 1 \\ 0 & 1\\ \end{pmatrix}$$

where:

$$A^2-B^2= \begin{pmatrix} 1 & 0 \\ 2 & 1\\ \end{pmatrix} \text{but } (A+B)(A-B) = \begin{pmatrix} 0 & 0 \\ 1 & 0\\ \end{pmatrix}.$$

However, as matrix addition is commutative, $(A+B)^2 = (B+A)^2$, and likewise $(A-B)^2 = (B-A)^2$. As scalar multiplication distributes and is commutative, $(A-B)(A-B) = (B-A)^2$ by taking out two factors of $-1$.