Math calculators

Augmented Matrix Calculator

Updated Sep 20, 2026 By Infinity Calculator
Rate Formulas
Matrix Size
Quick sizes
Method & Options
Elimination method
RREF — full Gauss-Jordan elimination: every pivot is 1 with zeros above and below.
Enter Matrix Values
Accepts integers, decimals, fractions (3/4) and expressions (2+3, 10/4). Entries are evaluated when you leave a cell or press Enter. Move with the arrow keys, Tab or Enter.
Example Systems

Number display
Calculations always use exact rational arithmetic; this only changes how results are shown.
Step-by-Step Solution
Operation legend: Row Swap exchanges two rows  ·  Row Scaling multiplies a row by a non-zero number  ·  Row Replacement adds a multiple of one row to another. Pivot entries are highlighted and underlined.
Step 1 of 1
Results

Rank Comparison

Introduction

An augmented matrix is a grid of numbers that stands for a system of equations. The left side holds the numbers in front of the variables. The last column holds the answers, called the constants. A line splits the two parts.

This augmented matrix calculator solves that system. Type your numbers into the grid, pick REF or RREF, and press Calculate. You can enter whole numbers, decimals, fractions like 3/4, or simple math like 2+3.

The calculator uses Gaussian elimination and Gauss-Jordan elimination to clean up the matrix row by row. You see every row swap, every row scaled, and every row added to another. Pivot spots are marked so you can follow along.

When the elimination finishes, the calculator tells you if the system has one solution, no solution, or infinite solutions. It can also show the rank and the determinant. Answers stay exact as fractions, or you can switch to decimals.

Matrices can be 2 to 8 rows tall and 3 to 9 columns wide. Try a built-in example, make a random matrix, transpose it, or multiply it by a number. When you are done, copy the solution, copy it as LaTeX, or print it as a PDF.

How to use our Augmented Matrix Calculator

Type the numbers of your matrix, pick a method, and the calculator shows the row steps, the final matrix, and the solution for x.

Rows: Pick how many rows (equations) your system has, from 2 to 8.

Columns: Pick how many columns you need. In augmented mode this is the number of variables plus 1 for the constants.

Quick sizes: Click a preset like 3×4 to set the rows and columns in one step.

Elimination method: Choose RREF for full Gauss-Jordan (pivots are 1 with zeros above and below) or REF for forward elimination only (zeros below each pivot).

Augmented mode: Leave this on when the last column holds the constants (b). Turn it off to reduce a plain coefficient matrix.

Show step-by-step solution: Turn this on to see every row swap, row scale, and row replacement with the matrix after each move.

Show matrix properties: Turn this on to see the rank of A, the rank of [A|b], and the determinant when the matrix is square.

Matrix cells: Click each box and enter a whole number, decimal, fraction like 3/4, or a small sum like 2+3. Move with the arrow keys, Tab, or Enter.

Clear Matrix: Sets every cell back to 0 so you can start fresh.

Random Matrix: Fills the grid with random whole numbers for quick practice.

Transpose: Flips rows into columns, if the new size still fits the limits.

Scalar Multiply: Enter one number and every cell is multiplied by it.

Example Systems: Load a ready-made system, like one with a unique solution, no solution, or infinite solutions.

Number display: Choose exact fractions or decimal answers. Math stays exact either way.

Calculate: Click it to run the elimination and see the final matrix, rank chart, and solution.

Reset: Puts all settings and the matrix back to the default 3×4 example.

What Is an Augmented Matrix?

An augmented matrix is a way to write a system of linear equations as a grid of numbers. You drop the letters and keep only the numbers. The coefficients (the numbers in front of each variable) go on the left side. The constants (the answers after the equals sign) go in the last column, after a vertical bar.

For example, the system:

2x + y = 5
x − 3y = −1

becomes the augmented matrix rows [2, 1 | 5] and [1, −3 | −1]. Same problem, less writing.

