# For matrices, when does $(A+B)C(D+E)=ACD+ACE+BCD+BCE$ hold? [closed]

I am wondering for the matrices.

If $(A+B)C(D+E)=ACD+ACE+BCD+BCE$ holds?

I think for $(A+B)C = AC+BC$, but how about the above?

## closed as off-topic by amWhy, Frits Veerman, Arnaldo, kingW3, NChJun 22 '17 at 16:11

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question is missing context or other details: Please improve the question by providing additional context, which ideally includes your thoughts on the problem and any attempts you have made to solve it. This information helps others identify where you have difficulties and helps them write answers appropriate to your experience level." – amWhy, Frits Veerman, Arnaldo, kingW3, NCh
If this question can be reworded to fit the rules in the help center, please edit the question.

You are close, but instead of $ABC$ you should have $ACD$. Note that matrix multiplication is associative; combining that with distributivity as you mentioned gives the desired result.

Edit: Please see @Evargalo's important comment below which points out that one should be careful when treating matrices like numbers, as matrix multiplication is not commutative.

• I mention it in a comment because it doesn't deserve a different answer, but the only case where you have to be careful before developing product of matrix "as if they were numbers" is when you have issue with commutativity: for instance $(A+B)(B+A)=A^2+AB+BA+B^2\neq A^2+2AB+B^2$ in general. I suppose it is that kind of issue that caused the OP's extreme prudency ! – Evargalo Jun 21 '17 at 16:26
• @Evargalo this is a very important comment. Thank you for adding it – TomGrubb Jun 21 '17 at 16:27

$$(A+B)C(D+E)=(AC+BC)(D+E)=ACD+ACE+BCD+BCE$$

By the way, $(A+B)C=AC+BC$.

• oh it was my typo. Thank you very much. – Woonghee Lee Jun 21 '17 at 16:25
• No problem. Glad to help. – Alberto Andrenucci Jun 21 '17 at 16:27