# Matrix Multiplication

Matrix Multiplication is defined as the multiplication of two matrices.

It requires the number of columns in the first matrix to equal the number of rows in the second matrix. The resulting matrix will have the same number of rows as the first matrix, and the same number of columns as the second matrix.

* | Scalar | Row Vector | Column Vector | Matrix |
---|---|---|---|---|

Scalar | Multiplies the two scalar values. | Multiplies the scalar with each element in the row vector. | Multiplies the scalar with each element in the column vector. | Multiplies the scalar with each element in the matrix. |

Row Vector | Multiplies the scalar with each element in the column vector. | Use matrix multiplication. | Use matrix multiplication. | |

Column Vector | Multiplies the scalar with each element in the column vector. | Use matrix multiplication. | Use matrix multiplication. | |

Matrix | Multiplies the scalar with each element in the matrix. | Use matrix multiplication. | Use matrix multiplication. | Use matrix multiplication. |

## Examples

```
3 * 3
ans = 9
[1 5 4] * [3; 5; 7]
ans = 56
[3 4; 5 8] * [4; 7]
ans = [40 ; 76]
```

```
[3 5 4] * [3 6 7]
[3 4] * [1 4;3 6; 10 2]
```