The Three Row Operations

You solve a matrix by changing its rows until the answer is easy to read. Only three moves are allowed, and none of them change the solution:

  • Row swap: trade the places of two rows.
  • Row scaling: multiply every number in one row by a number that is not zero.
  • Row replacement: add a multiple of one row to another row.

REF and RREF

These are two "finished" shapes for a matrix.

Row Echelon Form (REF) uses Gaussian elimination. Each leading number, called a pivot, sits to the right of the pivot above it, and everything below each pivot is zero. The matrix looks like a staircase. You then work backward to find each variable.

Reduced Row Echelon Form (RREF) uses Gauss-Jordan elimination. It goes further: every pivot equals 1, and there are zeros both above and below it. In RREF, the answers sit right there in the last column. No back-solving needed.

Three Kinds of Answers

Every linear system ends in one of three ways:

  • One solution: each variable has exactly one value. The lines or planes meet at a single point.
  • No solution: a row turns into something impossible, like 0 = 4. The equations disagree. This is called an inconsistent system.
  • Infinite solutions: there are fewer useful equations than variables. Some variables are free, so you write the answer with a parameter like t.

Rank and What It Tells You

The rank of a matrix is the number of pivots it has. Rank is a quick way to check your answer type:

  • rank(A) is smaller than rank([A|b]) → no solution
  • rank(A) = rank([A|b]) = number of variables → one solution
  • rank(A) = rank([A|b]) but smaller than the number of variables → infinite solutions

The number of free variables equals the number of variables minus the rank.

Where This Is Used

Solving linear systems with matrices shows up in engineering, physics, computer graphics, economics, chemistry (balancing equations), and machine learning. Any time many facts depend on each other at once, a matrix handles them together instead of one at a time.

Tips for Getting It Right

  • Keep fractions exact instead of rounding. Small rounding errors grow fast.
  • Work one column at a time, left to right.
  • If a whole row becomes zeros, that equation repeated another one.
  • Check your answer by plugging the values back into the original equations.

Formulas used

Partial pivoting (pivot row selection)
p = \arg\max_{r \le i \le m} \left| a_{ic} \right|, \qquad R_r \leftrightarrow R_p
Row scaling (normalize pivot to 1)
R_r \rightarrow \frac{1}{a_{rc}} \, R_r
Row replacement (eliminate entries in pivot column)
R_i \rightarrow R_i - a_{ic} \, R_r
Determinant from elimination (square coefficient matrix)
\det(A) = (-1)^{s} \prod_{k=1}^{n} u_{kk}
Rank and system consistency (Rouche-Capelli)
\begin{cases} \operatorname{rank}(A) < \operatorname{rank}([A\,|\,b]) & \text{no solution} \\ \operatorname{rank}(A) = \operatorname{rank}([A\,|\,b]) = n & \text{unique solution} \\ \operatorname{rank}(A) = \operatorname{rank}([A\,|\,b]) < n & \text{infinitely many solutions} \end{cases}
Number of free variables
f = n - \operatorname{rank}(A)
Solution read from RREF (pivot variable)
x_{j} = r_{i,n+1} - \sum_{k \in F} r_{i,k} \, t_{k}
Exact rational arithmetic on entries
\frac{a}{b} \pm \frac{c}{d} = \frac{ad \pm bc}{bd}, \qquad \frac{a}{b} \cdot \frac{c}{d} = \frac{ac}{bd}, \qquad \frac{a}{b} \div \frac{c}{d} = \frac{ad}{bc}

Frequently asked questions

What is the difference between a coefficient matrix and an augmented matrix?

A coefficient matrix holds only the numbers in front of the variables. An augmented matrix adds one more column with the constants from the right side of each equation.

For the system 2x + y = 5 and x − 3y = −1:

  • Coefficient matrix: [2, 1] and [1, −3]
  • Augmented matrix: [2, 1 | 5] and [1, −3 | −1]

