How to use the Linear Equation Solver
- Rearrange your equation until everything with an x sits on the left and the plain numbers on the right.
- Enter a, the number multiplying x. If x appears alone, a is 1; if the term is −x, a is −1.
- Enter b, the constant that remains on the left after rearranging. Include its sign.
- Enter c, the value on the right of the equals sign.
- Read x. If a is zero the calculator reports 'no solution' or 'any value' instead of dividing by zero.
How the calculation works
A linear equation in one variable has exactly one x term and no powers, roots or products of variables. Solving it is a two-move procedure: undo the addition, then undo the multiplication. Subtracting b from both sides isolates the ax term, and dividing both sides by a isolates x. Because both operations are applied to the whole of each side, the equality is preserved at every step — that is the entire justification for the method.
The interesting cases are the degenerate ones. If a is zero, x has vanished from the equation entirely and the statement reduces to b = c. When that is true, every real number satisfies it and the solution set is infinite. When it is false, nothing satisfies it and the solution set is empty. Software that blindly computes (c − b)/a returns Infinity or NaN here; classifying the case explicitly is the mathematically correct behaviour and the reason this calculator checks a before dividing.
Real problems rarely arrive in ax + b = c shape. Getting there means clearing fractions by multiplying through by the common denominator, expanding brackets with the distributive law, and collecting like terms on the correct side. Those manipulations are where errors happen; the final division almost never is. If a check by substitution fails, retrace the rearrangement rather than the arithmetic.
x = (c − b) / a, provided a ≠ 0Source: Standard result of elementary algebra; see any secondary-level algebra text, e.g. OpenStax Elementary Algebra 2e, Section 2.3.
Worked example
A taxi charges a $4.50 flag fall plus $2.20 per kilometre. How far can you travel on a $30 budget?
- Model the fare: 2.20x + 4.50 = 30, so a = 2.20, b = 4.50, c = 30.
- Subtract the flag fall: 2.20x = 25.50.
- Divide by the per-kilometre rate: x = 25.50 / 2.20.
- Check by substituting back: 2.20 × 11.59 + 4.50 = 30.00.
11.59 km — round down to 11.5 km, because fares are charged in increments and you do not want to arrive short of the fare.
Frequently asked questions
What if x appears on both sides?+
Collect it first. For 5x + 3 = 2x + 18, subtract 2x from both sides to get 3x + 3 = 18, then enter a = 3, b = 3, c = 18.
Why does the calculator sometimes say 'any value'?+
Because a is zero and b equals c, so the equation is an identity such as 7 = 7. It is true regardless of x, so every real number is a solution.
Can it handle fractions and decimals?+
Yes. Enter them directly as decimals. For a fractional coefficient like 2/3, enter 0.666667, or multiply the whole equation by 3 first for an exact result.
Is this the same as solving for y in y = mx + b?+
Related but not identical. That form evaluates y from a known x. This calculator does the reverse: it finds the x that produces a target value.
Last reviewed August 31, 2026. We review this page whenever the underlying formula, tax year, published rate or standard changes.