Graphing Quadratic Inequalities Calculator
Enter the coefficients of your quadratic expression and choose an inequality sign. The calculator solves ax² + bx + c [sign] d by finding the parabola's roots, working out the discriminant, and returning the solution set in interval notation. A step-by-step panel shows every line of working so you can follow along or check your own algebra.
Formula
Worked example
Solve x² - 3x + 2 < 0. Here a=1, b=-3, c=2, d=0. The discriminant is (-3)² - 4(1)(2) = 9 - 8 = 1 > 0, giving roots x = (3 - 1)/2 = 1 and x = (3 + 1)/2 = 2. Because a > 0 the parabola opens upward, so the expression is negative between the roots. The solution is the open interval (1, 2).
What is a quadratic inequality?
A quadratic inequality is a statement that compares a quadratic expression to a number using one of the four signs: <, <=, > or >=. The general form is ax² + bx + c [sign] d, where a is not zero. Unlike a quadratic equation, which has a finite set of solutions (the roots), a quadratic inequality typically has an infinite set of x-values that make it true, and the solution is written as one or two intervals on the number line. The shape of the parabola y = ax² + bx + c is the key to reading off the answer: because the curve is continuous and opens either upward (a > 0) or downward (a < 0), the regions where it lies above or below the line y = d form a connected pattern that depends only on where the two curves intersect.
How to solve a quadratic inequality by graphing
The graphical method has four steps:
- Rewrite as f(x) [sign] 0. Move d to the left: ax² + bx + (c - d) [sign] 0. You now have a shifted parabola to compare against the x-axis.
- Find the roots. Solve ax² + bx + (c - d) = 0 using the quadratic formula: x = (-b plus-or-minus sqrt(b² - 4a(c - d))) / (2a). The discriminant b² - 4a(c - d) tells you how many roots there are: positive gives two, zero gives one, negative gives none.
- Sketch the parabola. Plot the vertex at x = -b / (2a) and mark the roots on the x-axis. The parabola opens upward when a > 0 and downward when a < 0.
- Read off the solution. For f(x) < 0, shade where the parabola lies below the x-axis. For f(x) > 0, shade where it lies above. For strict inequalities (< or >), the boundary points are open circles (excluded). For non-strict (<= or >=), they are filled circles (included).
Understanding the discriminant and its role
The discriminant, written as the Greek letter delta or as b² - 4ac, controls the number of real roots and therefore the shape of the solution:
- Delta > 0: Two distinct roots. The solution is one of two types: an interval between the roots, or two separate rays extending outward from them, depending on the direction of the inequality and the sign of a.
- Delta = 0: One repeated root. The parabola just touches the x-axis. For a strict inequality (< or >) the single touching point gives no room to satisfy the condition, so the answer is either no solution or a single point depending on the direction.
- Delta < 0: No real roots. The parabola lies entirely above the x-axis (when a > 0) or entirely below it (when a < 0). The solution is then either all real numbers or the empty set, with nothing in between.
Interval notation and how to read the output
This calculator expresses solutions in interval notation, a compact standard used across algebra and calculus:
- Round brackets ( ) mean the endpoint is excluded (strict inequality).
- Square brackets [ ] mean the endpoint is included (non-strict inequality).
- -inf and +inf are always written with round brackets because infinity is never reached.
- U denotes the union of two disjoint intervals, for example (-inf, 1) U (2, +inf) means all x below 1 or above 2.
- All real numbers means every x satisfies the inequality. No solution means none do.
Solution cases for ax² + bx + c [sign] 0
| Discriminant | Sign of a | Inequality | Solution set |
|---|---|---|---|
| > 0 (two roots) | a > 0 | < or <= | Between the roots |
| > 0 (two roots) | a > 0 | > or >= | Outside the roots (two intervals) |
| > 0 (two roots) | a < 0 | < or <= | Outside the roots (two intervals) |
| > 0 (two roots) | a < 0 | > or >= | Between the roots |
| = 0 (one root) | a > 0 | < | No solution |
| = 0 (one root) | a > 0 | <= | Single point {x = r} |
| = 0 (one root) | a < 0 | > | No solution |
| = 0 (one root) | a < 0 | >= | Single point {x = r} |
| < 0 (no roots) | a > 0 | < or <= | No solution |
| < 0 (no roots) | a > 0 | > or >= | All real numbers |
| < 0 (no roots) | a < 0 | < or <= | All real numbers |
| < 0 (no roots) | a < 0 | > or >= | No solution |
Quick reference for the six possible outcome types based on discriminant and sign of a.
Frequently asked questions
How do I solve x² - 3x + 2 < 0?
Enter a=1, b=-3, c=2, sign=<, d=0. The discriminant is 9 - 8 = 1, giving roots x = 1 and x = 2. Because a > 0 the parabola opens upward and is negative between its roots, so the solution is the open interval (1, 2).
What happens when the discriminant is negative?
When the discriminant (b² - 4a(c - d)) is negative, the parabola has no real roots and never crosses the comparison line y = d. If a > 0, the parabola is entirely above the line, so inequalities asking for the expression to be positive are satisfied for all x, and those asking for it to be negative have no solution. The opposite holds when a < 0.
What is the difference between < and <= in the solution set?
For a strict inequality (< or >) the roots (boundary points) are excluded, and the interval uses round brackets. For a non-strict inequality (<= or >=) the roots are included, and the interval uses square brackets. For example, x² - 1 < 0 gives (-1, 1) while x² - 1 <= 0 gives [-1, 1].
Can I solve inequalities where d is not zero?
Yes. The calculator solves ax² + bx + c [sign] d for any value of d. Internally it subtracts d from both sides to get ax² + bx + (c - d) [sign] 0, then finds the roots of that shifted equation. Graphically, d determines the height of the horizontal comparison line against which the parabola is measured.
Why does the solution sometimes say "all real numbers"?
This happens when the parabola lies entirely on one side of the comparison line. For instance, x² + 1 > 0 is always true because x² + 1 is at least 1 for every real x, so the solution is all real numbers. It also appears for discriminant-negative cases where the inequality is pointing in the same direction as the parabola's position.
How do I verify my solution?
Pick any x-value inside the solution interval and substitute it into the original inequality. For example, if the solution is (1, 2), try x = 1.5: compute 1.5² - 3(1.5) + 2 = 2.25 - 4.5 + 2 = -0.25. Since -0.25 < 0, the inequality is satisfied. Also test a value outside the interval (say x = 0) to confirm it does NOT satisfy the inequality.
Does this calculator handle quadratic expressions with no x² term (a = 0)?
Setting a = 0 reduces the expression to a linear one (bx + c compared to d). The calculator handles this as a limiting case, finding at most one root. For a proper linear inequality solver, a dedicated linear inequality tool may be more appropriate.