VKCMVI
COMPUTATIONAL MATHEMATICS

Gaussian elimination

Solve linear systems using Gauss–Jordan row operations, partial pivoting and residual checks.

Calculator

Load the problem, then select Solve to view the steps. Some advanced examples intentionally fail or do not converge.

Method and applicability

Gauss–Jordan elimination

[A|b]→[I|x]

A square system Ax = b has a unique solution if A is nonsingular.

Partial pivoting reduces some rounding problems but cannot eliminate ill-conditioning.

Results

Worked examples

Basic 1

4x₁ + x₂ = 6; 2x₁ + 3x₂ = 8

Expected result: x = (1, 2)

Calculation steps
  1. [4, 1 | 6; 2, 3 | 8] → R₂ − ½R₁ → [4, 1 | 6; 0, 2.5 | 5]
  2. R₂ / 2.5 → [0, 1 | 2]
  3. R₁ − R₂ → [4, 0 | 4] → R₁ / 4 → [1, 0 | 1]
  4. Ax − b = (0, 0)

Source: Original exercise

Advanced 3

x + 2y = 3; 2x + 4y = 7

Expected result: rank(A) = 1; rank([A|b]) = 2

Calculation steps
  1. R₂ ← R₂ − 2R₁ → 0 = 1

Expected: no unique solution; applicability checks should reject this inconsistent system.

Source: Original exercise

Accuracy and common pitfalls

A small residual does not guarantee an accurate solution when the matrix is ill-conditioned; compare the backward error and condition estimate.

Recommended reading