The extra column is what lets you solve for the variables, not just study the shape of the system.

How do you know if a system has no solution from the matrix?

Look for a row where every coefficient is zero but the constant is not. That row says 0 = 4 (or some other non-zero number), which can never be true.

When you see that, stop. The system is inconsistent and has no solution. The equations contradict each other.

What is a pivot in a matrix?

A pivot is the first non-zero number in a row, reading left to right. It is the number you use to clear out the rest of its column.

In RREF every pivot equals 1 and has zeros above and below it. The column a pivot sits in is called a pivot column, and the variable for that column is a basic variable, not a free one.

How many solutions can a system of linear equations have?

Only three outcomes are possible:

  • Exactly one solution
  • No solution
  • Infinitely many solutions

There is never a case with exactly two or three solutions. Lines and planes either cross at one point, never meet, or overlap completely.

What are free variables in a matrix?

A free variable is one whose column has no pivot. You can pick any value for it, and the other variables adjust to match.

Count them with this rule: free variables = number of variables − rank.

Each free variable gets a parameter like t₁ or t₂ in the answer. If there is at least one free variable and the system is consistent, there are infinite solutions.

Should I use REF or RREF?

Use RREF if you want the answers handed to you. The last column becomes the solution, with no extra work.

Use REF if your class asks for Gaussian elimination with back substitution, or if you only need the rank. REF takes fewer steps but you still have to solve backward from the bottom row up.

Can an augmented matrix have more rows than columns?

Yes. More rows than variables means you have more equations than unknowns. This is called an overdetermined system.

It often has no solution, because the extra equations may disagree. But if some rows repeat information, it can still have one solution or infinite solutions. The rank test tells you which.

What does the determinant tell you about a system?

The determinant only works for square coefficient matrices (same number of equations and variables).

  • Determinant is not zero: exactly one solution.
  • Determinant is zero: either no solution or infinite solutions. You need row reduction to tell which.

A zero determinant means the rows are dependent, so at least one equation repeats info from the others.

Why do row operations not change the solution?

Each row is an equation. Swapping rows just reorders your equations. Scaling a row by a non-zero number is the same as multiplying both sides of one equation. Adding a multiple of one equation to another is a legal algebra move too.

None of these moves add or remove any solution, so the final matrix has the same answers as the one you started with.

How do you write the answer when a system has infinite solutions?

Give each free variable a parameter name like t. Then write every pivot variable in terms of those parameters.

For example, if the RREF gives x₁ + 2x₃ = 5 and x₂ − x₃ = 1, set x₃ = t. The answer is:

x₁ = 5 − 2t, x₂ = 1 + t, x₃ = t

Any value of t gives a valid solution, which is why there are infinitely many.

What happens if a whole row becomes zeros?

A row of all zeros (including the constant) means that equation gave no new information. It was a copy or a combination of other equations.

This drops the rank by one. If the rank ends up smaller than the number of variables, the system has infinite solutions. A zero row is fine and never means an error.

Can an augmented matrix be used for a homogeneous system?

Yes. A homogeneous system has all zeros in the constants column. Every row ends in 0.

These always have at least one solution: set every variable to 0. That is the trivial solution. If the rank is less than the number of variables, there are also infinite non-trivial solutions.

Why use fractions instead of decimals in row reduction?

Fractions stay exact. Decimals round, and those tiny rounding errors pile up over many row operations.

For example, 1/3 becomes 0.333, and after several steps that gap can turn a true zero into 0.0001, which looks like a pivot when it is not. Exact fractions keep every pivot and zero honest.

How do you convert a word problem into an augmented matrix?

Follow three steps:

  1. Write one equation for each fact in the problem.
  2. Line up the variables in the same order in every equation. Put a 0 where a variable is missing.
  3. Copy the coefficients into rows, and put each constant in the last column.

The key is keeping the variable order the same across all rows, or the columns will not match up.