4. Matrix Algebra

Matrix Multiplication

Matrix Multiplication

students, have you ever wondered how two tables of numbers can combine to make a third table that describes a new real-world process? 📊 Matrix multiplication is one of the most important ideas in linear algebra because it lets us combine transformations, solve systems efficiently, and model situations like computer graphics, economics, and data flow. In this lesson, you will learn the meaning of matrix multiplication, how to compute it correctly, why the dimensions matter, and how it fits into the bigger picture of matrix algebra.

By the end of this lesson, you should be able to:

  • Explain the main ideas and terminology behind matrix multiplication.
  • Apply procedures for multiplying matrices.
  • Connect matrix multiplication to other ideas in matrix algebra.
  • Describe why matrix multiplication is useful in real applications.

What Matrix Multiplication Means

A matrix is a rectangular arrangement of numbers. If a matrix has $m$ rows and $n$ columns, we say its size is $m \times n$. Matrix multiplication is a way to combine two matrices to create a new matrix, but it does not work the same way as regular number multiplication. In ordinary arithmetic, $2\times 3$ and $3\times 2$ are the same product value. With matrices, the order matters, and the product may change when the order changes. 🔄

To multiply a matrix $A$ by a matrix $B$, the number of columns in $A$ must equal the number of rows in $B$. If $A$ is $m \times n$ and $B$ is $n \times p$, then the product $AB$ is defined and will be an $m \times p$ matrix.

This rule is important because each entry in the product comes from combining a row of $A$ with a column of $B$. You can think of it like this: one matrix provides the “instructions” from the row side, and the other matrix provides the “data” from the column side.

For example, if $A$ is $2 \times 3$ and $B$ is $3 \times 4$, then $AB$ is possible and the result will be $2 \times 4$. But $BA$ would require the number of columns of $B$ to equal the number of rows of $A$, and since $4 \neq 2$, that product is not defined.

How to Compute a Matrix Product

The entry in row $i$ and column $j$ of the product $AB$ is found by taking the dot product of row $i$ of $A$ and column $j$ of $B$. The dot product means multiply matching entries and add the results.

If

$$

$A = \begin{bmatrix}$

a_{11} & a_{12} & $\cdots$ & a_{1n} \\

a_{21} & a_{22} & $\cdots$ & a_{2n} \\

$\vdots$ & $\vdots$ & $\ddots$ & $\vdots$ \\

a_{m1} & a_{m2} & $\cdots$ & a_{mn}

$\end{bmatrix}$

$$

and

$$

$B = \begin{bmatrix}$

b_{11} & b_{12} & $\cdots$ & b_{1p} \\

b_{21} & b_{22} & $\cdots$ & b_{2p} \\

$\vdots$ & $\vdots$ & $\ddots$ & $\vdots$ \\

b_{n1} & b_{n2} & $\cdots$ & b_{np}

$\end{bmatrix},$

$$

then the product $AB = C$ has entries

$$

$ c_{ij} = \sum_{k=1}^{n} a_{ik}b_{kj}.$

$$

That formula may look advanced, but it simply says: pair up the numbers in row $i$ of $A$ with the numbers in column $j$ of $B$, multiply them, and add them up.

Let’s do a small example.

$$

A = $\begin{bmatrix} 1$ & 2 \ 3 & $4 \end{bmatrix}$, \quad B = $\begin{bmatrix} 5$ & 6 \ 7 & $8 \end{bmatrix}$

$$

To find $AB$, compute each entry:

  • Top left: $1\cdot 5 + 2\cdot 7 = 19$
  • Top right: $1\cdot 6 + 2\cdot 8 = 22$
  • Bottom left: $3\cdot 5 + 4\cdot 7 = 43$
  • Bottom right: $3\cdot 6 + 4\cdot 8 = 50$

So,

$$

AB = $\begin{bmatrix} 19$ & 22 \ 43 & $50 \end{bmatrix}$.

$$

Notice that multiplying matrices requires careful organization. A common mistake is trying to multiply corresponding entries position by position. That is not matrix multiplication. For matrices, the row-column rule must be followed. âś…

Why the Order Matters

One of the most surprising facts about matrix multiplication is that it is usually not commutative. That means in general,

$$

$AB \neq BA.$

$$

This is very different from real numbers, where $2\cdot 3 = 3\cdot 2$. With matrices, switching the order can change the result or make the product undefined.

Here is a quick example:

$$

A = $\begin{bmatrix} 1$ & 2 \ 0 & $1 \end{bmatrix}$, \quad B = $\begin{bmatrix} 2$ & 0 \ 1 & $3 \end{bmatrix}$

$$

Compute $AB$:

$$

$AB = \begin{bmatrix}$

$1\cdot 2$ + $2\cdot 1$ & $1\cdot 0$ + $2\cdot 3$ \\

$0\cdot 2$ + $1\cdot 1$ & $0\cdot 0$ + $1\cdot 3$

$\end{bmatrix}$

= $\begin{bmatrix} 4$ & 6 \ 1 & $3 \end{bmatrix}$.

$$

Now compute $BA$:

$$

$BA = \begin{bmatrix}$

$2\cdot 1$ + $0\cdot 0$ & $2\cdot 2$ + $0\cdot 1$ \\

