Follow your curiosity

What discovery has been shared with you?

Start with one fact. Explore it, go deeper, then follow whichever branch catches your imagination.

Choose subjects for a surprise

Exploring any topic

Begin your discovery

Your next discovery is one click away.

Choose one or more subjects above, or leave Any Topic selected and let curiosity decide.

Mathematics

Cramer's Rule: Solving Linear Systems with Determinants

Quick fact

Cramer's rule can solve a 2x2 system almost instantly: for a system like ax + by = e, cx + dy = f, the solution is x = (ed - bf) / (ad - bc) and y = (af - ec) / (ad - bc). This rule extends to any square system, but it becomes computationally heavy for large systems—for a 100x100 system, it would require 101 determinant calculations, each of which is far more expensive than Gaussian elimination.

Why this is interesting

You've probably solved systems of equations by elimination, but what if you could just read the solution from a few numbers? Cramer's rule offers a surprisingly direct formula—but why does it work?

Read the full explanation

Understanding Cramer's Rule: Solving Linear Systems with Determinants

Imagine you have a system of linear equations, like two lines on a plane. Their intersection point is the solution. Cramer's rule gives you that point directly, using something called the determinant. The determinant is a special number associated with a square matrix that tells you how much the matrix scales area (or volume) when it transforms space. For a 2x2 matrix [[a, b], [c, d]], the determinant is ad - bc. If this number is not zero, the matrix is invertible, meaning the transformation is one-to-one and the system has a unique solution. Cramer's rule works by replacing one column of the coefficient matrix with the constants from the right-hand side, then taking the determinant. For each variable, you form a new matrix: for x, replace the first column with the constants; for y, replace the second column. Then the variable equals the determinant of that new matrix divided by the determinant of the original coefficient matrix. So for a 2x2 system, x = det([[e, b], [f, d]]) / det([[a, b], [c, d]]) and y = det([[a, e], [c, f]]) / det([[a, b], [c, d]]).

A deeper explanation

Why does this work? The determinant measures how volumes change under a linear transformation. When you solve Ax = b, you're looking for the coordinates of the vector b in the basis formed by the columns of A. When you replace the first column with b, you're measuring the volume of the parallelepiped spanned by b and the other columns. Dividing by the volume of the parallelepiped spanned by the original columns gives the coordinate of b along that first column. So, x = (volume of the parallelepiped with b in the first slot) / (volume of the parallelepiped with the original columns). This works because the determinant is multilinear: it changes linearly in each column. This property ensures that replacing a column shifts the volume in a way that isolates the contribution of that coordinate. For larger systems, the principle is the same: for the i-th variable, replace the i-th column of A with b, take the determinant, and divide by det(A). This is Cramer's rule. The rule only applies when det(A) ≠ 0, which is exactly when the system has a unique solution. If det(A) = 0, the matrix is singular, and the system either has no solution or infinitely many—the formula would involve division by zero. This makes Cramer's rule a direct test for uniqueness and a symbolic tool, though for numerical computation with many equations, Gaussian elimination is far more efficient because evaluating each determinant is computationally expensive.

Keep FACTREE close

Internet access is required. Updates arrive when you reopen or reload the app. You may need to sign in again in the installed app.