Skip to content

System of linear equations calculator

Enter coefficients for two or three equations, classify the system, and verify a unique solution by substitution residual.

Equation coefficients

Processed in your browser.

Two-variable mode uses the first two equations. Three-variable mode uses all three.

For ax + by + cz = d, enter a under x, b under y, c under z, and d under =.

System solution

Choose a system size and enter every active coefficient.

How to solve a system of linear equations

A solution assigns one value to every variable so that all entered equations are true at the same time. This page classifies square 2×2 and 3×3 systems.

How to use

  1. Choose two or three variables.
  2. Enter the coefficients in ax + by = d or ax + by + cz = d form; use 0 for a missing term.
  3. Select Solve system to classify the equations.
  4. For a unique solution, read x, y, and z and check the maximum substitution residual.

Elimination and classification

Scaled Gaussian elimination with partial pivoting rearranges equations when a stronger pivot is available. Row order therefore does not change the mathematical answer.

A pivot for every variable gives one solution. A row equivalent to 0 = nonzero gives no solution. Fewer pivots without a contradiction means infinitely many solutions. Unique results are substituted into the original equations and the largest absolute residual is displayed.

Worked examples

Unique 2×2 system

x+y=6 and 2x−y=3 gives x=3 and y=3. Substitution gives 6 and 3 again.

No solution

x+y=2 and 2x+2y=5 have parallel left sides but incompatible constants, so elimination yields a contradiction.

Infinitely many solutions

x+y=2 and 2x+2y=4 are the same equation at different scales, leaving one free variable.

Unique 3×3 system

x+y+z=6, 2x−y+z=3, and x+2y−z=2 gives x=1, y=2, z=3.

Limits and numeric scope

  • Only coefficient fields are accepted; free-form equation parsing, symbols, fractions, complex values, and units are not supported.
  • Inputs are finite decimals with absolute value at most 1 billion. Very ill-conditioned systems may be sensitive to small input changes.
  • Near-zero comparisons use a documented internal tolerance of 0.0000000001 after row scaling; this is numerical classification, not symbolic algebra.
  • The page handles exactly two or three equations in the same number of variables. It is not a CAS, matrix tutor, or unlimited solver.

Frequently asked questions

What does no solution mean?

At least two equations impose incompatible conditions, so no point satisfies all of them.

What does infinitely many solutions mean?

The equations do not provide enough independent constraints; one or more variables remain free.

Why enter zero?

A term missing from an equation has coefficient zero.

What is the substitution residual?

It is the largest absolute difference between each original left side evaluated at the solution and its right side.