Matrix multiplication falls into two general categories:

- Scalar in which a single number is multiplied with every entry of a matrix
- Multiplication of an entire matrix by another entire matrix
For the rest of the page,
*matrix multiplication*will refer to this second category.

### Scalar Matrix Multiplication

In the scalar variety, every entry is multiplied by a number, called a scalar.

#### What is the answer to the scalar multiplication

problem below?

#### What is matrix multiplication?

You can multiply two matrices if, and only if, the number of columns in the first matrix equals the number of rows in the second matrix.

Otherwise, the product of two matrices is undefined.

The product matrix's dimensions are $$ \rightarrow $$ (rows of first matrix) × (columns of the second matrix )

The Dimensions of the product matrix

##### Example 1

If we multiply a 2×3 matrix with a 3×1 matrix, the product matrix is 2×1

Here is how we get M_{11} and M_{12} in the product.

_{11}= r

_{11}× t

_{11}+ r

_{12}× t

_{21}+ r

_{13}×t

_{31}

M

_{12}= r

_{21}× t

_{11}+ r

_{22}× t

_{21 }+ r

_{23}×t

_{31}

### Two Matrices that can **not** be multiplied

Matrix C and D below **cannot** be multiplied together because the number of columns in C **does not equal** the number of rows in D. In this case, the multiplication of these two matrices is not defined.

#### Is the product of matrix A and Matrix B below

defined or undefined?

Since the number of columns in Matrix A does not equal the number of rows in Matrix B.

The multiplication of A and B is undefined.

#### OK, so how do we multiply two matrices?

In order to multiply matrices,

**Step 1**: Make sure that the the number of columns in the 1^{st}one equals the number of rows in the 2^{nd}one. (The pre-requisite to be able to multiply)-
**Step 2**: Multiply the elements of each row of the first matrix by the elements of each column in the second matrix. **Step 3**: Add the products.

It's easier to understand if you go through the power point examples below.