Mathwords logoMathwords

Systems of Linear Equations — Definition, Formula & Examples

A system of linear equations is a set of two or more linear equations that share the same variables. Solving the system means finding the values of those variables that make every equation true at the same time.

A system of mm linear equations in nn unknowns x1,x2,,xnx_1, x_2, \ldots, x_n is a collection of equations, each of the form a1x1+a2x2++anxn=ba_1x_1 + a_2x_2 + \cdots + a_nx_n = b, where aia_i and bb are real-number constants. A solution to the system is an ordered nn-tuple that satisfies all mm equations simultaneously. A system may have exactly one solution, infinitely many solutions, or no solution.

Key Formula

{a1x+b1y=c1a2x+b2y=c2\begin{cases} a_1x + b_1y = c_1 \\ a_2x + b_2y = c_2 \end{cases}
Where:
  • x,yx, y = the unknown variables to solve for
  • a1,a2a_1, a_2 = coefficients of x in the first and second equations
  • b1,b2b_1, b_2 = coefficients of y in the first and second equations
  • c1,c2c_1, c_2 = constant terms on the right side of each equation

How It Works

You can solve a system of linear equations using three main methods: graphing, substitution, or elimination. When you graph each equation, the solution is the point where the lines intersect. With substitution, you solve one equation for a variable and plug that expression into the other equation. With elimination, you add or subtract the equations (sometimes after multiplying one) to cancel out a variable. If the lines are parallel (same slope, different intercepts), the system has no solution and is called inconsistent. If the equations describe the same line, there are infinitely many solutions.

Worked Example

Problem: Solve the system: 2x + y = 10 and x − y = 2.
Step 1 — Choose a method: Use elimination. Adding the two equations will cancel the y terms because +y and −y are opposites.
Step 2 — Add the equations: Add the left sides and right sides separately.
(2x+y)+(xy)=10+2    3x=12(2x + y) + (x - y) = 10 + 2 \implies 3x = 12
Step 3 — Solve for x: Divide both sides by 3.
x=123=4x = \frac{12}{3} = 4
Step 4 — Solve for y: Substitute x = 4 into the second equation, x − y = 2.
4y=2    y=24 - y = 2 \implies y = 2
Answer: The solution is (4, 2). Both equations are satisfied: 2(4) + 2 = 10 and 4 − 2 = 2.

Another Example

Problem: Solve the system using substitution: y = 3x − 1 and 2x + y = 9.
Step 1 — Substitute: The first equation already gives y in terms of x. Replace y in the second equation.
2x+(3x1)=92x + (3x - 1) = 9
Step 2 — Solve for x: Combine like terms and isolate x.
5x1=9    5x=10    x=25x - 1 = 9 \implies 5x = 10 \implies x = 2
Step 3 — Find y: Plug x = 2 back into y = 3x − 1.
y=3(2)1=5y = 3(2) - 1 = 5
Answer: The solution is (2, 5).

Visualization

Why It Matters

Systems of linear equations appear throughout Algebra 1, Algebra 2, and precalculus, making them one of the most tested topics in high-school math. Beyond school, they model real situations such as budgeting (two constraints on cost), chemistry (balancing reaction quantities), and engineering (finding currents in an electrical circuit). Mastering them also lays the groundwork for linear algebra and matrix methods used in data science and computer graphics.

Common Mistakes

Mistake: Forgetting to distribute a multiplier to every term in an equation before adding or subtracting.
Correction: When you multiply an equation by a constant, apply it to every term — including the constant on the right side — before combining with the other equation.
Mistake: Finding x but not substituting back to find y (or vice versa), leaving the solution incomplete.
Correction: A solution to a two-variable system is an ordered pair. Always solve for both variables and state the answer as (x, y).

Related Terms