A system of linear equations asks you to find values of the variables that make every equation true at once. This calculator solves 2×2 and 3×3 systems exactly — as fractions, not rounded decimals — and shows the work two complementary ways: Cramer's rule with determinants, and Gaussian elimination. It also detects the two awkward cases that trip up students: systems with no solution and systems with infinitely many.
Three ways to solve a system
Substitution solves one equation for a single variable and plugs that expression into the others — quick when a coefficient is already 1. Elimination (the Gaussian method) adds a multiple of one equation to another so a variable cancels, then back-substitutes; it scales cleanly to large systems and is what computers use. Cramer's rule expresses each unknown as a ratio of determinants — elegant and great for showing why a solution exists, though it becomes slow beyond 3×3. All three give the same answer; this tool shows elimination and Cramer side by side so you can connect the algebra to the determinants.
What the determinant tells you
The coefficient determinant D is the single most informative number in the whole problem. If D ≠ 0, the system has exactly one solution and Cramer's rule delivers it directly. If D = 0, the equations are not independent and you fall into one of two special cases. Geometrically, two equations in x and y are two lines: a nonzero determinant means they cross once; a zero determinant means they are either the same line (infinitely many solutions) or parallel (none). In three variables the same logic applies to planes.
No solution vs. infinitely many
When D = 0 you still need to know which degenerate case you have. The test is to compare the rank of the coefficient matrix with the rank of the augmented matrix (coefficients plus the constant column). If adding the constants raises the rank, the equations contradict each other and there is no solution — think parallel lines. If the ranks are equal, the equations are dependent and there are infinitely many solutions — the same line or plane described twice. This calculator runs that rank comparison automatically and labels the result, so you never have to guess.
Why exact fractions matter
Linear systems frequently produce non-terminating decimals — x = 7/3 is exact, but 2.333… is not. Rounding early can hide structure and accumulate error, especially when you back-substitute. This calculator keeps every value as an exact rational using big-integer arithmetic, so 7/3 stays 7/3. A rounded decimal is still shown beneath each fraction for quick reading, but the fraction is the source of truth.