Calcist

Style

Buttons

Spacing

How much to show

Decimal places

Text size

Inequality solver

Solve a linear or quadratic inequality in x, with every step, interval notation and a number line.

a·x + b  (sign)  c·x + d

Private: calculated on your device. Nothing you type is sent anywhere.

Next: Solving an equation instead? Use the equation solver, or see the parabola on the graphing calculator.

What this inequality solver does

It solves linear inequalities like 3x + 4 < x − 2 and quadratic inequalities like x² − 5x + 6 < 0, one step at a time. You get the answer as an inequality, in interval notation and on a number line, with a check you can do by hand. Fractions are kept exact.

How linear inequalities are solved

Solve them like equations: get the x terms on one side and the numbers on the other. There's one extra rule.

If you multiply or divide both sides by a negative number, flip the inequality sign.

Why? Multiplying by a negative number reverses the order of numbers on the number line. 2 < 5 is true, but after multiplying by −1 you get −2 and −5, and −2 is bigger. So −2 > −5. Adding or subtracting never flips the sign, and neither does multiplying or dividing by a positive number.

Worked example

Solve −2x + 5 ≥ 11.

  1. Subtract 5 from both sides: −2x ≥ 6.
  2. Divide both sides by −2. It's negative, so ≥ becomes ≤: x ≤ −3.
  3. In interval notation: (−∞, −3]. The bracket means −3 is included.
  4. Check with x = −4: −2(−4) + 5 = 13, and 13 ≥ 11 is true.

How quadratic inequalities are solved

Move everything to one side so you're comparing ax² + bx + c with 0. If a is negative, multiply everything by −1 and flip the sign, so the parabola opens upward. Then:

  1. Find the roots of ax² + bx + c = 0 with the quadratic formula, x = (−b ± √(b² − 4ac)) ÷ 2a.
  2. The roots split the number line into intervals. The sign of the expression can only change at a root.
  3. Test one point in each interval, and keep the intervals with the sign you want.

For x² − 5x + 6 < 0 the roots are 2 and 3. Testing x = 0 gives 6 (positive), x = 2.5 gives −0.25 (negative) and x = 4 gives 2 (positive). So the answer is 2 < x < 3, or (2, 3).

Upward parabola, roots r₁ < r₂Solution
< 0(r₁, r₂)
≤ 0[r₁, r₂]
> 0(−∞, r₁) ∪ (r₂, ∞)
≥ 0(−∞, r₁] ∪ [r₂, ∞)
No real roots, > 0 or ≥ 0All real numbers
No real roots, < 0 or ≤ 0No solution

Interval notation in one minute

A parenthesis ( ) means the endpoint isn't included (< or >). A square bracket [ ] means it is (≤ or ≥). Infinity always gets a parenthesis, because it isn't a number you can reach. ∪ joins two pieces.

Limitations

  • One variable, x, with a linear or quadratic expression. Rational inequalities (x in a denominator), absolute values and systems of inequalities aren't covered.
  • Coefficients can be whole numbers or decimals up to about a trillion. Answers stay exact; irrational roots are shown in square-root form with a decimal value.

Sources

How we checked this

Before every update, this calculator is run in a real browser with these known answers, and it must match all of them:

  • 3x + 4 < x − 2 gives x < −3, or (−∞, −3) ✓
  • −2x + 5 ≥ 11: dividing by −2 flips the sign, so x ≤ −3 ✓
  • 0.5x − 1 ≤ 2 gives x ≤ 6 ✓
  • x² − 5x + 6 < 0 gives (2, 3) ✓
  • x² − 5x + 6 ≥ 0 gives (−∞, 2] ∪ [3, ∞) ✓
  • x² − 2 ≤ 0 gives [−√2, √2] ✓
  • −x² + 4 > 0 flips to x² − 4 < 0: (−2, 2) ✓
  • Edge: x² + 1 < 0 has no solution ✓
  • Edge: 2x + 3 > 2x + 1 is true for every x ✓

Last checked October 26, 2026. Spotted something wrong? The math is done in your browser with the formula shown on this page, so you can check any result by hand.

Add this calculator to your website (free)

Paste this code into any web page. The calculator works on your page, resizes itself, has no ads and no tracking, and nothing your visitors type is sent anywhere. More about embedding.

Questions people ask

When do you flip the inequality sign?

Only when you multiply or divide both sides by a negative number. Adding, subtracting, or multiplying and dividing by a positive number keeps the sign as it is.

How do you write an inequality in interval notation?

Write the smallest and largest values with a comma between them. Use ( or ) when the endpoint isn't included and [ or ] when it is. x ≥ 2 becomes [2, ∞), and −1 < x ≤ 4 becomes (−1, 4].

How do you solve a quadratic inequality?

Move everything to one side, find the roots of the quadratic, then test a number in each interval between the roots. Keep the intervals where the inequality is true.

What if the x terms cancel out?

Then you're left with a statement about numbers, like 3 > 1 or 3 < 1. If it's true, every real number is a solution. If it's false, there's no solution.

Related calculators