How do I calculate the following example: $$(\lambda A-I)(\lambda A-I)$$
where A is any $n\,x\,n$ matrix of the same size as $I$? Do I multiply as regular algebra or what?
Is is: $$(\lambda A)^2-2\lambda A + I$$
Why, why not?
Edit: Or for the example $$(A-2BC)(A-2BC)$$
where $A, B, C$ are three $3\,x\,3$ matrices.
Matrix multiplication is distributive but since order matters you have to be careful not to commute any of the elements. Lets look at the example $(A-B)(C-D)$ since it's more general and assume all the matrices are square. We can do this two ways. First we can calculate $$(A-B)(C-D)=(A-B)C -(A-B)D=\\AC-BC-(AD-BD)=AC-BC-AD+BD$$
Or we could have distributed the other way with $$(A-B)(C-D)=A(C-D)-B(C-D)=\\AC-AD-(BC-BD)=AC-AD-BC+BD$$
And we can see by inspection that they are the same regardless of our choice in left or right distributivity.