Multiplication of Matrices

Key Questions

• Matrix multiplication is an operation performed upon two (or sometimes more) matrices, with the result being another matrix.

This explanation will assume the student is familiar with the basics of matrices, such as matrix notation and vector dot products.

There are certain rules which must be followed in the multiplication process. First, when multiplying any two matrices ${A}_{r s}$ and ${B}_{t u}$, where $r$ and $t$ are the number of rows in matrices A & B respectively and $s$ and $u$ the number of columns in matrices A & B respectively, if $s \ne t$ (that is, the number of rows in $A$ does not equal the number of columns in $B$), the matrix multiplication cannot be carried out.

When multiplying two matrices such as this, the resultant matrix $A B$ will possess $r$ rows and $u$ columns; in other words, the same number of rows as the $A$ matrix and the same number of columns as the $B$ matrix.

Each entry in the $A B$ matrix will be calculated via the dot product of a row from the $A$ matrix and a column from the $B$ matrix. Renaming the $A B$ matrix as $C$ for ease of use, the value of any individual element ${c}_{i} j$ can be found by taking the dot product of row $i$ from $A$ and column $j$ from $B$.

There is currently some difficulty in utilizing Socratic's math code to construct a matrix, so different notation must be used temporarily. Consider the 2x3 matrix $A$, such that ${a}_{11} = 1 , {a}_{12} = 0 , {a}_{13} = 3 , {a}_{21} = 0 , {a}_{22} = 5 , {a}_{23} = - 1$, as well as the 3x2 matrix $B$ such that ${b}_{11} = 4 , {b}_{12} = 5 , {b}_{21} = 0 , {b}_{22} = - 3 , {b}_{31} = - 4 , {b}_{32} = 1$. Then the resultant matrix $A B = C$ is a 2x2 matrix, with
${c}_{11} = \left({a}_{11} \cdot {b}_{11}\right) + \left({a}_{12} \cdot {b}_{21}\right) + \left({a}_{13} \cdot {b}_{31}\right)$,
${c}_{12} = \left({a}_{11} \cdot {b}_{12}\right) + \left({a}_{12} \cdot {b}_{22}\right) + \left({a}_{13} \cdot {b}_{32}\right) ,$
${c}_{21} = \left({a}_{21} \cdot {b}_{11}\right) + \left({a}_{22} \cdot {b}_{21}\right) + \left({a}_{23} \cdot {b}_{31}\right) ,$
${c}_{22} = \left({a}_{21} \cdot {b}_{12}\right) + \left({a}_{22} + {b}_{22}\right) + \left({a}_{23} + {b}_{32}\right)$

Plugging in the respective values, we get ${c}_{11} = - 8 , {c}_{12} = 8 , {c}_{21} = 4 , {c}_{22} = - 16$

• There is some information on Multiplication of Matrices here on Socratic.

I think of it as a process that is easier to explain in person, but I'll do my best here.

Let's go through an example:

$\left(\begin{matrix}1 & 2 \\ 3 & 4\end{matrix}\right) \left(\begin{matrix}3 & 5 \\ 7 & 11\end{matrix}\right)$

Find the first row of the product

Take the first row of $\left(\begin{matrix}1 & 2 \\ 3 & 4\end{matrix}\right)$, and make it vertical in front of $\left(\begin{matrix}3 & 5 \\ 7 & 11\end{matrix}\right)$. (We'll do the same for the second row in a minute.)

It looks like:

$\left.\begin{matrix}1 \\ 2\end{matrix}\right. \left(\begin{matrix}3 & 5 \\ 7 & 11\end{matrix}\right)$

Now multiply times the first column and add to get the first number in the first row of the answer:
$\left.\begin{matrix}1 \times 3 \\ 2 \times 7\end{matrix}\right. = \left.\begin{matrix}3 \\ 14\end{matrix}\right.$ now add to get $17$

The product starts with:
$\left(\begin{matrix}17 & \text{-" \\ "-" & "-}\end{matrix}\right)$

Next multiply times the second column and add to get the second number in the first row of the answer:
$\left.\begin{matrix}1 \times 5 \\ 2 \times 11\end{matrix}\right. = \left.\begin{matrix}5 \\ 22\end{matrix}\right.$ now add to get $27$

The first row of the product is: $\left(\left(17 , 27\right)\right)$

A this point we know that the product looks like:

$\left(\begin{matrix}1 & 2 \\ 3 & 4\end{matrix}\right) \left(\begin{matrix}3 & 5 \\ 7 & 11\end{matrix}\right) = \left(\begin{matrix}17 & 27 \\ \text{-" & "-}\end{matrix}\right)$

Find the second row of the product
Find the second row of the product by the same process using the second row of $\left(\begin{matrix}1 & 2 \\ 3 & 4\end{matrix}\right)$

$\left.\begin{matrix}3 \\ 4\end{matrix}\right. \left(\begin{matrix}3 & 5 \\ 7 & 11\end{matrix}\right)$ to get: $9 + 28 = 37$ and $15 + 44 = 59$

The second row of the product is: $\left(\left(37 , 59\right)\right)$

$\left(\begin{matrix}1 & 2 \\ 3 & 4\end{matrix}\right) \left(\begin{matrix}3 & 5 \\ 7 & 11\end{matrix}\right) = \left(\begin{matrix}17 & 27 \\ 37 & 59\end{matrix}\right)$

• Simply the multiplication of a scalar (generally a real number) by a matrix.

The multiplication of a matriz $M$ of entries ${m}_{i j}$ by a scalar $a$ is defined as the matrix of entries $a {m}_{i j}$ and is denoted $a M$.

Example:

Take the matrix

$A = \left(\begin{matrix}3 & 14 \\ - 4 & 2\end{matrix}\right)$

and the scalar $b = 4$

Then, the product $b A$ of the scalar $b$ and the matrix $A$ is the matrix

$b A = \left(\begin{matrix}12 & 56 \\ - 16 & 8\end{matrix}\right)$

This operation has very simple properties that are analogous to that of the real numbers.