Loading calculator...
- Finds the determinant, inverse and transpose of a matrix.
- Adds, subtracts and multiplies two matrices.
- Works with matrices up to 6 × 6.
- Shows exact fractions, such as 3/5, where possible.
How to use the matrix calculator
Choose the operation
Determinant, inverse, transpose, A × B, A + B or A − B.
Enter matrix A
One row per line, with numbers separated by spaces. Fractions like 1/2 work too.
Enter matrix B if needed
For adding, subtracting or multiplying.
Read the result
Each row of the answer is shown separately.
Matrix operations explained
A matrix is a grid of numbers. Adding and subtracting work entry by entry, so both matrices must be the same size. Multiplying A × B combines each row of A with each column of B, so A needs as many columns as B has rows. Only square matrices have a determinant and possibly an inverse.
2 × 2 formulas
det [a b; c d] = ad − bc
Inverse = (1 ÷ (ad − bc)) × [d −b; −c a]
A matrix with determinant 0 has no inverse
Example 1: determinant of a 3 × 3 matrix
A = [2 1 3; 0 −1 4; 1 2 0]
- Determinant −9
Example 2: inverse of a 2 × 2 matrix
A = [4 7; 2 6], determinant 10
- Inverse [3/5 −7/10; −1/5 2/5]
Example 3: multiplying
[1 2; 3 4] × [5 6; 7 8]
- Result [19 22; 43 50]
Where matrices are used
Linear algebra
Check homework on determinants and inverses.
Systems of equations
Solve them with inverse matrices.
Computer graphics
Rotate, scale and move shapes.
Data science
Matrices are at the heart of statistics and machine learning.
Solve 2 or 3 equations directly with the system of equations calculator, or work with exact fractions in the fraction calculator.
Matrix calculator FAQ
How do you find the determinant of a 2 × 2 matrix?
Multiply the diagonals and subtract: ad − bc.
When does a matrix have no inverse?
When its determinant is 0. Such a matrix is called singular.
Can you multiply any two matrices?
Only if the number of columns in the first equals the number of rows in the second.
Is A × B the same as B × A?
Usually not. Matrix multiplication is not commutative.
What is a transpose?
The matrix flipped over its diagonal, so rows become columns.
How do I enter a matrix?
Type one row per line, with numbers separated by spaces or commas.