Exact two-variable elimination

Systems of Equations Solver

Solve two linear equations in two variables. Follow the checked steps to find the values that satisfy both equations or see why there is no single answer.

Recent problems and practice On this device

Your practice

0 due

This browser keeps your 20 most recent quizzes and the questions you missed. No sign-in needed.

Solve a problem, then choose Four-question quiz.

    Failed typed math may be kept for up to 7 days to improve the solver. Privacy.

    Enter a problem

    Typed solving is free
    Try
    Input help

    Enter one problem at a time. Browse supported topics and limits.

    Use parentheses to show what belongs in a fraction. Type (x+1)/3 to divide the whole numerator by 3. For a square root, type sqrt(9).

    For a system, put each of two equations on its own line or separate them with a semicolon.

    Drafts stay in this tab for up to 24 hours. Select Clear to remove your draft.

    Sign in to use photo, PDF, drawing, or Describe. A usable result uses one assisted credit.

    Status
    Verified
    Equations
    Exactly 2
    Variables
    Exactly 2
    Independent check
    Complete solution set

    How to solve systems of equations

    A solution is a pair of values that makes both equations true at once. Enter one equation per line or separate them with a semicolon. Use substitution when a variable is already on its own, or elimination when adding or subtracting the equations can cancel a variable.

    Solve by elimination

    {2x+y=7x−y=2\begin{cases}2x+y=7\\x-y=2\end{cases}

    2x+y=7; x-y=2

    1. Add the equations to cancel y. The result is 3x = 9, so x = 3.
    2. Substitute x = 3 into x − y = 2 to get y = 1.
    3. Check both equations. The first gives 2(3) + 1 = 7 and the second gives 3 − 1 = 2.

    Solve by substitution

    {y=2x−1x+y=8\begin{cases}y=2x-1\\x+y=8\end{cases}

    Replace y in the second equation with 2x − 1. This gives x + (2x − 1) = 8, so 3x = 9 and x = 3. Then y = 2(3) − 1 = 5. The pair (3, 5) works in both originals because 5 = 2(3) − 1 and 3 + 5 = 8.

    Eliminate a variable when the coefficients differ

    {x+2y=53x−y=4\begin{cases}x+2y=5\\3x-y=4\end{cases}

    Multiply the entire second equation by 2 to get 6x − 2y = 8. Add it to the first equation to get 7x = 13. Substitute x = 13/7 into the first equation to find y = 11/7.

    x=137,y=117x=\frac{13}{7},\quad y=\frac{11}{7}

    A system with no solution

    {x+y=22x+2y=6\begin{cases}x+y=2\\2x+2y=6\end{cases}

    Double the first equation, then subtract it from the second. The variables cancel and leave 0 = 2. The equations describe distinct parallel lines, so no pair satisfies both.

    A system with infinitely many solutions

    {x+y=22x+2y=4\begin{cases}x+y=2\\2x+2y=4\end{cases}

    Subtract twice the first equation from the second and you get 0 = 0. The second equation describes the same line as the first. Any real x works when y = 2 − x.

    Three unknowns by hand

    The calculator above accepts two equations in two variables. The same elimination idea can solve a larger system on paper.

    Eliminate z in two equations

    {x+y+z=62x+y+z=7x+2y+z=8\begin{cases}x+y+z=6\\2x+y+z=7\\x+2y+z=8\end{cases}
    1. Subtract the first equation from the second to get x = 1.
    2. Subtract the first equation from the third to get y = 2.
    3. Use the first equation to get z = 6 − 1 − 2 = 3.
    4. Check all three. The left sides become 1 + 2 + 3 = 6, 2 + 2 + 3 = 7, and 1 + 4 + 3 = 8.

    Common mistakes and how to check your work

    • When you multiply or subtract an equation, apply the operation to every term and to the right-hand side.
    • When both variables cancel, read the statement that remains. A contradiction means no solution. For the dependent two-variable systems here, a true identity leaves infinitely many solutions on the original line.
    • Plug the ordered pair into both original equations. Check the first equation and the second separately, even if you used only one to find the second variable.

    The substitution-checking guide shows how to check a value in a single equation. Use the line-by-line guide to inspect signs and operations during elimination.

    What you can enter

    Use two linear equations with two single-letter variables and exact rational coefficients. For an equation in just one variable, use the solve for x calculator.

    Questions

    Systems of equations solver FAQ

    How do I enter a system of equations?

    Enter exactly two equations, one on each line, or separate them with a semicolon, such as 2x+y=7; x-y=2.

    What outcomes can the solver identify?

    It verifies a unique ordered pair, no solution for inconsistent parallel equations, or infinitely many solutions for dependent equations.

    Can this solver handle three unknowns?

    The calculator accepts two linear equations in two single-letter variables with rational coefficients. The guide below shows how to use elimination by hand for a system with three unknowns.