Solve and checkLesson 17 of 48 · 7 min
Solve an inequality as a region
Read an inequality solution as intervals with explicit endpoints.
Maths refresher: Intervals and strict boundaries
An interval contains a range of real numbers. A strict inequality excludes equality at its boundary.
Combining with gives . The value 2 is excluded, while 1 is included.
An inequality describes a region, not usually a list of isolated roots. Its boundary depends on whether equality is included. Multiplying an inequality by an expression of unknown sign can reverse or invalidate a hand calculation.
reduce_inequalities can reduce suitable one-variable inequalities to logical conditions. The example combines a strict quadratic condition with a non-strict lower bound. Read the intersection of both requirements rather than treating the outputs as alternatives.
The real number line is the domain here. Test boundary points deliberately: satisfies both conditions, while fails the strict quadratic condition. Later, changing a strict sign changes which endpoints belong.
Does include either endpoint -3 or 3?
Write a prediction (optional)
Exact symbolic investigation
Select Run Python with the code unchanged.
Your saved draft is open. To use the published code, select Restore example in Tools. Use Recover draft to bring back your code.
Tools
About Python
Python and the course packages can load while you read. Each run starts with fresh user variables; imported modules stay loaded. Stop replaces the worker. Runtime details ↗
Ctrl+Enter or ⌘+Enter runs Python.
Execution error
Technical error details
Your result
Python text output
Compare with the worked example
Executed from the published Python during the site build. Your own run appears above. Build environment ↗
Worked text output
Permitted region: (1 <= x) & (x < 3) At 1: True At 3: False
Read the starter result
Read Permitted region as simultaneous conditions on real x. Check At 1 and At 3 to confirm which endpoints belong.
Edit and compare
In reduce_inequalities, replace x**2<9 with x**2<=9. Select Run Python. Compare Permitted region and At 3 with the first run. Which boundary changed?
Scope. This lesson covers supported univariate real inequalities; coupled multivariate inequality systems require other methods.
Try a fresh case
What region satisfies together with ?
Need a hint?
Hint 1
Intersect the two permitted regions.
Hint 2
Check each endpoint separately.