Just need the answer?
Type both equations into the system of equations calculator to get x and y with every step shown. The guide below shows how to solve a 2x2 system by hand four ways, with practice problems at the end.
What is a 2x2 system of equations?
A 2x2 system of equations is two linear equations in two unknowns, each of the form . The "2x2" refers to its coefficient matrix: two rows (equations) by two columns (variables). You will also see it called two equations in two unknowns, a two-variable system or a pair of simultaneous equations. A solution is an ordered pair (x, y) that makes both equations true at once.
Each equation is a straight line, so solving the system means finding where the two lines meet. Two lines can cross once, run parallel, or lie on top of each other, which gives the three possible outcomes:
| Outcome | What the lines do | What elimination shows | Determinant D = a₁b₂ − a₂b₁ |
|---|---|---|---|
| One solution (consistent, independent) | Cross at a single point; different slopes | Each variable gets a value | Not zero |
| No solution (inconsistent) | Parallel: same slope, different intercepts | A false statement such as 0 = 1 | Zero |
| Infinitely many solutions (consistent, dependent) | The same line: same slope and intercept | A true statement such as 0 = 0 | Zero |
How to solve a 2x2 system by elimination
Line up the equations
Write both in the form ax + by = c, so the x terms, the y terms and the constants sit in matching columns.
Match one coefficient
Multiply one or both equations by constants so that the coefficients of one variable are equal in size and opposite in sign. Multiply every term, including the constant.
Add the equations
The matched variable cancels, leaving one equation in one unknown. Solve it.
Substitute back
Put the value into either original equation and solve for the other variable.
Check in both equations
Substitute the pair into each original equation. A solution must satisfy both, not only the one you used to find the second value.
Elimination is also called the addition method or linear combination. The examples below solve one system, and , four different ways, so you can see that every method lands on the same point.
Example 1: elimination
The y coefficients are 2 and −4. Multiplying equation (1) by 2 turns it into 6x + 4y = 14, so the y terms are now 4y and −4y and cancel when the equations are added:
Substitute x = 3 into equation (1): 3(3) + 2y = 7, so 2y = −2 and y = −1.
| Equation | Substitute | Left side | Right side | True? |
|---|---|---|---|---|
| (1) 3x + 2y = 7 | 3(3) + 2(−1) | 7 | 7 | Yes |
| (2) 5x − 4y = 19 | 5(3) − 4(−1) | 19 | 19 | Yes |
Both hold, so the solution is (x, y) = (3, −1), the point where the two lines cross. Check it in the calculator.
Example 2: substitution
Substitution is quickest when one variable has a coefficient of 1 or −1, but it works for any system. Here no coefficient is 1, so a fraction appears. Solve equation (1) for y, , and substitute it into equation (2):
Then y = (7 − 9)/2 = −1, the same answer. For a system such as and , substitution is cleaner: x = 1 + y, so 2(1 + y) + 3y = 12, which gives y = 2 and x = 3.
Example 3: graphing
Solve each equation for y to get slope-intercept form, and , and draw both lines. The first falls with slope −1.5; the second rises with slope 1.25. Different slopes mean they must cross exactly once:
Graphing shows the answer at a glance and makes the special cases obvious, but reading a point off a sketch is only exact when the solution lands on whole numbers. Use it to see the answer, and algebra to prove it.
Example 4: Cramer’s rule
For and , the 2 × 2 determinant decides what kind of answer to expect. If D ≠ 0, there is exactly one solution:
Then x = (7(−4) − 19(2))/(−22) = −66/(−22) = 3 and y = (3(19) − 5(7))/(−22) = 22/(−22) = −1. Cramer’s rule is a fast formula for a 2x2 system with integer coefficients, and the only method that gives one variable without finding the other. Check D in the determinant calculator.
Example 5: a word problem
A café sold 40 drinks for 3 and tea costs $2. How many of each were sold?
Let c be the number of coffees and t the number of teas. Each sentence gives one equation, so this is a 2x2 system:
Multiply the first equation by 2 and subtract it from the second: 3c − 2c = 105 − 80, so c = 25, and then t = 15. Check: 25 + 15 = 40 drinks and 3(25) + 2(15) = 75 + 30 = $105. Check it.
No solution or infinitely many
When D = 0, the two lines have the same slope, and elimination removes both variables at once. What is left tells you which case you have:
- No solution (inconsistent system): and . Doubling the first gives 2x + 2y = 6, and subtracting it from the second leaves 0 = 1, which is false. The lines are parallel and never meet. Check it.
- Infinitely many solutions (dependent system): and . Subtracting twice the first leaves 0 = 0, which is always true. Both equations describe the same line, so every point on it, such as (0, 3) or (1, 2), is a solution. Write the answer as y = 3 − x, or as (t, 3 − t) for any t. Check it.
A 2x2 linear system can never have exactly two solutions: two different lines meet at most once, and if they share two points they are the same line.
Which method should you use?
| Method | Best when | Watch out for |
|---|---|---|
| Elimination | Coefficients are integers and none is 1; the default by hand | Scaling only some terms; sign errors when subtracting |
| Substitution | One variable has a coefficient of 1 or −1, or is already isolated (y = …) | Fractions appear quickly otherwise |
| Graphing | You want to see the answer or the number of solutions | Only exact when the point lands on the grid |
| Cramer’s rule | You need a formula, or only one variable, and D ≠ 0 | Fails when D = 0; mixing up the numerators |
On a Casio or TI-84 calculator
Most scientific and graphing calculators solve a 2x2 system directly. You enter the coefficients row by row, as a, b and c for each equation ax + by = c, so rearrange both equations into that form first.
- Casio fx-991EX or fx-570EX: press MENU, choose Equation/Func, then Simul Equation and 2 unknowns. Type the six numbers and press = to step through x and y.
- Casio fx-991CW: open Equation from the HOME screen, choose Simul Equation, then 2 Unknowns.
- Casio fx-991ES PLUS: press MODE, 5 (EQN), then 1 for anX + bnY = cn.
- TI-84 Plus: enter both lines in Y= as y = (7 − 3x)/2 and y = (5x − 19)/4, press GRAPH, then 2nd TRACE (CALC), 5: intersect and ENTER three times. Or store the 2 × 3 augmented matrix in [A] and run rref([A]) from the MATRIX MATH menu; the last column holds x and y.
Check it with ScientifiCalc
- System of equations calculator: opens with the example filled in and returns x and y, the row operations and whether the system is consistent and independent.
- Determinant calculator: opens with the 2 × 2 coefficient matrix to confirm D = −22 before you use Cramer’s rule.
- Math solver: enter
3x + 2y = 7, 5x - 4y = 19, separating the equations with a comma, for numbered steps and a check that substitutes the solution back. - Graphing calculator: enter
y = (7 - 3x)/2andy = (5x - 19)/4. The Key points panel lists their intersection at (3, −1).
Type a 2x2 system of equations to get x and y with every step shown.
Common mistakes
- Multiplying only some terms. When you scale an equation, every term changes, including the constant: doubling 3x + 2y = 7 gives 6x + 4y = 14, not 6x + 4y = 7.
- Sign errors when subtracting equations. Subtracting means changing the sign of every term in the second equation. Multiplying by a negative number and then adding is less error-prone.
- Misaligned columns. Rewrite y = 2x − 5 as −2x + y = −5 before eliminating, so the x terms, y terms and constants line up.
- Calling 0 = 0 "no solution". A true statement with no variables means infinitely many solutions. Only a false one, such as 0 = 1, means none.
- Checking only one equation. The value found by back-substitution always satisfies the equation you used. Check the other one too.
Practice problems with answers
Solve each 2x2 system by any method, then open the link to check your answer and the steps in the calculator.
- x + y = 10, x − y = 4. Hint: add the equations. Answer: (7, 3). Check
- 2x + 3y = 12, x − y = 1. Hint: substitution, with x = 1 + y. Answer: (3, 2). Check
- 4x − 3y = 11, 3x + 2y = 4. Hint: multiply by 2 and 3 to cancel y. Answer: (2, −1). Check
- y = 2x − 5, y = −x + 7. Hint: set the right sides equal. Answer: (4, 3). Check
- 3x − 6y = 9, x − 2y = 4. Answer: no solution; three times the second equation gives 3x − 6y = 12, which contradicts 9. Check
- 2x − y = 3, −4x + 2y = −6. Answer: infinitely many, because the second equation is −2 times the first; every point on y = 2x − 3 works. Check