Interval Defined by Betweenness
Lemma
Let $S \subseteq \R$ be a non-empty subset of $\R$.
Then $S$ is an interval of $\R$ iff it satisfies this property:
If $x, y \in S$ and $z \in \R$ such that $x < z < y$, then $z \in S$.
Proof
- If $S$ is a real interval of any of the various kinds, then it clearly has this property by definition.
- Suppose $S$ has this property.
Let:
- $a = \inf \left({S}\right)$ (or $a = -\infty$ if $S$ is not bounded below);
- $b = \sup \left({S}\right)$ (or $b = +\infty$ if $S$ is not bounded above).
We will prove that $\left({a \, . \, . \, b}\right) \subseteq S \subseteq \left[{a \, . \, . \, b}\right]$.
In order not to need to provide lots of lists of cases, we make the temporary conventions:
- A square bracket "$[$" or "$]$" next to $\pm \infty$ means the same as a round bracket "$($" or "$)$";
- $\left({a \, . \, . \, b}\right)$ means $\varnothing$ iff $a = b$.
Let $z \in \left({a \, . \, . \, b}\right)$.
Then $z > a$, so $\exists x \in S: x < z$ by definition of $a$.
Similarly $z < b$, so $\exists y \in S: z < y$ by definition of $b$.
Hence by hypothesis $z \in S$.
This proves that $\left({a \, . \, . \, b}\right) \subseteq S$.
From the definitions of $a$ and $b$ it follows that $S \subseteq \left[{a \, . \, . \, b}\right]$.
But if $\left({a \, . \, . \, b}\right) \subseteq S \subseteq \left[{a \, . \, . \, b}\right]$, then $S$ must be one of the various types of real interval.
$\blacksquare$