Inequality Solver, Explained

After reading this you will be able to solve polynomial and rational inequalities in one variable by hand, write the answer in interval notation, and check the machine's output against a sign chart.

What an inequality solver does

An inequality like x^2 - 4 \ge 0 asks a different question than an equation. An equation asks which values of x make both sides equal. An inequality asks which values make one side larger or smaller than the other. The answer is almost never a short list of points. It is usually a union of intervals.

For x^2 - 4 \ge 0 the solution is every x at least 2 away from 0 in the positive direction or 2 away in the negative direction. In interval notation that is (-\infty, -2] \cup [2, \infty). Test x = 3: 9 - 4 = 5 \ge 0, true. Test x = 0: -4 \ge 0, false. Test x = -3: 9 - 4 = 5 \ge 0, true. The pattern matches the intervals.

The calculator solves such inequalities exactly, reports the solution set in interval notation, and plots the difference of the two sides so you can see where the graph sits above or below zero.

The one move that makes everything work

Every inequality with two sides can be rewritten so that one side is zero. Move all terms to the left:

f(x) \ge g(x) \quad\Longleftrightarrow\quad f(x) - g(x) \ge 0

Here f(x) is the left side, g(x) is the right side, and their difference h(x) = f(x) - g(x) is what you actually analyze. The problem becomes: where is h(x) positive, negative, or zero?

This single step is why the calculator plots the difference. A point on the number line belongs to the solution when the plotted curve is on the correct side of the horizontal axis. For \ge 0 you want the curve at or above the axis.

Rewriting to h(x) \ge 0 avoids the classic trap of multiplying both sides by something that might be negative. You never multiply. You only study the sign of one expression.

Sign charts: the exact method

A continuous expression can only change sign where it crosses zero. A rational expression can also flip sign where its denominator is zero (a vertical asymptote). Those special points are the critical points. Between two neighboring critical points the sign of h(x) never changes, so testing a single value settles the whole interval.

The procedure is short:

  1. Rewrite as h(x) \; \square \; 0 where \square is one of \lt, \gt, \le, \ge.
  2. Find every root of the numerator and every root of the denominator. These are the critical points.
  3. Sort them on the number line. They cut it into open intervals.
  4. Pick one test value inside each interval and evaluate the sign of h(x).
  5. Keep the intervals whose sign matches the inequality. Include a critical point only if the relation is \le or \ge and the point does not make a denominator zero.

That last rule matters. A value that makes a denominator zero is never in the solution set, no matter how the inequality is written, because the expression is undefined there.

Worked example: x^2 - 4 ≥ 0

This is the demo. Enter x^2 - 4 >= 0 and press Calculate.

  1. The expression is already in the form h(x) \ge 0 with h(x) = x^2 - 4.
  2. Factor: x^2 - 4 = (x-2)(x+2). The roots are x = -2 and x = 2. There is no denominator, so those are the only critical points.
  3. They split the line into three intervals: (-\infty, -2), (-2, 2), and (2, \infty).
  4. Test x = -3: (-3)^2 - 4 = 5 \gt 0. Test x = 0: -4 \lt 0. Test x = 3: 5 \gt 0.
  5. Keep the two outer intervals. Because the relation is \ge and neither root is a division problem, include the endpoints.

Solution: (-\infty, -2] \cup [2, \infty). The square brackets mark that -2 and 2 are included.

The parabola sits at or above the axis on the two shaded stretches. It dips below between the roots, which is exactly the excluded interval (-2, 2).

Rational inequalities need extra care

Consider \dfrac{x-1}{x+2} \ge 0. The numerator is zero at x = 1. The denominator is zero at x = -2. Both are critical points, but they behave differently.

Test the three intervals. On (-\infty, -2) pick x = -3: \frac{-4}{-1} = 4 \gt 0. On (-2, 1) pick x = 0: \frac{-1}{2} = -0.5 \lt 0. On (1, \infty) pick x = 2: \frac{1}{4} = 0.25 \gt 0.