$1\cdot 1$ + $3\cdot 0$ & $1\cdot 2$ + $3\cdot 1$

$\end{bmatrix}$

= $\begin{bmatrix} 2$ & 4 \ 1 & $5 \end{bmatrix}$.

$$

The answers are different, so order matters. This property helps explain why matrix multiplication can represent sequences of actions. For example, if one matrix rotates a shape and another stretches it, doing the stretch first and the rotation second may give a different outcome than doing them in the opposite order.

Identity, Zero, and Associative Properties

Matrix algebra has some useful rules that help organize calculations.

The identity matrix plays the role of $1$ in ordinary multiplication. For a square matrix of size $n \times n$, the identity matrix is $I_n$, with $1$’s on the main diagonal and $0$’s elsewhere. For any compatible matrix $A$,

$$

AI = A \quad \text{and} \quad IA = A.

$$

For example, if

$$

I_2 = $\begin{bmatrix} 1$ & 0 \ 0 & $1 \end{bmatrix}$,

$$

then multiplying any $2 \times 2$ matrix by $I_2$ leaves it unchanged.

The zero matrix contains only zeros. If $0$ is a zero matrix of the correct size, then

$$

A0 = 0 \quad \text{and} \quad 0A = 0.

$$

Another important rule is associativity:

$$

$(AB)C = A(BC).$

$$

This means that when multiplying three matrices, the grouping does not change the final result, as long as the products are defined. However, the order of the matrices still matters. Associativity helps people compute products in a way that is easier or more efficient.

Matrix multiplication is also distributive over addition:

$$

$A(B+C) = AB + AC$

$$

and

$$

$(A+B)C = AC + BC.$

$$

These rules make matrix algebra powerful because they allow algebraic manipulation similar to expressions with numbers, but with richer structure.

Real-World Meaning and Applications

Matrix multiplication is not just a classroom skill. It shows up wherever multiple steps or relationships need to be combined. One common example is computer graphics. A picture of a shape can be represented by coordinates in a matrix. A transformation matrix can rotate, stretch, or reflect the shape. Multiplying matrices combines these transformations into one process. 🎮

Another example is systems of equations. Matrices help organize coefficients, and matrix multiplication helps connect inputs and outputs. If a company wants to model how materials are converted into products across several stages, matrices can represent those stages, and multiplication can show the total effect.

A simple application comes from production planning. Suppose one matrix shows how many parts are needed for each product, and another matrix shows how many products are made in each factory. Multiplying them can tell you the total number of parts used across factories. That is a practical use of the row-column rule: each final entry summarizes a specific combination of inputs.

Matrix multiplication also appears in science and technology. In robotics, it helps describe movement. In computer science, it helps process data. In economics, it can model trade and resource flow. In all of these cases, the product matrix captures the result of combining two structured sets of information.

How Matrix Multiplication Fits into Matrix Algebra

Matrix multiplication is central to matrix algebra because many other ideas depend on it. Solving linear systems, finding inverses, studying transformations, and understanding vector spaces all use multiplication in some way.

For example, if $A$ is a square matrix and $A^{-1}$ exists, then

$$

$AA^{-1} = I$

$$

and

$$

$A^{-1}A = I.$

$$

The very definition of an inverse uses matrix multiplication. Also, when we represent a linear transformation, multiplying matrices combines transformations in the same order the actions happen. That makes matrix multiplication a language for describing change.

Because of this, learning matrix multiplication is a foundation skill. If you understand the row-column rule, dimension matching, and the special properties like associativity and identity, you are ready for more advanced topics in linear algebra.

Conclusion

students, matrix multiplication is more than a procedure for finding numbers in a table. It is a way to combine information, describe transformations, and model real systems. The key idea is the row-column rule: multiply entries from a row of one matrix and a column of another matrix, then add the results. The dimensions must fit, the order matters, and the product can represent meaningful real-world change. By mastering matrix multiplication, you build an essential tool for the rest of matrix algebra and for many applications across mathematics, science, and technology. 🌟

Study Notes

  • A matrix with $m$ rows and $n$ columns has size $m \times n$.
  • The product $AB$ is defined only when the number of columns of $A$ equals the number of rows of $B$.
  • If $A$ is $m \times n$ and $B$ is $n \times p$, then $AB$ is $m \times p$.
  • Each entry of $AB$ is found by taking a dot product of a row of $A$ and a column of $B$.
  • The entry formula is $c_{ij} = \sum_{k=1}^{n} a_{ik}b_{kj}$.
  • Matrix multiplication is usually not commutative, so $AB \neq BA$ in general.
  • The identity matrix satisfies $AI = A$ and $IA = A$.
  • The zero matrix satisfies $A0 = 0$ and $0A = 0$.
  • Matrix multiplication is associative: $(AB)C = A(BC)$.
  • Matrix multiplication is distributive over addition: $A(B+C) = AB + AC$ and $(A+B)C = AC + BC$.
  • Matrix multiplication is used in transformations, systems of equations, computer graphics, robotics, and many other real-world settings.

Practice Quiz

5 questions to test your understanding

Matrix Multiplication — Linear Algebra | A-Warded