Inequality Calculator — Linear & Compound, Step-by-Step

Solve linear and compound linear inequalities step by step. Automatic sign-flip handling on negative multiplication/division, plus correct interval notation.

Enter the inequality a·x + b < c — for example a = -2, b = 3, operator <, c = 7 means -2x + 3 < 7.

Solving — Step by Step

Original inequality:

-2x + 3 < 7

1

Subtract b from both sides

-2x < 4

2

Divide both sides by a (-2) — negative, so the inequality flips

Dividing by a negative number reverses the inequality: < becomes >

x > -2

Solution (interval notation):

x > -2(-2, ∞)

Solves standard linear inequalities (ax + b vs. c, using <, >, ≤, or ≥) and compound linear inequalities (a < mx + b < c). Multiplying or dividing both sides by a negative number flips the inequality direction — this calculator always shows that step explicitly. Not intended for quadratic, absolute-value, or multi-variable inequalities. For differentiating composite functions instead of solving inequalities, see the companion Chain Rule Calculator.

91% found this helpful

Reference Values

Last verified:
Category Range What It Means Status
Adding or subtracting a term No flip Adding or subtracting the same number from both sides of an inequality never changes which direction the inequality symbol points. Good
Multiplying/dividing by a positive number No flip Multiplying or dividing both sides by a positive number preserves the inequality's direction, just like solving an equation. Good
Multiplying/dividing by a negative number **Flip required** The inequality symbol must reverse direction (< becomes >, ≤ becomes ≥, and vice versa) any time you multiply or divide both sides by a negative number. This is the single most common error students make when solving linear inequalities. ★ Best
Strict inequality (< or >) Parenthesis ( ) Interval notation uses a parenthesis on any boundary that is NOT included in the solution set — the value is approached but never reached. Good
Non-strict inequality (≤ or ≥) **Square bracket [ ]** Interval notation uses a square bracket on any boundary that IS included in the solution set. Good
Infinity (∞ or −∞) **Always a parenthesis** Infinity is a concept, not a reachable number, so it is always written with a parenthesis in interval notation — never a square bracket — regardless of whether the inequality itself is strict or non-strict. ★ Best

Source: Sign-flip rule and interval notation convention cross-checked against Pearson Channels' linear inequalities lessons (channels.pearson.com) and LibreTexts Mathematics, "Inequalities, Number Lines, and Interval Notation."

Worked Examples

Simple Inequality — No Sign Flip

Inequality
3x + 4 < 19
x < 5 → (-∞, 5)

Subtract 4 from both sides: 3x < 15. Divide by 3 — since 3 is positive, the symbol stays the same: x < 5.

Simple Inequality — Sign Flip Required

Inequality
-2x + 5 ≥ -3
x ≤ 4 → (-∞, 4]

Subtract 5 from both sides: -2x ≥ -8. Divide by -2 — because we're dividing by a negative number, ≥ flips to ≤: x ≤ 4.

Simple Inequality — Strict, No Flip

Inequality
5x - 7 > 3
x > 2 → (2, ∞)

Add 7 to both sides: 5x > 10. Divide by 5 — positive coefficient, no flip: x > 2.

Simple Inequality — Sign Flip with Negative Coefficient

Inequality
-4x - 1 ≤ 11
x ≥ -3 → [-3, ∞)

Add 1 to both sides: -4x ≤ 12. Divide by -4 — dividing by a negative flips ≤ to ≥: x ≥ -3.

Compound Inequality — Sign Flip on All Three Parts

Compound Inequality
-4 < -3x + 2 ≤ 11
-3 ≤ x < 2 → [-3, 2)

Subtract 2 from all three parts: -6 < -3x ≤ 9. Divide all three by -3 — both inequality symbols flip: 2 > x ≥ -3. Reordering ascending gives -3 ≤ x < 2.

How to Use This Calculator

  1. 1

    Choose Simple or Compound mode

    Simple mode solves ax + b compared to c. Compound mode solves a < mx + b < c, where the variable is sandwiched between two bounds.

  2. 2

    Enter the coefficients and operator

    For simple mode: a, b, the comparison operator (<, >, ≤, ≥), and c. For compound mode: the left bound L, m, b, the right bound R, and the two operators.

  3. 3

    Read each algebra step

    The calculator shows subtracting the constant, then dividing by the coefficient, exactly like solving by hand.

  4. 4

    Watch for the flip warning

    If the coefficient you divide by is negative, a red flip notice appears explaining exactly which symbol changed and why.

  5. 5

    Read the interval notation result

    The final answer is shown both as an inequality (like x > -3) and in interval notation (like (-3, ∞)), using parentheses for strict bounds and brackets for inclusive bounds.

What Each Value Means

Sign-Flip Rule (rule)
The algebra rule stating that multiplying or dividing both sides of an inequality by a negative number reverses the inequality's direction (< ↔ >, ≤ ↔ ≥), while addition and subtraction never do.
Interval Notation (notation)
A compact way to write an inequality's solution set as a range of numbers, using parentheses for excluded (strict) boundaries and square brackets for included (non-strict) boundaries — infinity always gets a parenthesis.
Compound Inequality (expression)
An inequality with three parts chained together (a < mx + b < c), meaning the middle expression must satisfy both bounds at once. Solved by applying the same operation to all three parts simultaneously.

Frequently Asked Questions

What is the sign-flip rule for inequalities?
Whenever you multiply or divide both sides of an inequality by a negative number, the inequality symbol must reverse direction — < becomes >, ≤ becomes ≥, and vice versa. Adding or subtracting a number never flips the symbol, no matter the sign. For example, -2x < 6 divided by -2 becomes x > -3 (the < flipped to >), because dividing by a negative number reverses the order of every value on the number line.
How does interval notation work — when do I use parentheses vs. brackets?
Use a parenthesis ( or ) when the boundary value is not included in the solution (strict inequalities, < or >). Use a square bracket [ or ] when the boundary value is included (non-strict inequalities, ≤ or ≥). Infinity is always written with a parenthesis, since infinity isn't a number you can actually reach — for example, x ≥ 4 is written [4, ∞), never [4, ∞].
How do I solve a compound inequality like a < mx + b < c?
Treat all three parts as one chain and apply the same operation to all three simultaneously. Subtract b from all three parts first, then divide all three parts by m. If m is positive, both inequality symbols keep their direction. If m is negative, both symbols flip at once, and you then reorder the chain so the smaller bound is written first — this calculator shows both the flip step and the reorder step explicitly when m is negative.
Can this calculator solve quadratic, absolute-value, or system-of-inequality problems?
No — this tool is scoped to single-variable linear inequalities (ax + b compared to c) and compound linear inequalities (a < mx + b < c). Quadratic inequalities (like x² - 4 > 0) require sign-chart analysis of the factored roots, and absolute-value inequalities split into two separate cases, both of which use different solving methods than the linear elimination steps shown here. Systems of inequalities require graphing overlapping solution regions in two variables. Each of those is a different algebra topic with its own procedure.
Why does subtracting a number never flip an inequality, but dividing sometimes does?
Addition and subtraction shift every point on the number line by the same amount without changing the distance or order between any two points, so the inequality's direction is preserved. Multiplying or dividing by a negative number, however, reflects every point across zero — what used to be the larger value becomes the smaller value. Since 5 > 3 becomes -5 < -3 after multiplying both sides by -1, the inequality symbol has to flip to keep describing the same true relationship.