Keep the first and third intervals. Now the endpoints. At x = 1 the fraction equals 0, and \ge 0 allows zero, so include it. At x = -2 the fraction is undefined, so exclude it even though the interval on its right is not kept anyway. The answer is (-\infty, -2) \cup [1, \infty).

A denominator root always gets a round bracket. A numerator root gets a square bracket only when the inequality is \le or \ge. Mixing these up is the most common mistake, and it changes the answer by a single point that graders check for.

Watch the sign of factors as x passes a root

A factor raised to an even power does not change the sign of the product when x crosses its root. It only touches zero. Take (x-1)^2 (x+3) \gt 0. The factor (x-1)^2 is never negative. At x = 1 the product is zero, which fails a strict \gt. Away from 1 the sign is decided entirely by (x+3).

So the product is positive when x \gt -3, except at the single point x = 1 where it is zero. The solution is (-3, 1) \cup (1, \infty). The hole at x = 1 is easy to miss if you only track sign changes and forget that an even multiplicity can stop a sign flip.

A sign chart for (x-a)(x-b) with a = -2 and b = 2 shows + on (-inf, -2), then - on (-2, 2), then + on (2, inf), matching the demo solution set for the ≥ 0 case.

Reading the calculator's output

The result is a set written with brackets and the union symbol. Read it left to right along the number line.

Round bracket, ( or )
The endpoint is not included. Used for strict inequalities and for every point that makes a denominator zero.
Square bracket, [ or ]
The endpoint is included. Used for \le and \ge at numerator roots.
Union, \cup
The solution is more than one interval. Each piece is separate on the number line.
Empty set, \varnothing
No value of x works. For example x^2 + 1 \lt 0 has no real solution.
All reals, (-\infty, \infty)
Every value works, as in x^2 + 1 \gt 0.

The plotted curve is the difference h(x). Match the shaded ranges under the curve with the bracket type in the text and you have a full check.

Common mistakes

Three errors account for most wrong answers.

Multiplying across an inequality by an unknown. If you multiply \frac{x-1}{x+2} \ge 0 by x+2, the direction of the inequality depends on the sign of x+2, which is exactly what you do not know yet. Rewrite as h(x) \ge 0 instead and never multiply.

Flipping only sometimes. When you multiply or divide both sides by a negative constant, the relation reverses: -2x \lt 6 becomes x \gt -3. A positive constant leaves it alone. Check with a value: x = 0 gives 0 \lt 6, true, and 0 \gt -3, also true.

Including an undefined point. A value that makes a denominator zero is never a solution. The graph has no height there, so no bracket, ever.

Related tools

Finding the critical points is a root-finding problem, so these calculators pair naturally with this one. Use the Quadratic equation solver for the roots of a degree-2 numerator, and the Equation solver for higher-degree polynomials. To factor before you build a sign chart, reach for the Polynomial toolkit. When a rational inequality has a messy fraction, the Partial fraction decomposition tool can simplify the structure first. If your inequality involves exponentials or logs, convert it with the Exponent and logarithm calculator.

Frequently asked questions

Why is the answer written with intervals instead of a number?

An inequality is satisfied by a range of values, not a single one. For x^2 - 4 \ge 0 there are infinitely many solutions, so the compact way to list them is interval notation: (-\infty, -2] \cup [2, \infty).

When do I use square brackets versus round brackets?

Square brackets include the endpoint, round brackets exclude it. Include a numerator root when the relation is \le or \ge. Always exclude infinity and always exclude points that make a denominator zero.

Can I just multiply both sides to clear the fraction?

Not safely. Multiplying by an expression whose sign you do not know can flip the inequality the wrong way. Move everything to one side, form h(x), and study its sign with a chart.

What does it mean if the solver returns the empty set?

No real value satisfies the inequality. For example x^2 \lt -1 is impossible, since a square is never negative, so the result is \varnothing.

How do I check the machine's answer quickly?

Pick one number from each interval the solver reports and one from each gap it left out. Plug them into the original inequality. Every reported number should make it true, every excluded number should make it false.