b2KIT

Gaussian Elimination Step-by-Step

Solve systems of linear equations with animated row operations. Shows augmented matrix, pivot selection, and back substitution.

Tested tool guide Tested browser tools Checked August 16, 2026

What Gaussian Elimination Step-by-Step does, with a checked example

Enter a system of linear equations, or its augmented matrix, and the tool replays Gaussian elimination as an animated walkthrough: it shows the augmented matrix, highlights each pivot, performs row operations visibly one at a time, and closes with back substitution or the reduced row echelon form. The mistake most users make is treating an operation as applying only to the coefficients; every row operation changes the constant column too. The surprise is that the step sequence is not unique, only the final solution is.

Worked example

A concrete input and expected output from the current implementation.

Input

x + y + z = 6
2x - y + z = 3
x + 2y - z = 2

Expected output

Solution: x = 1, y = 2, z = 3. The animation shows operations including R2 - 2R1, which turns row 2 into [0 -3 -1 | -9], and R3 - R1, which turns row 3 into [0 1 -2 | -4]; after eliminating below the second pivot, back substitution gives z = 3, y = 2, and x = 1.

Substituting z = 3 into y - 2z = -4 gives y = 2, and x + y + z = 6 then gives x = 1. The equations verify: 1 + 2 + 3 = 6, 2(1) - 2 + 3 = 3, and 1 + 4 - 3 = 2.

How the result is produced

1

Forward elimination

The tool works column by column on the augmented matrix. In each column it selects a pivot, a nonzero entry, and swaps rows first if the natural pivot position holds zero. It then animates a row operation of the form Ri - mRj that zeroes every entry below the pivot, moving to the next column only after the change is shown. The whole row changes at once, including the constant column.

2

Back substitution

When the matrix is upper triangular, the tool solves from the bottom row upward: the last row fixes the last variable, and each row above substitutes the values already found. In the reduced form it continues above the pivots, clearing entries until each pivot column holds a single 1, so every variable value reads directly off the final constant column.

Good uses

  • Checking hand-worked homework: run the same system through the animation and compare your row-operation sequence and final solution frame by frame to find the exact step where you went wrong.
  • Systems with fractions or awkward decimals, where arithmetic slips are common and seeing each operation applied to the whole row, constants included, catches them early.
  • Learning or teaching pivot selection: watch why a zero in the pivot position forces a row swap, and see how different valid pivots yield different but equivalent chains of steps.

Limits and checks

  • Inconsistent or underdetermined systems: a row that reduces to [0 ... 0 | k] with k nonzero means no solution, while [0 ... 0 | 0] means free variables. Elimination runs to completion either way, so judge the final matrix, not just whether the tool printed values.
  • The step sequence is never unique. A different pivot choice gives a different-looking chain of operations that is equally valid; compare final solutions, not intermediate frames, when checking against the tool.
  • Rounding: if the tool displays decimals, a small value like 0.0001 may represent exact zero (or vice versa) depending on its rounding and tolerance, so prefer exact fractions when the tool offers them.

Common questions

Do row operations ever change the solution of the system?

No. Swapping rows, multiplying a row by a nonzero constant, and adding a multiple of one row to another all preserve the solution set exactly. That invariance is what makes the animation trustworthy: whatever sequence of displayed operations is applied, the final matrix represents the same system as the first one.

Why did the tool pick a different pivot than I did?

Any nonzero entry can serve as a pivot, so the choice is a strategy, not a rule. The tool may take the first available nonzero entry or the numerically largest one to limit rounding error. Different pivots produce different-looking sequences that still reach the same solution, so the differences are cosmetic.

References and verification

The example and behavioral notes were checked against the browser implementation. Standards and primary references below define the relevant format, formula, or platform behavior.

Related Tools