What an interval is
Definition
An interval represents a set of real numbers lying between two given real values.
Types
→ Open $(\;,\;)$: the endpoints are not included.
→ Half-open $(\;,\;]$ and $[\;,\;)$: one endpoint is included.
→ Closed $[\;,\;]$: both endpoints are included.
A square bracket means "this endpoint is in" and a round bracket, "this endpoint is out". On the line we draw a solid dot or a hollow one.
Notation
| Interval | Set notation | Real line |
|---|---|---|
| $(a,\, b)$ | $\{a < x < b \mid x \in \mathbb{R}\}$ | |
| $[a,\, b)$ | $\{a \le x < b \mid x \in \mathbb{R}\}$ | |
| $(a,\, b]$ | $\{a < x \le b \mid x \in \mathbb{R}\}$ | |
| $[a,\, b]$ | $\{a \le x \le b \mid x \in \mathbb{R}\}$ |
Example
| Interval | Set notation | Real line |
|---|---|---|
| $[0,\, 5)$ | $\{0 \le x < 5 \mid x \in \mathbb{R}\}$ |
The $0$ is in and the $5$ is out: $4{,}999\ldots$ belongs to it, $5$ does not.
Union and intersection
Union $\cup$
The union of two intervals $A$ and $B$ is made of the values that are in $A$ or in $B$.
Example
The two intervals overlap, so the union is a single interval: it starts where the first one starts and ends where the second one ends.
Intersection $\cap$
The intersection of two intervals $A$ and $B$ is made of the values that are in $A$ and in $B$ at the same time.
Example
The intersection is the stretch they share: it starts at the later start and ends at the earlier end. Each endpoint keeps the bracket it had in its own interval.