Logo

MonoCalc

/

Linear Equation Solver

Math

3x − 6 = x + 4

Try an Example

Equation Form

Unique Solution

Solution

x = 5

Exact Fraction

5

Intersection Point

(5, 9)

Verification

LHS = 9

RHS = 9

Matches ✓

Graph — y = ax + b and y = cx + d

y = ax + b

y = cx + d

Intersection

Step-by-Step Solution

Step 1: Start with the equation 3x − 6 = 1x + 4

Step 2: Move the x-terms to the left side by subtracting 1x from both sides: 3x − 1x − 6 = 4

Step 3: Combine like terms: (3 − 1)x − 6 = 4 → 2x − 6 = 4

Step 4: Move the constant to the right side by subtracting -6 from both sides: 2x = 4 − (-6) = 10

Step 5: Divide both sides by 2: x = 10 / 2 = 5

About This Tool

Linear Equation Solver – Solve ax + b = 0 and ax + b = cx + d

A linear equation is any first-degree equation in one variable — the variable appears only to the power of 1, with no squares, cubes, or roots attached to it. Linear equations are the building block of algebra: they show up when converting units, splitting a bill, finding a break-even point, or working out how long it takes two moving objects to meet. This tool solves both the simple one-sided form ax + b = 0 and the more general two-sided form ax + b = cx + d, where a, b, c, and d are numbers you supply.

How the Solver Works

Every two-sided equation can be reduced to the simple form by moving all the x terms to one side and all the constants to the other. The solver computes A = a − c (the combined coefficient of x) and B = d − b (the combined constant). When A is not zero, the unique solution is x = B / A. The tool then substitutes that value back into both sides of the original equation to verify that the left-hand side equals the right-hand side, and it shows every intermediate algebraic step so you can follow — or double-check — the work by hand.

Identities and Contradictions

Not every linear equation has exactly one solution. If A = 0 (meaning the coefficient of x is the same on both sides) there are two possibilities. When the constants also match (B = 0), the equation is an identity — both sides are literally the same expression, so any real number satisfies it, giving infinitely many solutions. When the constants differ (B ≠ 0), the equation collapses to a false statement like 0 = 4, which is a contradiction with no solution at all. Recognizing these two edge cases is a common stumbling block for students, so the solver labels them explicitly instead of throwing a division-by-zero error.

Exact Fractions and Mixed Numbers

Many linear equations produce a solution that isn't a whole number. Rather than only showing a rounded decimal, the solver converts the result into an exact, fully reduced fraction using a continued-fraction algorithm, then also offers a mixed-number representation. You can toggle between decimal, fraction, and mixed-number output, and adjust the decimal precision from 0 to 10 places for the numeric display.

Graphing the Equation

Algebraically, solving ax + b = cx + d is the same as finding where the two lines y = ax + b and y = cx + d cross. The tool plots both lines and marks their intersection point, whose x-coordinate is the solution to the equation. When the equation is a contradiction, the lines are parallel and never meet; when it's an identity, the two lines are coincident — they lie exactly on top of each other.

Free-Form Equation Input

If you'd rather type the equation as written, switch to free-form mode and enter something like 4(x - 2) = 2x + 6. The parser expands parentheses, combines like terms on each side, and feeds the resulting coefficients into the same solver. It supports a single variable (x) and degree-1 terms only; entering something like x^2 or a second variable will return a clear error message pointing you toward the right tool.

When to use this tool
Use the Linear Equation Solver any time you need to isolate a variable from a first-degree equation — for homework, checking algebra by hand, or quickly verifying a formula rearrangement. For equations with an term, try the Quadratic Equation Solver instead; for two or more equations solved simultaneously, use the System of Equations Solver.

Frequently Asked Questions

Is the Linear Equation Solver free?

Yes, Linear Equation Solver is totally free :)

Can I use the Linear Equation Solver offline?

Yes, you can install the webapp as PWA.

Is it safe to use Linear Equation Solver?

Yes, any data related to Linear Equation Solver only stored in your browser (if storage required). You can simply clear browser cache to clear all the stored data. We do not store any data on server.

What is a linear equation?

A linear equation is a first-degree equation in one variable, meaning the variable appears only to the power of 1. It can be written in the simple form ax + b = 0 or the two-sided form ax + b = cx + d, and it always graphs as a straight line.

How does the Linear Equation Solver work?

Enter the coefficients a and b (simple form) or a, b, c, and d (two-sided form). The tool computes A = a − c and B = d − b, then solves x = B / A when A ≠ 0. It also classifies the equation, shows a full step-by-step derivation, and verifies the solution by substituting it back into both sides.

What does 'infinitely many solutions' mean?

If both sides of the equation reduce to the same expression (for example 2x + 4 = 2x + 4), the x-terms cancel and the constants match, so every real number satisfies the equation. This is called an identity, and it happens when a = c and b = d.

What does 'no solution' mean?

If the x-terms cancel but the remaining constants differ (for example 2x + 3 = 2x + 7), the equation reduces to a false statement like 0 = 4. No value of x can satisfy it, so the equation is called a contradiction. This happens when a = c but b ≠ d.

Can I enter a free-form equation like '4(x - 2) = 2x + 6'?

Yes. Switch to free-form input and type the equation directly, including parentheses. The parser expands the parentheses, collects like terms on each side, and solves the resulting equation. Only the single variable x and degree-1 terms are supported.

How accurate is the fraction output?

The solver converts the decimal solution to an exact simplified fraction using a continued-fraction algorithm, capped at a denominator of one million. If no small exact fraction represents the value, the result falls back to decimal display.