# Matrix addition, subtraction and multiplication.

 From: Malik Subject: Matrices Tell me about matrices, including addition, subtraction and multiplication.

### Maths Help suggests:

First, matrices can only be added if they have the same number of rows and columns.
If this is the case, we say that the matrices are conformable for addition.

If the matrices are conformable, simply add the corresponding elements:

## Subtracting Matrices

Matrices are conformable for subtraction if they have the same number of rows and columns.

Subtract the elements of the second matrix from the corresponding elements of the first:

## Multiplying Matrices

Matrices are conformable for multiplication if the number columns in the first matrix is equal to the number of rows in the second.

NB: The order of the matrices is important for matrix multiplication.
In general,   A × B   is not equal to   B × A.

In general a   p × q   matrix multiplied by a   q × r   matrix results in a matrix that is   p × r   in shape.

Split the left matrix into rows, and the right matrix into columns.

To find the top-left element of the answer matrix,
Take the top row of the first matrix,
and the left column of the second matrix.