Use this matrix calculator to add, subtract, multiply, transpose, find determinant or inverse, reduce to RREF, find rank, or solve A x = b.
How to use our Matrix Calculator
- Choose an option in Operation.
- Set Rows in matrix A and Columns in matrix A to match matrix A.
- If your chosen operation uses a second matrix or vector, set Rows in matrix B and Columns in matrix B to match it.
- Enter values in Entries of matrix A using integers, decimals, or fractions like 3/4.
- When needed, enter the second matrix or right-side vector in Entries of matrix B or vector b.
- Pick Result format to show exact fractions when possible or decimal answers.
- Click Calculate.
- Read the result card that matches your operation, such as Result matrix, Determinant of A, Rank of A, or Solution x.
- Use What this means to check whether the answer is valid and sensible, such as whether A is invertible, singular, or whether A x = b has a unique solution.
Definitions
Operation: The matrix task you want to do, such as multiply, inverse, or solve A x = b.
Matrix A: The main matrix you enter in Entries of matrix A.
Matrix B or vector b: The second input used for add, subtract, multiply, or the right-hand side in Solve A x = b.
Result matrix: The new matrix produced by operations like add, subtract, multiply, transpose, inverse, or RREF.
Determinant of A: A single number for a square matrix. If it is 0, A is singular and not invertible [3].
Rank of A: The number of pivot columns, which tells how much independent information the matrix has [1].
Invertibility: Whether A has an inverse matrix. A square matrix is invertible when its determinant is not 0 [2][3].
RREF: Reduced row echelon form. This is a simplified version of a matrix found by row operations, often used to solve systems and find rank.
Solution x: The value or column vector that makes A x = b true when a unique solution exists.
System status: A plain-language label saying whether A x = b has one solution, infinitely many solutions, or no solution.
Common mistakes and quick fixes
Mistake: Using Add A + B or Subtract A - B when Rows in matrix A , Columns in matrix A , Rows in matrix B , and Columns in matrix B do not match.
Fix: For addition and subtraction, make matrix A and matrix B the same size before you calculate Result matrix .
Mistake: Trying Multiply A x B when Columns in matrix A is not equal to Rows in matrix B .
Fix: Change the dimensions so the inside numbers match. Then the calculator can produce Result matrix with size rows of A by columns of B.
Mistake: Choosing Determinant of A or Inverse of A when matrix A is not square.
Fix: Set Rows in matrix A equal to Columns in matrix A . Only square matrices can have Determinant of A and Invertibility .
Mistake: Entering Entries of matrix B or vector b as a full matrix when using Solve A x = b .
Fix: For solving, make b a single column, so Columns in matrix B should be 1 and Rows in matrix B should match Rows in matrix A .
Mistake: Typing invalid values in Entries of matrix A or Entries of matrix B or vector b , such as 3/0, blank cells, or words.
Fix: Use only numbers, decimals, or valid fractions like 1/2 in every visible cell so the calculator can compute Result matrix , Rank of A , or Solution x .
Mistake: Thinking a displayed decimal is the exact answer when Result format is set to decimals.
Fix: If you need school-style exact values, switch Result format to exact fractions when possible and compare that with What this means .
Limitations & Key Assumptions / Boundary Conditions
- The calculator only supports matrix sizes from 1 x 1 up to 4 x 4.
- Determinant of A and Inverse of A require matrix A to be square.
- Add A + B and Subtract A - B require A and B to have exactly the same dimensions.
- Multiply A x B requires Columns in matrix A to equal Rows in matrix B.
- Solve A x = b requires b to be a single column vector with the same number of rows as A.
- If A is singular, the calculator will report that it is not invertible instead of forcing an inverse.
- If a system has no solution or infinitely many solutions, the calculator shows the correct System status instead of a fake Solution x.
- Exact fraction output is used when practical, but some entries may be shown as decimals if exact symbolic display is not practical.
- Rounded decimal output is for display only, so small decimal differences can appear compared with handwritten rounding.
Methodology
How the calculator works
The calculator reads the chosen Operation, checks whether the matrix sizes are valid for that operation, then computes the result using standard matrix rules.
Core formulas
(A + B)_{ij} = a_{ij} + b_{ij}
(A - B)_{ij} = a_{ij} - b_{ij}
(AB)_{ij} = sum_{k=1}^{n} a_{ik} b_{kj}
(A^T)_{ij} = a_{ji}
A is invertible iff det(A) != 0
rank(A) = number of pivot columns in rref(A)
A x = b
Operation rules
For addition and subtraction, A and B must have the same number of rows and columns [4]. For multiplication, the number of columns in A must equal the number of rows in B [4]. Transpose swaps rows and columns. Determinant and inverse are only defined here for square matrix A, and a zero determinant means A is not invertible [2][3]. Rank is found from the pivot structure of the reduced row echelon form [1]. To solve A x = b, the calculator row-reduces the augmented matrix and classifies the system as unique, infinite, or inconsistent.
Exact and decimal handling
If you enter fractions such as 1/2, the calculator keeps them as exact rational values when possible. If you choose decimal output, rounding is applied only to what is displayed, not to the main internal steps unless exact display is impractical.
Mini example
Suppose Operation is Multiply A x B, matrix A is [[1, 2], [3, 4]], and matrix B is [[5, 6], [7, 8]].
(AB)_{11} = 1x5 + 2x7 = 19
(AB)_{12} = 1x6 + 2x8 = 22
(AB)_{21} = 3x5 + 4x7 = 43
(AB)_{22} = 3x6 + 4x8 = 50
So the Result matrix is [[19, 22], [43, 50]]. As a quick check, the answer has 2 rows and 2 columns because A is 2 x 2 and B is 2 x 2.
How to interpret the result
If Determinant of A is 0, the matrix is singular, so Invertibility should say not invertible and no inverse matrix should be shown. If Rank of A is smaller than the smaller matrix dimension, the rows or columns are not fully independent. For Solve A x = b, a unique solution means one exact answer for x, infinitely many solutions means free variables remain, and no solution means the row-reduced system contains a contradiction.
Assumptions used
The calculator assumes every visible cell in Entries of matrix A and Entries of matrix B or vector b is a valid integer, decimal, or fraction p/q with q not equal to 0. It also assumes only the inputs needed for the selected operation affect the result.