# How do you multiply #((-2, -5, 3), (3, -1, 2), (1, 4, -2))# with #((1, 4, 3), (-3, -3, 2), (-2, -1, -2))#?

##### 1 Answer

The formal definition of matrix multiplication is:

#c_(ik) = sum_(i,j,k) a_(ij)b_(jk)# where

#a,b,c# are entries in the matrices#A,B,C# , respectively, and#AB = C# . That means if#A# is#I xx J# and#B# is#J xx K# , then#C# is#I xx K# .

Let the first and second indices indicate the row and column, respectively, for matrices

If you take the **sum of the dot products of a GIVEN row** **in** **with each column in**

That means:

- Multiply row 1 in
#A# with column 1 in#B# . This entry goes in#c_(11)# . - Multiply row 1 in
#A# with column 2 in#B# . This entry goes in#c_(12)# . - Multiply row 1 in
#A# with column 3 in#B# . This entry goes in#c_(13)# . - Multiply row 2 in
#A# with column 1 in#B# . This entry goes in#c_(21)# . - Multiply row 2 in
#A# with column 2 in#B# . This entry goes in#c_(22)# . - Multiply row 2 in
#A# with column 3 in#B# . This entry goes in#c_(23)# . - Multiply row 3 in
#A# with column 1 in#B# . This entry goes in#c_(31)# . - Multiply row 3 in
#A# with column 2 in#B# . This entry goes in#c_(32)# . - Multiply row 3 in
#A# with column 3 in#B# . This entry goes in#c_(33)# .

This gives another

#color(blue)(C) = AB#

#= [(-2, -5, 3), (3, -1, 2), (1, 4, -2)]xx[(1, 4, 3), (-3, -3, 2), (-2, -1, -2)]#

#[(sum_j a_(1j)b_(j1),sum_j a_(1j)b_(j2),sum_j a_(1j)b_(j3)),(sum_j a_(2j)b_(j1),sum_j a_(2j)b_(j2),sum_j a_(2j)b_(j3)),(sum_j a_(3j)b_(j1),sum_j a_(3j)b_(j2),sum_j a_(3j)b_(j3))]#

#[(-2*1 - 5*-3 - 3*2,-2*4-5*-3-1*3,-2*3-5*2-3*2),(3*1-1*-3-2*2,3*4-1*-3-1*2,3*3-1*2-2*2),(1*1-4*3-2*-2,1*4-3*4-1*-2,1*3+2*4-2*-2)]#

#[(-2 + 15 - 6,-8 + 15 - 3,-6 - 10 - 6),(3 + 3 - 4,12 + 3 - 2,9-2-4),(1 - 12 + 4,4 - 12 + 2,3 + 8 + 4)]#

#color(blue)([(7,4,-22),(2,13,3),(-7,-6,15)])#