Matrix calculator allows you to perform the following actions on matrices: addition of matrices, subtraction of matrices, multiplication of matrices. Fill in the appropriate elements in matrices A and B, select the type of action over the matrices, and then click the "Calculate" button.

Matrix calculator
Matrix А
The size of the matrix А: Number of rows:       
Number of columns:
Matrix B
The size of the matrix B: Number of rows:       
Number of columns:
Сalculate



Matrix in mathematics is usually called a set of numbers represented as a rectangular table having m rows and n columns.

A(m×n) = 
a11 a12 ... a1n
a21 a22 ... a2n
... ... ... ...
am1 am2 ... amn

The addition of the matrices А and B is the action at which the corresponding elements of the matrices A and B are added. Only matrices of the same size can be folded. For example: А(2×2) + В(2×2), А(3×5) + В(3×5) etc. The result of the addition of the matrices A and B is the matrix C, having the same size as the matrices A and B.

Subtraction of the matrices A and B is the action at which the corresponding elements of the matrices A and B are subtracted. Only matrices of the same size can be subtracted. For example: А(2×2) - В(2×2), А(3×5) - В(3×5) etc. The result of subtracting the matrices A and B is the matrix C, which has the same size as the matrices A and B.

Multiplication of matrices A and B. Matrix multiplication is possible only if the number of columns of the matrix A is equal to the number of rows of the matrix B. For example: А(2×5) × В(5×2), А(3×4) × В(4×5) etc. The result of multiplying the matrix A by size m×n by a matrix B of size n×k is a matrix C of size m×k.