Topology (Munkres)

§14 The Order Topology

Definition 127
more_than_one_element

$X$ has more than one element iff there exist $x, y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\class{latex-symbol-tip latex-symbol-id-neq}{\neq} y$.

LaTeX source
\begin{definition}
\label{more_than_one_element}
    $X$ has more than one element iff there exist $x, y\in X$ such that $x\neq y$.
\end{definition}
Definition 128
largest_element

$b$ is a largest element of $X$ with respect to $R$ iff $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ and for all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ we have $x\mathrel{R}b$ or $x = b$.

LaTeX source
\begin{definition}
\label{largest_element}
    $b$ is a largest element of $X$ with respect to $R$ iff
    $b\in X$ and for all $x\in X$ we have $x\mathrel{R}b$ or $x = b$.
\end{definition}
Definition 129
intervalopen_rel

$\intervalopenrel{R}{X}{a}{b} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid a\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-land}{\land} x\mathrel{R}b\}$.

LaTeX source
\begin{definition}
\label{intervalopen_rel}
    $\intervalopenrel{R}{X}{a}{b} = \{x\in X \mid a\mathrel{R}x \land x\mathrel{R}b\}$.
\end{definition}
Definition 130
intervalopenclosed_rel

$\intervalopenclosedrel{R}{X}{a}{b} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid a\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-land}{\land} (x\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b)\}$.

LaTeX source
\begin{definition}
\label{intervalopenclosed_rel}
    $\intervalopenclosedrel{R}{X}{a}{b} = \{x\in X \mid a\mathrel{R}x \land (x\mathrel{R}b \lor x = b)\}$.
\end{definition}
Definition 131
intervalclosedopen_rel

$\intervalclosedopenrel{R}{X}{a}{b} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid (a\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = a) \class{latex-symbol-tip latex-symbol-id-land}{\land} x\mathrel{R}b\}$.

LaTeX source
\begin{definition}
\label{intervalclosedopen_rel}
    $\intervalclosedopenrel{R}{X}{a}{b} = \{x\in X \mid (a\mathrel{R}x \lor x = a) \land x\mathrel{R}b\}$.
\end{definition}
Definition 132
intervalclosed_rel

$\intervalclosedrel{R}{X}{a}{b} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid (a\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = a) \class{latex-symbol-tip latex-symbol-id-land}{\land} (x\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b)\}$.

LaTeX source
\begin{definition}
\label{intervalclosed_rel}
    $\intervalclosedrel{R}{X}{a}{b} = \{x\in X \mid (a\mathrel{R}x \lor x = a) \land (x\mathrel{R}b \lor x = b)\}$.
\end{definition}
Definition 133
order_basis

$\orderBasis{R}{X} = \{B\class{latex-symbol-tip latex-symbol-id-in}{\in}\pow{X} \mid (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0})\}$.

LaTeX source
\begin{definition}
\label{order_basis}
    $\orderBasis{R}{X} = \{B\in\pow{X} \mid
        (\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}) \lor
        (\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}) \lor
        (\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0})\}$.
\end{definition}
Definition 134
order_topology

$T$ is the order topology on $X$ with respect to $R$ iff $R$ is a simple order relation on $X$ and $X$ has more than one element and $T = \basisTopology{\orderBasis{R}{X}}{X}$.

LaTeX source
\begin{definition}
\label{order_topology}
    $T$ is the order topology on $X$ with respect to $R$ iff
    $R$ is a simple order relation on $X$ and
    $X$ has more than one element and
    $T = \basisTopology{\orderBasis{R}{X}}{X}$.
\end{definition}
Lemma 100
more_than_one_element_has_other

Assume $X$ has more than one element.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Then there exists $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $y\class{latex-symbol-tip latex-symbol-id-neq}{\neq} x$.

LaTeX source
\begin{lemma}
\label{more_than_one_element_has_other}
    Assume $X$ has more than one element.
    Suppose $x\in X$.
    Then there exists $y\in X$ such that $y\neq x$.
\end{lemma}
Proof

Follows by Definition 127.

LaTeX source
\begin{proof}
    Follows by \cref{more_than_one_element}.
\end{proof}
Lemma 101
non_smallest_has_predecessor

Assume $R$ is a simple order relation on $X$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Suppose $x$ is not a smallest element of $X$ with respect to $R$.
Then there exists $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $y\mathrel{R}x$.

LaTeX source
\begin{lemma}
\label{non_smallest_has_predecessor}
    Assume $R$ is a simple order relation on $X$.
    Suppose $x\in X$.
    Suppose $x$ is not a smallest element of $X$ with respect to $R$.
    Then there exists $y\in X$ such that $y\mathrel{R}x$.
\end{lemma}
Proof

Follows by Definition 40, Definition 98, Definition 99.

LaTeX source
\begin{proof}
    Follows by \cref{simple_order_relation,connex,smallest_element}.
\end{proof}
Lemma 102
non_largest_has_successor

Assume $R$ is a simple order relation on $X$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Suppose $x$ is not a largest element of $X$ with respect to $R$.
Then there exists $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}y$.

LaTeX source
\begin{lemma}
\label{non_largest_has_successor}
    Assume $R$ is a simple order relation on $X$.
    Suppose $x\in X$.
    Suppose $x$ is not a largest element of $X$ with respect to $R$.
    Then there exists $y\in X$ such that $x\mathrel{R}y$.
\end{lemma}
Proof

Follows by Definition 40, Definition 98, Definition 128.

LaTeX source
\begin{proof}
    Follows by \cref{simple_order_relation,connex,largest_element}.
\end{proof}
Lemma 103
intervalopenrel_subset_by_endpoints

Assume $R$ is transitive.
Suppose $a,a_1,b,b_1\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Suppose $a_1\mathrel{R}a$ or $a_1 = a$.
Suppose $b\mathrel{R}b_1$ or $b = b_1$.
Then $\intervalopenrel{R}{X}{a}{b} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} \intervalopenrel{R}{X}{a_1}{b_1}$.

LaTeX source
\begin{lemma}
\label{intervalopenrel_subset_by_endpoints}
    Assume $R$ is transitive.
    Suppose $a,a_1,b,b_1\in X$.
    Suppose $a_1\mathrel{R}a$ or $a_1 = a$.
    Suppose $b\mathrel{R}b_1$ or $b = b_1$.
    Then $\intervalopenrel{R}{X}{a}{b} \subseteq \intervalopenrel{R}{X}{a_1}{b_1}$.
\end{lemma}
Proof

Follows by Definition 1, Definition 37 [Transitivity], Definition 129.

LaTeX source
\begin{proof}
    Follows by \cref{intervalopen_rel,subseteq,transitive}.
\end{proof}
Lemma 104
intervalclosedopenrel_subset_by_right

Assume $R$ is transitive.
Suppose $a,b,b_1\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Suppose $b\mathrel{R}b_1$ or $b = b_1$.
Then $\intervalclosedopenrel{R}{X}{a}{b} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} \intervalclosedopenrel{R}{X}{a}{b_1}$.

LaTeX source
\begin{lemma}
\label{intervalclosedopenrel_subset_by_right}
    Assume $R$ is transitive.
    Suppose $a,b,b_1\in X$.
    Suppose $b\mathrel{R}b_1$ or $b = b_1$.
    Then $\intervalclosedopenrel{R}{X}{a}{b} \subseteq \intervalclosedopenrel{R}{X}{a}{b_1}$.
\end{lemma}
Proof

Follows by Definition 1, Definition 37 [Transitivity], Definition 131.

LaTeX source
\begin{proof}
    Follows by \cref{intervalclosedopen_rel,subseteq,transitive}.
\end{proof}
Lemma 105
intervalopenclosedrel_subset_by_left

Assume $R$ is transitive.
Suppose $a,a_1,b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Suppose $a_1\mathrel{R}a$ or $a_1 = a$.
Then $\intervalopenclosedrel{R}{X}{a}{b} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} \intervalopenclosedrel{R}{X}{a_1}{b}$.

LaTeX source
\begin{lemma}
\label{intervalopenclosedrel_subset_by_left}
    Assume $R$ is transitive.
    Suppose $a,a_1,b\in X$.
    Suppose $a_1\mathrel{R}a$ or $a_1 = a$.
    Then $\intervalopenclosedrel{R}{X}{a}{b} \subseteq \intervalopenclosedrel{R}{X}{a_1}{b}$.
\end{lemma}
Proof

Follows by Definition 1, Definition 37 [Transitivity], Definition 130.

LaTeX source
\begin{proof}
    Follows by \cref{intervalopenclosed_rel,subseteq,transitive}.
\end{proof}
Lemma 106
orderbasis_elem_at_smallest

Assume $R$ is a simple order relation on $X$.
Suppose $x$ is a smallest element of $X$ with respect to $R$.
Suppose $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B$.
Then there exists $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}b$ and $B = \intervalclosedopenrel{R}{X}{x}{b}$.

LaTeX source
\begin{lemma}
\label{orderbasis_elem_at_smallest}
    Assume $R$ is a simple order relation on $X$.
    Suppose $x$ is a smallest element of $X$ with respect to $R$.
    Suppose $B\in\orderBasis{R}{X}$.
    Suppose $x\in B$.
    Then there exists $b\in X$ such that $x\mathrel{R}b$ and $B = \intervalclosedopenrel{R}{X}{x}{b}$.
\end{lemma}
Proof

$((\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}))$ by Definition 133.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}$.

Take $a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
Then $a\mathrel{R}x$ by Definition 129.
$x\mathrel{R}a$ or $x = a$ by Definition 99.
Suppose not.
Contradiction by Definition 36, Definition 98.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}$.

Take $a_0, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
Then $(a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = a_0)$ and $x\mathrel{R}b$ by Definition 131.
Hence $a_0 = x$ by Definition 36, Definition 98, Definition 99, Definition 131.
Therefore there exists $c\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}c$ and $B = \intervalclosedopenrel{R}{X}{x}{c}$.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}$.

Take $a, b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
Then $a\mathrel{R}x$ by Definition 130.
$x\mathrel{R}a$ or $x = a$ by Definition 99.
Suppose not.
Contradiction by Definition 36, Definition 98.

LaTeX source
\begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Then $a\mathrel{R}x$ by \cref{intervalopen_rel}.
        $x\mathrel{R}a$ or $x = a$ by \cref{smallest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Then $(a_0\mathrel{R}x \lor x = a_0)$ and $x\mathrel{R}b$ by \cref{intervalclosedopen_rel}.
        Hence $a_0 = x$ by \cref{intervalclosedopen_rel,smallest_element,simple_order_relation,asymmetric}.
        Therefore there exists $c\in X$ such that $x\mathrel{R}c$ and $B = \intervalclosedopenrel{R}{X}{x}{c}$.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Then $a\mathrel{R}x$ by \cref{intervalopenclosed_rel}.
        $x\mathrel{R}a$ or $x = a$ by \cref{smallest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    
\end{byCase}
LaTeX source
\begin{proof}
    $((\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}) \lor
        (\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}) \lor
        (\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}))$
        by \cref{order_basis}.
    \begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Then $a\mathrel{R}x$ by \cref{intervalopen_rel}.
        $x\mathrel{R}a$ or $x = a$ by \cref{smallest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Then $(a_0\mathrel{R}x \lor x = a_0)$ and $x\mathrel{R}b$ by \cref{intervalclosedopen_rel}.
        Hence $a_0 = x$ by \cref{intervalclosedopen_rel,smallest_element,simple_order_relation,asymmetric}.
        Therefore there exists $c\in X$ such that $x\mathrel{R}c$ and $B = \intervalclosedopenrel{R}{X}{x}{c}$.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Then $a\mathrel{R}x$ by \cref{intervalopenclosed_rel}.
        $x\mathrel{R}a$ or $x = a$ by \cref{smallest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \end{byCase}
\end{proof}
Lemma 107
orderbasis_elem_at_largest

Assume $R$ is a simple order relation on $X$.
Suppose $x$ is a largest element of $X$ with respect to $R$.
Suppose $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B$.
Then there exists $a\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}x$ and $B = \intervalopenclosedrel{R}{X}{a}{x}$.

LaTeX source
\begin{lemma}
\label{orderbasis_elem_at_largest}
    Assume $R$ is a simple order relation on $X$.
    Suppose $x$ is a largest element of $X$ with respect to $R$.
    Suppose $B\in\orderBasis{R}{X}$.
    Suppose $x\in B$.
    Then there exists $a\in X$ such that $a\mathrel{R}x$ and $B = \intervalopenclosedrel{R}{X}{a}{x}$.
\end{lemma}
Proof

$((\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}))$ by Definition 133.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}$.

Take $a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
Then $x\mathrel{R}b$ by Definition 129.
$b\mathrel{R}x$ or $b = x$ by Definition 128.
Suppose not.
Contradiction by Definition 36, Definition 98.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}$.

Take $a_0, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
Then $x\mathrel{R}b$ by Definition 131.
$b\mathrel{R}x$ or $b = x$ by Definition 128.
Suppose not.
Contradiction by Definition 36, Definition 98.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}$.

Take $a, b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
Then $a\mathrel{R}x$ and $(x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0)$ by Definition 130.
Hence $b_0 = x$ by Definition 36, Definition 98, Definition 128, Definition 130.
Therefore there exists $c\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $c\mathrel{R}x$ and $B = \intervalopenclosedrel{R}{X}{c}{x}$.

LaTeX source
\begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Then $x\mathrel{R}b$ by \cref{intervalopen_rel}.
        $b\mathrel{R}x$ or $b = x$ by \cref{largest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Then $x\mathrel{R}b$ by \cref{intervalclosedopen_rel}.
        $b\mathrel{R}x$ or $b = x$ by \cref{largest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Then $a\mathrel{R}x$ and $(x\mathrel{R}b_0 \lor x = b_0)$ by \cref{intervalopenclosed_rel}.
        Hence $b_0 = x$ by \cref{intervalopenclosed_rel,largest_element,simple_order_relation,asymmetric}.
        Therefore there exists $c\in X$ such that $c\mathrel{R}x$ and $B = \intervalopenclosedrel{R}{X}{c}{x}$.
    
\end{byCase}
LaTeX source
\begin{proof}
    $((\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}) \lor
        (\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}) \lor
        (\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}))$
        by \cref{order_basis}.
    \begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Then $x\mathrel{R}b$ by \cref{intervalopen_rel}.
        $b\mathrel{R}x$ or $b = x$ by \cref{largest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Then $x\mathrel{R}b$ by \cref{intervalclosedopen_rel}.
        $b\mathrel{R}x$ or $b = x$ by \cref{largest_element}.
        Suppose not.
        Contradiction by \cref{simple_order_relation,asymmetric}.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Then $a\mathrel{R}x$ and $(x\mathrel{R}b_0 \lor x = b_0)$ by \cref{intervalopenclosed_rel}.
        Hence $b_0 = x$ by \cref{intervalopenclosed_rel,largest_element,simple_order_relation,asymmetric}.
        Therefore there exists $c\in X$ such that $c\mathrel{R}x$ and $B = \intervalopenclosedrel{R}{X}{c}{x}$.
    \end{byCase}
\end{proof}
Lemma 108
orderbasis_elem_contains_open_interval

Assume $R$ is a simple order relation on $X$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Suppose $x$ is not a smallest element of $X$ with respect to $R$.
Suppose $x$ is not a largest element of $X$ with respect to $R$.
Suppose $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B$.
Then there exist $a,b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a}{b} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B$.

LaTeX source
\begin{lemma}
\label{orderbasis_elem_contains_open_interval}
    Assume $R$ is a simple order relation on $X$.
    Suppose $x\in X$.
    Suppose $x$ is not a smallest element of $X$ with respect to $R$.
    Suppose $x$ is not a largest element of $X$ with respect to $R$.
    Suppose $B\in\orderBasis{R}{X}$.
    Suppose $x\in B$.
    Then there exist $a,b\in X$ such that $a\mathrel{R}x$ and $x\mathrel{R}b$ and
        $\intervalopenrel{R}{X}{a}{b} \subseteq B$.
\end{lemma}
Proof

$((\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}))$ by Definition 133.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}$.

Take $a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
Then $a\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a}{b} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B$ by Definition 129, Proposition 2.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}$.

Take $a_0, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
Hence $a_0\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a_0}{b} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B$ by Definition 1, Definition 99, Definition 129, Definition 131.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}$.

Take $a, b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
Therefore $a\mathrel{R}x$ and $x\mathrel{R}b_0$ and $\intervalopenrel{R}{X}{a}{b_0} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B$ by Definition 1, Definition 128, Definition 129, Definition 130.

LaTeX source
\begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Then $a\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a}{b} \subseteq B$
            by \cref{intervalopen_rel,subseteq_refl}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Hence $a_0\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a_0}{b} \subseteq B$
            by \cref{intervalopen_rel,intervalclosedopen_rel,smallest_element,subseteq}.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Therefore $a\mathrel{R}x$ and $x\mathrel{R}b_0$ and $\intervalopenrel{R}{X}{a}{b_0} \subseteq B$
            by \cref{intervalopen_rel,intervalopenclosed_rel,largest_element,subseteq}.
    
\end{byCase}
LaTeX source
\begin{proof}
    $((\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}) \lor
        (\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}) \lor
        (\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}))$
        by \cref{order_basis}.
    \begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Then $a\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a}{b} \subseteq B$
            by \cref{intervalopen_rel,subseteq_refl}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Hence $a_0\mathrel{R}x$ and $x\mathrel{R}b$ and $\intervalopenrel{R}{X}{a_0}{b} \subseteq B$
            by \cref{intervalopen_rel,intervalclosedopen_rel,smallest_element,subseteq}.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Therefore $a\mathrel{R}x$ and $x\mathrel{R}b_0$ and $\intervalopenrel{R}{X}{a}{b_0} \subseteq B$
            by \cref{intervalopen_rel,intervalopenclosed_rel,largest_element,subseteq}.
    \end{byCase}
\end{proof}
Lemma 109
max_of_two_elements

Assume $R$ is a simple order relation on $X$.
Suppose $a_1, a_2\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Then there exists $a\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(a = a_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a = a_2) \class{latex-symbol-tip latex-symbol-id-land}{\land} (a_1\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_1 = a) \class{latex-symbol-tip latex-symbol-id-land}{\land} (a_2\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_2 = a)$.

LaTeX source
\begin{lemma}
\label{max_of_two_elements}
    Assume $R$ is a simple order relation on $X$.
    Suppose $a_1, a_2\in X$.
    Then there exists $a\in X$ such that
        $(a = a_1 \lor a = a_2) \land
        (a_1\mathrel{R}a \lor a_1 = a) \land
        (a_2\mathrel{R}a \lor a_2 = a)$.
\end{lemma}
Proof

Follows by Definition 40, Definition 98.

LaTeX source
\begin{proof}
    Follows by \cref{simple_order_relation,connex}.
\end{proof}
Lemma 110
min_of_two_elements

Assume $R$ is a simple order relation on $X$.
Suppose $b_1, b_2\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Then there exists $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(b = b_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_2) \class{latex-symbol-tip latex-symbol-id-land}{\land} (b\mathrel{R}b_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_1) \class{latex-symbol-tip latex-symbol-id-land}{\land} (b\mathrel{R}b_2 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_2)$.

LaTeX source
\begin{lemma}
\label{min_of_two_elements}
    Assume $R$ is a simple order relation on $X$.
    Suppose $b_1, b_2\in X$.
    Then there exists $b\in X$ such that
        $(b = b_1 \lor b = b_2) \land
        (b\mathrel{R}b_1 \lor b = b_1) \land
        (b\mathrel{R}b_2 \lor b = b_2)$.
\end{lemma}
Proof

Follows by Definition 40, Definition 98.

LaTeX source
\begin{proof}
    Follows by \cref{simple_order_relation,connex}.
\end{proof}
Lemma 111
rel_from_or_left

Suppose $a = a_1$ or $a = a_2$.
Suppose $a_1\mathrel{R}x$ and $a_2\mathrel{R}x$.
Then $a\mathrel{R}x$.

LaTeX source
\begin{lemma}
\label{rel_from_or_left}
    Suppose $a = a_1$ or $a = a_2$.
    Suppose $a_1\mathrel{R}x$ and $a_2\mathrel{R}x$.
    Then $a\mathrel{R}x$.
\end{lemma}
Proof

Trivial.

LaTeX source
\begin{proof}
    Trivial.
\end{proof}
Lemma 112
rel_from_or_right

Suppose $b = b_1$ or $b = b_2$.
Suppose $x\mathrel{R}b_1$ and $x\mathrel{R}b_2$.
Then $x\mathrel{R}b$.

LaTeX source
\begin{lemma}
\label{rel_from_or_right}
    Suppose $b = b_1$ or $b = b_2$.
    Suppose $x\mathrel{R}b_1$ and $x\mathrel{R}b_2$.
    Then $x\mathrel{R}b$.
\end{lemma}
Proof

Trivial.

LaTeX source
\begin{proof}
    Trivial.
\end{proof}
Lemma 113
order_basis_is_basis

Assume $R$ is a simple order relation on $X$.
Assume $X$ has more than one element.
Then $\orderBasis{R}{X}$ is a basis on $X$.

LaTeX source
\begin{lemma}
\label{order_basis_is_basis}
    Assume $R$ is a simple order relation on $X$.
    Assume $X$ has more than one element.
    Then $\orderBasis{R}{X}$ is a basis on $X$.
\end{lemma}
Proof
Claim: $\orderBasis{R}{X}\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq}\pow{X}$.
Claim: For all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ there exists $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$.

Fix $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.

Case. $x$ is a smallest element of $X$ with respect to $R$.

Take $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $y\class{latex-symbol-tip latex-symbol-id-neq}{\neq} x$ by Lemma 100.
$x\mathrel{R}y$ by Definition 99.
Let $B_1 = \intervalclosedopenrel{R}{X}{x}{y}$.
Thus $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ by Definition 1, Definition 99, Definition 131, Definition 133, Proposition 155.

Case. $x$ is not a smallest element of $X$ with respect to $R$.
Case. $x$ is a largest element of $X$ with respect to $R$.

Take $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $y\class{latex-symbol-tip latex-symbol-id-neq}{\neq} x$ by Lemma 100.
$y\mathrel{R}x$ by Definition 128.
Let $B_1 = \intervalopenclosedrel{R}{X}{y}{x}$.
$B_1\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ by Definition 1, Definition 128, Definition 130, Definition 133, Proposition 155.

Case. $x$ is not a largest element of $X$ with respect to $R$.

Take $a\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}x$ by Lemma 101.
Take $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}b$ by Lemma 102.
Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
$B_1\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ by Definition 1, Definition 37 [Transitivity], Definition 98, Definition 129, Definition 133, Proposition 155.

LaTeX source
\begin{byCase}
            \caseOf{$x$ is a largest element of $X$ with respect to $R$.}
                Take $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
                $y\mathrel{R}x$ by \cref{largest_element}.
                Let $B_1 = \intervalopenclosedrel{R}{X}{y}{x}$.
                $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{intervalopenclosed_rel,subseteq,powerset_intro,largest_element,order_basis}.
            \caseOf{$x$ is not a largest element of $X$ with respect to $R$.}
                Take $a\in X$ such that $a\mathrel{R}x$ by \cref{non_smallest_has_predecessor}.
                Take $b\in X$ such that $x\mathrel{R}b$ by \cref{non_largest_has_successor}.
                Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
                $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{simple_order_relation,transitive,intervalopen_rel,subseteq,powerset_intro,order_basis}.
            
\end{byCase}
LaTeX source
\begin{byCase}
        \caseOf{$x$ is a smallest element of $X$ with respect to $R$.}
            Take $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
            $x\mathrel{R}y$ by \cref{smallest_element}.
            Let $B_1 = \intervalclosedopenrel{R}{X}{x}{y}$.
            Thus $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{intervalclosedopen_rel,subseteq,powerset_intro,smallest_element,order_basis}.
        \caseOf{$x$ is not a smallest element of $X$ with respect to $R$.}
            \begin{byCase}
            \caseOf{$x$ is a largest element of $X$ with respect to $R$.}
                Take $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
                $y\mathrel{R}x$ by \cref{largest_element}.
                Let $B_1 = \intervalopenclosedrel{R}{X}{y}{x}$.
                $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{intervalopenclosed_rel,subseteq,powerset_intro,largest_element,order_basis}.
            \caseOf{$x$ is not a largest element of $X$ with respect to $R$.}
                Take $a\in X$ such that $a\mathrel{R}x$ by \cref{non_smallest_has_predecessor}.
                Take $b\in X$ such that $x\mathrel{R}b$ by \cref{non_largest_has_successor}.
                Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
                $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{simple_order_relation,transitive,intervalopen_rel,subseteq,powerset_intro,order_basis}.
            \end{byCase}
        
\end{byCase}
Claim: For all $B_1,B_2,x$ such that $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $B_2\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1\inter B_2$ there exists $B_3\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_3$ and $B_3\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_1\inter B_2$.

Fix $B_1,B_2$.
Fix $x$ such that $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $B_2\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1\inter B_2$.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_2$ by Proposition 62, Proposition 63.
Thus $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ by Definition 1, Definition 133, Proposition 156.

Case. $x$ is a smallest element of $X$ with respect to $R$.

Take $b_1\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}b_1$ and $B_1 = \intervalclosedopenrel{R}{X}{x}{b_1}$ by Lemma 106.
Take $b_2\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}b_2$ and $B_2 = \intervalclosedopenrel{R}{X}{x}{b_2}$ by Lemma 106.
Take $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(b = b_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_2) \class{latex-symbol-tip latex-symbol-id-land}{\land} (b\mathrel{R}b_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_1) \class{latex-symbol-tip latex-symbol-id-land}{\land} (b\mathrel{R}b_2 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_2)$ by Lemma 110.
Let $B_3 = \intervalclosedopenrel{R}{X}{x}{b}$.
$B_3\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_3$ and $B_3\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_1\inter B_2$ by Definition 1, Definition 98, Definition 99, Definition 131, Definition 133, Lemma 104, Proposition 72, Proposition 155.

Case. $x$ is not a smallest element of $X$ with respect to $R$.
Case. $x$ is a largest element of $X$ with respect to $R$.

Take $a_1\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a_1\mathrel{R}x$ and $B_1 = \intervalopenclosedrel{R}{X}{a_1}{x}$ by Lemma 107.
Take $a_2\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a_2\mathrel{R}x$ and $B_2 = \intervalopenclosedrel{R}{X}{a_2}{x}$ by Lemma 107.
Take $a\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(a = a_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a = a_2) \class{latex-symbol-tip latex-symbol-id-land}{\land} (a_1\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_1 = a) \class{latex-symbol-tip latex-symbol-id-land}{\land} (a_2\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_2 = a)$ by Lemma 109.
Let $B_3 = \intervalopenclosedrel{R}{X}{a}{x}$.
$B_3\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_3$ and $B_3\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_1\inter B_2$ by Definition 1, Definition 98, Definition 128, Definition 130, Definition 133, Lemma 105, Proposition 72, Proposition 155.

Case. $x$ is not a largest element of $X$ with respect to $R$.

Take $a_1,b_1\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a_1\mathrel{R}x$ and $x\mathrel{R}b_1$ and $\intervalopenrel{R}{X}{a_1}{b_1} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_1$ by Lemma 108.
Take $a_2,b_2\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a_2\mathrel{R}x$ and $x\mathrel{R}b_2$ and $\intervalopenrel{R}{X}{a_2}{b_2} \class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_2$ by Lemma 108.
Take $a\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(a = a_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a = a_2) \class{latex-symbol-tip latex-symbol-id-land}{\land} (a_1\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_1 = a) \class{latex-symbol-tip latex-symbol-id-land}{\land} (a_2\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_2 = a)$ by Lemma 109.
Take $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(b = b_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_2) \class{latex-symbol-tip latex-symbol-id-land}{\land} (b\mathrel{R}b_1 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_1) \class{latex-symbol-tip latex-symbol-id-land}{\land} (b\mathrel{R}b_2 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} b = b_2)$ by Lemma 110.
Let $B_3 = \intervalopenrel{R}{X}{a}{b}$.
$R$ is transitive by Definition 98.
Thus $a\mathrel{R}b$ by \hyperref[transitive]{transitivity}.
$B_3\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_3$ by Definition 1, Definition 129, Definition 133, Lemma 111, Lemma 112, Proposition 155.
$B_3\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_1\inter B_2$ by Lemma 103, Proposition 6, Proposition 72.

LaTeX source
\begin{byCase}
            \caseOf{$x$ is a largest element of $X$ with respect to $R$.}
                Take $a_1\in X$ such that $a_1\mathrel{R}x$ and $B_1 = \intervalopenclosedrel{R}{X}{a_1}{x}$ by \cref{orderbasis_elem_at_largest}.
                Take $a_2\in X$ such that $a_2\mathrel{R}x$ and $B_2 = \intervalopenclosedrel{R}{X}{a_2}{x}$ by \cref{orderbasis_elem_at_largest}.
                Take $a\in X$ such that
                    $(a = a_1 \lor a = a_2) \land
                    (a_1\mathrel{R}a \lor a_1 = a) \land
                    (a_2\mathrel{R}a \lor a_2 = a)$
                    by \cref{max_of_two_elements}.
                Let $B_3 = \intervalopenclosedrel{R}{X}{a}{x}$.
                $B_3\in\orderBasis{R}{X}$ and $x\in B_3$ and $B_3\subseteq B_1\inter B_2$
                    by \cref{order_basis,intervalopenclosed_rel,subseteq,powerset_intro,largest_element,simple_order_relation,intervalopenclosedrel_subset_by_left,subseteq_inter_iff}.
            \caseOf{$x$ is not a largest element of $X$ with respect to $R$.}
                Take $a_1,b_1\in X$ such that $a_1\mathrel{R}x$ and $x\mathrel{R}b_1$ and
                    $\intervalopenrel{R}{X}{a_1}{b_1} \subseteq B_1$ by \cref{orderbasis_elem_contains_open_interval}.
                Take $a_2,b_2\in X$ such that $a_2\mathrel{R}x$ and $x\mathrel{R}b_2$ and
                    $\intervalopenrel{R}{X}{a_2}{b_2} \subseteq B_2$ by \cref{orderbasis_elem_contains_open_interval}.
                Take $a\in X$ such that
                    $(a = a_1 \lor a = a_2) \land
                    (a_1\mathrel{R}a \lor a_1 = a) \land
                    (a_2\mathrel{R}a \lor a_2 = a)$
                    by \cref{max_of_two_elements}.
                Take $b\in X$ such that
                    $(b = b_1 \lor b = b_2) \land
                    (b\mathrel{R}b_1 \lor b = b_1) \land
                    (b\mathrel{R}b_2 \lor b = b_2)$
                    by \cref{min_of_two_elements}.
                Let $B_3 = \intervalopenrel{R}{X}{a}{b}$.
                $R$ is transitive by \cref{simple_order_relation}.
                Thus $a\mathrel{R}b$ by \hyperref[transitive]{transitivity}.
                $B_3\in\orderBasis{R}{X}$ and $x\in B_3$
                    by \cref{intervalopen_rel,subseteq,powerset_intro,order_basis,rel_from_or_left,rel_from_or_right}.
                $B_3\subseteq B_1\inter B_2$
                    by \cref{intervalopenrel_subset_by_endpoints,subseteq_transitive,subseteq_inter_iff}.
            
\end{byCase}
LaTeX source
\begin{byCase}
        \caseOf{$x$ is a smallest element of $X$ with respect to $R$.}
            Take $b_1\in X$ such that $x\mathrel{R}b_1$ and $B_1 = \intervalclosedopenrel{R}{X}{x}{b_1}$ by \cref{orderbasis_elem_at_smallest}.
            Take $b_2\in X$ such that $x\mathrel{R}b_2$ and $B_2 = \intervalclosedopenrel{R}{X}{x}{b_2}$ by \cref{orderbasis_elem_at_smallest}.
            Take $b\in X$ such that
                $(b = b_1 \lor b = b_2) \land
                (b\mathrel{R}b_1 \lor b = b_1) \land
                (b\mathrel{R}b_2 \lor b = b_2)$
                by \cref{min_of_two_elements}.
            Let $B_3 = \intervalclosedopenrel{R}{X}{x}{b}$.
            $B_3\in\orderBasis{R}{X}$ and $x\in B_3$ and $B_3\subseteq B_1\inter B_2$
                by \cref{order_basis,intervalclosedopen_rel,subseteq,powerset_intro,smallest_element,simple_order_relation,intervalclosedopenrel_subset_by_right,subseteq_inter_iff}.
        \caseOf{$x$ is not a smallest element of $X$ with respect to $R$.}
            \begin{byCase}
            \caseOf{$x$ is a largest element of $X$ with respect to $R$.}
                Take $a_1\in X$ such that $a_1\mathrel{R}x$ and $B_1 = \intervalopenclosedrel{R}{X}{a_1}{x}$ by \cref{orderbasis_elem_at_largest}.
                Take $a_2\in X$ such that $a_2\mathrel{R}x$ and $B_2 = \intervalopenclosedrel{R}{X}{a_2}{x}$ by \cref{orderbasis_elem_at_largest}.
                Take $a\in X$ such that
                    $(a = a_1 \lor a = a_2) \land
                    (a_1\mathrel{R}a \lor a_1 = a) \land
                    (a_2\mathrel{R}a \lor a_2 = a)$
                    by \cref{max_of_two_elements}.
                Let $B_3 = \intervalopenclosedrel{R}{X}{a}{x}$.
                $B_3\in\orderBasis{R}{X}$ and $x\in B_3$ and $B_3\subseteq B_1\inter B_2$
                    by \cref{order_basis,intervalopenclosed_rel,subseteq,powerset_intro,largest_element,simple_order_relation,intervalopenclosedrel_subset_by_left,subseteq_inter_iff}.
            \caseOf{$x$ is not a largest element of $X$ with respect to $R$.}
                Take $a_1,b_1\in X$ such that $a_1\mathrel{R}x$ and $x\mathrel{R}b_1$ and
                    $\intervalopenrel{R}{X}{a_1}{b_1} \subseteq B_1$ by \cref{orderbasis_elem_contains_open_interval}.
                Take $a_2,b_2\in X$ such that $a_2\mathrel{R}x$ and $x\mathrel{R}b_2$ and
                    $\intervalopenrel{R}{X}{a_2}{b_2} \subseteq B_2$ by \cref{orderbasis_elem_contains_open_interval}.
                Take $a\in X$ such that
                    $(a = a_1 \lor a = a_2) \land
                    (a_1\mathrel{R}a \lor a_1 = a) \land
                    (a_2\mathrel{R}a \lor a_2 = a)$
                    by \cref{max_of_two_elements}.
                Take $b\in X$ such that
                    $(b = b_1 \lor b = b_2) \land
                    (b\mathrel{R}b_1 \lor b = b_1) \land
                    (b\mathrel{R}b_2 \lor b = b_2)$
                    by \cref{min_of_two_elements}.
                Let $B_3 = \intervalopenrel{R}{X}{a}{b}$.
                $R$ is transitive by \cref{simple_order_relation}.
                Thus $a\mathrel{R}b$ by \hyperref[transitive]{transitivity}.
                $B_3\in\orderBasis{R}{X}$ and $x\in B_3$
                    by \cref{intervalopen_rel,subseteq,powerset_intro,order_basis,rel_from_or_left,rel_from_or_right}.
                $B_3\subseteq B_1\inter B_2$
                    by \cref{intervalopenrel_subset_by_endpoints,subseteq_transitive,subseteq_inter_iff}.
            \end{byCase}
        
\end{byCase}

$\orderBasis{R}{X}$ is a basis on $X$ by Definition 113.

LaTeX source
\begin{proof}
    Show that $\orderBasis{R}{X}\subseteq\pow{X}$.
    \begin{subproof}
        Follows by \cref{order_basis,subseteq}.
    \end{subproof}
    Show that for all $x\in X$ there exists $B_1\in\orderBasis{R}{X}$ such that $x\in B_1$.
    \begin{subproof}
        Fix $x\in X$.
        \begin{byCase}
        \caseOf{$x$ is a smallest element of $X$ with respect to $R$.}
            Take $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
            $x\mathrel{R}y$ by \cref{smallest_element}.
            Let $B_1 = \intervalclosedopenrel{R}{X}{x}{y}$.
            Thus $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{intervalclosedopen_rel,subseteq,powerset_intro,smallest_element,order_basis}.
        \caseOf{$x$ is not a smallest element of $X$ with respect to $R$.}
            \begin{byCase}
            \caseOf{$x$ is a largest element of $X$ with respect to $R$.}
                Take $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
                $y\mathrel{R}x$ by \cref{largest_element}.
                Let $B_1 = \intervalopenclosedrel{R}{X}{y}{x}$.
                $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{intervalopenclosed_rel,subseteq,powerset_intro,largest_element,order_basis}.
            \caseOf{$x$ is not a largest element of $X$ with respect to $R$.}
                Take $a\in X$ such that $a\mathrel{R}x$ by \cref{non_smallest_has_predecessor}.
                Take $b\in X$ such that $x\mathrel{R}b$ by \cref{non_largest_has_successor}.
                Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
                $B_1\in\orderBasis{R}{X}$ and $x\in B_1$ by \cref{simple_order_relation,transitive,intervalopen_rel,subseteq,powerset_intro,order_basis}.
            \end{byCase}
        \end{byCase}
    \end{subproof}
    Show that for all $B_1,B_2,x$ such that $B_1\in\orderBasis{R}{X}$ and $B_2\in\orderBasis{R}{X}$ and $x\in B_1\inter B_2$
        there exists $B_3\in\orderBasis{R}{X}$ such that $x\in B_3$ and $B_3\subseteq B_1\inter B_2$.
    \begin{subproof}
        Fix $B_1,B_2$.
        Fix $x$ such that $B_1\in\orderBasis{R}{X}$ and $B_2\in\orderBasis{R}{X}$ and $x\in B_1\inter B_2$.
        $x\in B_1$ and $x\in B_2$ by \cref{inter_elim_left,inter_elim_right}.
        Thus $x\in X$ by \cref{order_basis,powerset_elim,subseteq}.
        \begin{byCase}
        \caseOf{$x$ is a smallest element of $X$ with respect to $R$.}
            Take $b_1\in X$ such that $x\mathrel{R}b_1$ and $B_1 = \intervalclosedopenrel{R}{X}{x}{b_1}$ by \cref{orderbasis_elem_at_smallest}.
            Take $b_2\in X$ such that $x\mathrel{R}b_2$ and $B_2 = \intervalclosedopenrel{R}{X}{x}{b_2}$ by \cref{orderbasis_elem_at_smallest}.
            Take $b\in X$ such that
                $(b = b_1 \lor b = b_2) \land
                (b\mathrel{R}b_1 \lor b = b_1) \land
                (b\mathrel{R}b_2 \lor b = b_2)$
                by \cref{min_of_two_elements}.
            Let $B_3 = \intervalclosedopenrel{R}{X}{x}{b}$.
            $B_3\in\orderBasis{R}{X}$ and $x\in B_3$ and $B_3\subseteq B_1\inter B_2$
                by \cref{order_basis,intervalclosedopen_rel,subseteq,powerset_intro,smallest_element,simple_order_relation,intervalclosedopenrel_subset_by_right,subseteq_inter_iff}.
        \caseOf{$x$ is not a smallest element of $X$ with respect to $R$.}
            \begin{byCase}
            \caseOf{$x$ is a largest element of $X$ with respect to $R$.}
                Take $a_1\in X$ such that $a_1\mathrel{R}x$ and $B_1 = \intervalopenclosedrel{R}{X}{a_1}{x}$ by \cref{orderbasis_elem_at_largest}.
                Take $a_2\in X$ such that $a_2\mathrel{R}x$ and $B_2 = \intervalopenclosedrel{R}{X}{a_2}{x}$ by \cref{orderbasis_elem_at_largest}.
                Take $a\in X$ such that
                    $(a = a_1 \lor a = a_2) \land
                    (a_1\mathrel{R}a \lor a_1 = a) \land
                    (a_2\mathrel{R}a \lor a_2 = a)$
                    by \cref{max_of_two_elements}.
                Let $B_3 = \intervalopenclosedrel{R}{X}{a}{x}$.
                $B_3\in\orderBasis{R}{X}$ and $x\in B_3$ and $B_3\subseteq B_1\inter B_2$
                    by \cref{order_basis,intervalopenclosed_rel,subseteq,powerset_intro,largest_element,simple_order_relation,intervalopenclosedrel_subset_by_left,subseteq_inter_iff}.
            \caseOf{$x$ is not a largest element of $X$ with respect to $R$.}
                Take $a_1,b_1\in X$ such that $a_1\mathrel{R}x$ and $x\mathrel{R}b_1$ and
                    $\intervalopenrel{R}{X}{a_1}{b_1} \subseteq B_1$ by \cref{orderbasis_elem_contains_open_interval}.
                Take $a_2,b_2\in X$ such that $a_2\mathrel{R}x$ and $x\mathrel{R}b_2$ and
                    $\intervalopenrel{R}{X}{a_2}{b_2} \subseteq B_2$ by \cref{orderbasis_elem_contains_open_interval}.
                Take $a\in X$ such that
                    $(a = a_1 \lor a = a_2) \land
                    (a_1\mathrel{R}a \lor a_1 = a) \land
                    (a_2\mathrel{R}a \lor a_2 = a)$
                    by \cref{max_of_two_elements}.
                Take $b\in X$ such that
                    $(b = b_1 \lor b = b_2) \land
                    (b\mathrel{R}b_1 \lor b = b_1) \land
                    (b\mathrel{R}b_2 \lor b = b_2)$
                    by \cref{min_of_two_elements}.
                Let $B_3 = \intervalopenrel{R}{X}{a}{b}$.
                $R$ is transitive by \cref{simple_order_relation}.
                Thus $a\mathrel{R}b$ by \hyperref[transitive]{transitivity}.
                $B_3\in\orderBasis{R}{X}$ and $x\in B_3$
                    by \cref{intervalopen_rel,subseteq,powerset_intro,order_basis,rel_from_or_left,rel_from_or_right}.
                $B_3\subseteq B_1\inter B_2$
                    by \cref{intervalopenrel_subset_by_endpoints,subseteq_transitive,subseteq_inter_iff}.
            \end{byCase}
        \end{byCase}
    \end{subproof}
    $\orderBasis{R}{X}$ is a basis on $X$ by \cref{basis_on}.
\end{proof}
Definition 135
openray_right

$\openrayright{R}{X}{a} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid a\mathrel{R}x\}$.

LaTeX source
\begin{definition}
\label{openray_right}
    $\openrayright{R}{X}{a} = \{x\in X \mid a\mathrel{R}x\}$.
\end{definition}
Definition 136
openray_left

$\openrayleft{R}{X}{a} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid x\mathrel{R}a\}$.

LaTeX source
\begin{definition}
\label{openray_left}
    $\openrayleft{R}{X}{a} = \{x\in X \mid x\mathrel{R}a\}$.
\end{definition}
Definition 137
closedray_right

$\closedrayright{R}{X}{a} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid a\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = a\}$.

LaTeX source
\begin{definition}
\label{closedray_right}
    $\closedrayright{R}{X}{a} = \{x\in X \mid a\mathrel{R}x \lor x = a\}$.
\end{definition}
Definition 138
closedray_left

$\closedrayleft{R}{X}{a} = \{x\class{latex-symbol-tip latex-symbol-id-in}{\in} X \mid x\mathrel{R}a \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = a\}$.

LaTeX source
\begin{definition}
\label{closedray_left}
    $\closedrayleft{R}{X}{a} = \{x\in X \mid x\mathrel{R}a \lor x = a\}$.
\end{definition}
Definition 139
open_rays

$\openRays{R}{X} = \{U\class{latex-symbol-tip latex-symbol-id-in}{\in}\pow{X} \mid \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (U = \openrayright{R}{X}{a} \class{latex-symbol-tip latex-symbol-id-lor}{\lor} U = \openrayleft{R}{X}{a})\}$.

LaTeX source
\begin{definition}
\label{open_rays}
    $\openRays{R}{X} = \{U\in\pow{X} \mid \exists a\in X. (U = \openrayright{R}{X}{a} \lor U = \openrayleft{R}{X}{a})\}$.
\end{definition}
Lemma 114
intervalopenrel_as_intersection_openrays

$\intervalopenrel{R}{X}{a}{b} = \openrayright{R}{X}{a} \inter \openrayleft{R}{X}{b}$.

LaTeX source
\begin{lemma}
\label{intervalopenrel_as_intersection_openrays}
    $\intervalopenrel{R}{X}{a}{b} = \openrayright{R}{X}{a} \inter \openrayleft{R}{X}{b}$.
\end{lemma}
Proof

Follows by Axiom 1 [Set extensionality], Definition 5, Definition 129, Definition 135, Definition 136.

LaTeX source
\begin{proof}
    Follows by \cref{intervalopen_rel,openray_right,openray_left,inter,setext}.
\end{proof}
Lemma 115
intervalclosedopenrel_smallest_eq_openrayleft

Assume $a_0$ is a smallest element of $X$ with respect to $R$.
Then $\intervalclosedopenrel{R}{X}{a_0}{b} = \openrayleft{R}{X}{b}$.

LaTeX source
\begin{lemma}
\label{intervalclosedopenrel_smallest_eq_openrayleft}
    Assume $a_0$ is a smallest element of $X$ with respect to $R$.
    Then $\intervalclosedopenrel{R}{X}{a_0}{b} = \openrayleft{R}{X}{b}$.
\end{lemma}
Proof

Follows by Axiom 1 [Set extensionality], Definition 99, Definition 131, Definition 136.

LaTeX source
\begin{proof}
    Follows by \cref{intervalclosedopen_rel,openray_left,smallest_element,setext}.
\end{proof}
Lemma 116
intervalopenclosedrel_largest_eq_openrayright

Assume $b_0$ is a largest element of $X$ with respect to $R$.
Then $\intervalopenclosedrel{R}{X}{a}{b_0} = \openrayright{R}{X}{a}$.

LaTeX source
\begin{lemma}
\label{intervalopenclosedrel_largest_eq_openrayright}
    Assume $b_0$ is a largest element of $X$ with respect to $R$.
    Then $\intervalopenclosedrel{R}{X}{a}{b_0} = \openrayright{R}{X}{a}$.
\end{lemma}
Proof

Follows by Axiom 1 [Set extensionality], Definition 128, Definition 130, Definition 135.

LaTeX source
\begin{proof}
    Follows by \cref{intervalopenclosed_rel,openray_right,largest_element,setext}.
\end{proof}
Lemma 117
open_rays_subbasis_on

Assume $R$ is a simple order relation on $X$.
Assume $X$ has more than one element.
Then $\openRays{R}{X}$ is a subbasis on $X$.

LaTeX source
\begin{lemma}
\label{open_rays_subbasis_on}
    Assume $R$ is a simple order relation on $X$.
    Assume $X$ has more than one element.
    Then $\openRays{R}{X}$ is a subbasis on $X$.
\end{lemma}
Proof

Let $S = \openRays{R}{X}$.
$S\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq}\pow{X}$ by Definition 1, Definition 139.
$\unions{S}\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} X$ by Proposition 159.
For all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ there exists $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $y\class{latex-symbol-tip latex-symbol-id-neq}{\neq} x$ by Lemma 100.

Claim: For all $x$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ we have $x\class{latex-symbol-tip latex-symbol-id-in}{\in} \unions{S}$.

Fix $x$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$.
Take $y\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $y\class{latex-symbol-tip latex-symbol-id-neq}{\neq} x$ by Lemma 100.
Then $y\mathrel{R} x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x\mathrel{R} y$ by Definition 40, Definition 98.

Case. $y\mathrel{R} x$.

$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\openrayright{R}{X}{y}$ by Definition 135.
$\openrayright{R}{X}{y}\class{latex-symbol-tip latex-symbol-id-in}{\in} S$ by Definition 1, Definition 135, Definition 139, Proposition 155.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\unions{S}$ by Axiom 4.

Case. $x\mathrel{R} y$.

$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\openrayleft{R}{X}{y}$ by Definition 136.
$\openrayleft{R}{X}{y}\class{latex-symbol-tip latex-symbol-id-in}{\in} S$ by Definition 1, Definition 136, Definition 139, Proposition 155.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\unions{S}$ by Axiom 4.

LaTeX source
\begin{byCase}
        \caseOf{$y\mathrel{R} x$.}
            $x\in\openrayright{R}{X}{y}$ by \cref{openray_right}.
            $\openrayright{R}{X}{y}\in S$ by \cref{openray_right,subseteq,powerset_intro,open_rays}.
            $x\in\unions{S}$ by \cref{unions_iff}.
        \caseOf{$x\mathrel{R} y$.}
            $x\in\openrayleft{R}{X}{y}$ by \cref{openray_left}.
            $\openrayleft{R}{X}{y}\in S$ by \cref{openray_left,subseteq,powerset_intro,open_rays}.
            $x\in\unions{S}$ by \cref{unions_iff}.
        
\end{byCase}

$\unions{S} = X$ by Definition 1, Proposition 3.
$S$ is a subbasis on $X$ by Definition 124.

LaTeX source
\begin{proof}
    Let $S = \openRays{R}{X}$.
    $S\subseteq\pow{X}$ by \cref{open_rays,subseteq}.
    $\unions{S}\subseteq X$ by \cref{unions_subseteq_of_powerset_is_subseteq}.
    For all $x\in X$ there exists $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
    Show that for all $x$ such that $x\in X$ we have $x\in \unions{S}$.
    \begin{subproof}
        Fix $x$ such that $x\in X$.
        Take $y\in X$ such that $y\neq x$ by \cref{more_than_one_element_has_other}.
        Then $y\mathrel{R} x \lor x\mathrel{R} y$ by \cref{simple_order_relation,connex}.
        \begin{byCase}
        \caseOf{$y\mathrel{R} x$.}
            $x\in\openrayright{R}{X}{y}$ by \cref{openray_right}.
            $\openrayright{R}{X}{y}\in S$ by \cref{openray_right,subseteq,powerset_intro,open_rays}.
            $x\in\unions{S}$ by \cref{unions_iff}.
        \caseOf{$x\mathrel{R} y$.}
            $x\in\openrayleft{R}{X}{y}$ by \cref{openray_left}.
            $\openrayleft{R}{X}{y}\in S$ by \cref{openray_left,subseteq,powerset_intro,open_rays}.
            $x\in\unions{S}$ by \cref{unions_iff}.
        \end{byCase}
    \end{subproof}
    $\unions{S} = X$ by \cref{subseteq,subseteq_antisymmetric}.
    $S$ is a subbasis on $X$ by \cref{subbasis_on}.
\end{proof}
Lemma 118
order_basis_in_finite_intersections

Assume $R$ is a simple order relation on $X$.
Assume $X$ has more than one element.
Suppose $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\orderBasis{R}{X}$.
Then $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\finiteIntersections{\openRays{R}{X}}$.

LaTeX source
\begin{lemma}
\label{order_basis_in_finite_intersections}
    Assume $R$ is a simple order relation on $X$.
    Assume $X$ has more than one element.
    Suppose $B\in\orderBasis{R}{X}$.
    Then $B\in\finiteIntersections{\openRays{R}{X}}$.
\end{lemma}
Proof

Let $S = \openRays{R}{X}$.
$B\class{latex-symbol-tip latex-symbol-id-in}{\in}\pow{\unions{S}}$ and $((\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}) \class{latex-symbol-tip latex-symbol-id-lor}{\lor} (\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}))$ by Axiom 12, Definition 124, Definition 133, Lemma 117, Proposition 155.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a\mathrel{R}b \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenrel{R}{X}{a}{b}$.

Take $a, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
Let $F = \{\openrayright{R}{X}{a}, \openrayleft{R}{X}{b}\}$.
$F\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} S$ by Definition 1, Definition 135, Definition 136, Definition 139, Proposition 19, Proposition 155.
$F$ is finite and $F$ is inhabited by Lemma 40, Proposition 16.
Thus $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\finiteIntersections{S}$ by Definition 125, Lemma 114, Proposition 64.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalclosedopenrel{R}{X}{a_0}{b}$.

Take $a_0, b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
Hence $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\finiteIntersections{S}$ by Definition 1, Definition 99, Definition 125, Definition 136, Definition 139, Lemma 40, Lemma 44, Lemma 115, Proposition 16, Proposition 20, Proposition 25, Proposition 36, Proposition 155.

Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} B = \intervalopenclosedrel{R}{X}{a}{b_0}$.

Take $a, b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $(\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
Therefore $B\class{latex-symbol-tip latex-symbol-id-in}{\in}\finiteIntersections{S}$ by Definition 1, Definition 125, Definition 128, Definition 135, Definition 139, Lemma 40, Lemma 44, Lemma 116, Proposition 16, Proposition 20, Proposition 25, Proposition 36, Proposition 155.

LaTeX source
\begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Let $F = \{\openrayright{R}{X}{a}, \openrayleft{R}{X}{b}\}$.
        $F\subseteq S$ by \cref{openray_right,openray_left,subseteq,powerset_intro,open_rays,upair_iff}.
        $F$ is finite and $F$ is inhabited by \cref{pair_is_finite,upair_intro_left}.
        Thus $B\in\finiteIntersections{S}$
            by \cref{intervalopenrel_as_intersection_openrays,inter_as_inters,finite_intersections}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Hence $B\in\finiteIntersections{S}$
            by \cref{openray_left,subseteq,powerset_intro,open_rays,singleton_subset_intro,pair_is_finite,upair_intro_left,subseteq_finite_is_finite,singleton_intro,smallest_element,intervalclosedopenrel_smallest_eq_openrayleft,inters_singleton,finite_intersections}.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Therefore $B\in\finiteIntersections{S}$
            by \cref{openray_right,subseteq,powerset_intro,open_rays,singleton_subset_intro,pair_is_finite,upair_intro_left,subseteq_finite_is_finite,singleton_intro,largest_element,intervalopenclosedrel_largest_eq_openrayright,inters_singleton,finite_intersections}.
    
\end{byCase}
LaTeX source
\begin{proof}
    Let $S = \openRays{R}{X}$.
    $B\in\pow{\unions{S}}$ and
        $((\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}) \lor
        (\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}) \lor
        (\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}))$
        by \cref{open_rays_subbasis_on,subbasis_on,order_basis,pow_iff,powerset_intro}.
    \begin{byCase}
    \caseOf{$\exists a, b\in X. a\mathrel{R}b \land B = \intervalopenrel{R}{X}{a}{b}$.}
        Take $a, b\in X$ such that $a\mathrel{R}b$ and $B = \intervalopenrel{R}{X}{a}{b}$.
        Let $F = \{\openrayright{R}{X}{a}, \openrayleft{R}{X}{b}\}$.
        $F\subseteq S$ by \cref{openray_right,openray_left,subseteq,powerset_intro,open_rays,upair_iff}.
        $F$ is finite and $F$ is inhabited by \cref{pair_is_finite,upair_intro_left}.
        Thus $B\in\finiteIntersections{S}$
            by \cref{intervalopenrel_as_intersection_openrays,inter_as_inters,finite_intersections}.
    \caseOf{$\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land B = \intervalclosedopenrel{R}{X}{a_0}{b}$.}
        Take $a_0, b\in X$ such that
            $(\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$ and $B = \intervalclosedopenrel{R}{X}{a_0}{b}$.
        Hence $B\in\finiteIntersections{S}$
            by \cref{openray_left,subseteq,powerset_intro,open_rays,singleton_subset_intro,pair_is_finite,upair_intro_left,subseteq_finite_is_finite,singleton_intro,smallest_element,intervalclosedopenrel_smallest_eq_openrayleft,inters_singleton,finite_intersections}.
    \caseOf{$\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land B = \intervalopenclosedrel{R}{X}{a}{b_0}$.}
        Take $a, b_0\in X$ such that
            $(\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$ and $B = \intervalopenclosedrel{R}{X}{a}{b_0}$.
        Therefore $B\in\finiteIntersections{S}$
            by \cref{openray_right,subseteq,powerset_intro,open_rays,singleton_subset_intro,pair_is_finite,upair_intro_left,subseteq_finite_is_finite,singleton_intro,largest_element,intervalopenclosedrel_largest_eq_openrayright,inters_singleton,finite_intersections}.
    \end{byCase}
\end{proof}
Lemma 119
initial_segment_one

$\initialSegment{1} = \{1\}$.

LaTeX source
\begin{lemma}
\label{initial_segment_one}
    $\initialSegment{1} = \{1\}$.
\end{lemma}
Proof

For all $x$ we have $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{1}$ iff $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\{1\}$ by Axiom 35, Axiom 41, Axiom 42, Axiom 43, Definition 1, Definition 84, Proposition 22.
Follows by Axiom 1 [Set extensionality].

LaTeX source
\begin{proof}
    For all $x$ we have $x\in\initialSegment{1}$ iff $x\in\{1\}$
        by \cref{initial_segment_naturalsplus,real_one_in_naturals,real_one_leq_naturalsplus,real_naturals_subset_reals,subseteq,singleton_iff,real_lt_asym}.
    Follows by \cref{setext}.
\end{proof}
Lemma 120
naturalsplus_lt_succ

Suppose $n\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus$.
Then $n < n + 1$.

LaTeX source
\begin{lemma}
\label{naturalsplus_lt_succ}
    Suppose $n\in\naturalsPlus$.
    Then $n < n + 1$.
\end{lemma}
Proof

$n\class{latex-symbol-tip latex-symbol-id-in}{\in}\reals$ and $1\class{latex-symbol-tip latex-symbol-id-in}{\in}\reals$ and $0\class{latex-symbol-tip latex-symbol-id-in}{\in}\reals$ by Axiom 17, Axiom 41, Axiom 42, Definition 1.
$0 < 1$ by Proposition 462.
$0 + n < 1 + n$ by Axiom 37.
$0 + n = n$ and $1 + n = n + 1$ by Axiom 16, Axiom 17.
Follows by Lemma 82, Lemma 83.

LaTeX source
\begin{proof}
    $n\in\reals$ and $1\in\reals$ and $0\in\reals$
        by \cref{real_naturals_subset_reals,real_one_in_naturals,subseteq,real_add_ident}.
    $0 < 1$ by \cref{real_zero_lt_one}.
    $0 + n < 1 + n$ by \cref{real_lt_add}.
    $0 + n = n$ and $1 + n = n + 1$ by \cref{real_add_ident,real_add_comm}.
    Follows by \cref{real_lt_subst_left,real_lt_subst_right}.
\end{proof}
Lemma 121
initial_segment_subset_succ

Suppose $n\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus$.
Then $\initialSegment{n}\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} \initialSegment{n + 1}$.

LaTeX source
\begin{lemma}
\label{initial_segment_subset_succ}
    Suppose $n\in\naturalsPlus$.
    Then $\initialSegment{n}\subseteq \initialSegment{n + 1}$.
\end{lemma}
Proof
Claim: For all $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ we have $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n + 1}$.

Fix $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus$ and $x \class{latex-symbol-tip latex-symbol-id-leq}{\leq} n$ by Definition 84.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\reals$ and $n\class{latex-symbol-tip latex-symbol-id-in}{\in}\reals$ and $n + 1\class{latex-symbol-tip latex-symbol-id-in}{\in}\reals$ by Axiom 41, Axiom 45, Definition 1.
$n < n + 1$ by Lemma 120.
$x < n + 1$ or $x = n + 1$ by Axiom 36, Lemma 81, Lemma 82.
Thus $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n + 1}$ by Axiom 45, Definition 84.

Follows by Definition 1.

LaTeX source
\begin{proof}
    Show that for all $x\in\initialSegment{n}$ we have $x\in\initialSegment{n + 1}$.
    \begin{subproof}
        Fix $x\in\initialSegment{n}$.
        $x\in\naturalsPlus$ and $x \leq n$ by \cref{initial_segment_naturalsplus}.
        $x\in\reals$ and $n\in\reals$ and $n + 1\in\reals$
            by \cref{real_naturals_subset_reals,real_naturals_closed_succ,subseteq}.
        $n < n + 1$ by \cref{naturalsplus_lt_succ}.
        $x < n + 1$ or $x = n + 1$ by \cref{real_leq_split,real_lt_trans,real_lt_subst_left}.
        Thus $x\in\initialSegment{n + 1}$ by \cref{initial_segment_naturalsplus,real_naturals_closed_succ}.
    \end{subproof}
    Follows by \cref{subseteq}.
\end{proof}
Lemma 122
initial_segment_succ_split

Suppose $n\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus$.
Suppose $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n + 1}$.
Then $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ or $x = n + 1$.

LaTeX source
\begin{lemma}
\label{initial_segment_succ_split}
    Suppose $n\in\naturalsPlus$.
    Suppose $x\in\initialSegment{n + 1}$.
    Then $x\in\initialSegment{n}$ or $x = n + 1$.
\end{lemma}
Proof

Follows by Axiom 44, Definition 84.

LaTeX source
\begin{proof}
    Follows by \cref{initial_segment_naturalsplus,real_succ_discrete}.
\end{proof}
Lemma 123
initial_segment_inhabited

Suppose $n\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus$.
Then $\initialSegment{n}$ is inhabited.

LaTeX source
\begin{lemma}
\label{initial_segment_inhabited}
    Suppose $n\in\naturalsPlus$.
    Then $\initialSegment{n}$ is inhabited.
\end{lemma}
Proof

$1\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ by Axiom 42, Axiom 43, Definition 84.

LaTeX source
\begin{proof}
    $1\in\initialSegment{n}$ by \cref{initial_segment_naturalsplus,real_one_in_naturals,real_one_leq_naturalsplus}.
\end{proof}
Lemma 124
finite_intersections_open_in_topology

Assume $T$ is a topology on $X$.
Suppose $F\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$.
Suppose $F$ is finite and inhabited.
Then $\inters{F}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.

LaTeX source
\begin{lemma}
\label{finite_intersections_open_in_topology}
    Assume $T$ is a topology on $X$.
    Suppose $F\subseteq T$.
    Suppose $F$ is finite and inhabited.
    Then $\inters{F}\in T$.
\end{lemma}
Proof

Take $k\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus$ such that there exists a bijection from $\initialSegment{k}$ to $F$ by Definition 89.
Let $A = \{ n\class{latex-symbol-tip latex-symbol-id-in}{\in}\naturalsPlus \mid \text{for all $G,g$ such that $g$ is a bijection from $\initialSegment{n}$ to $G$ and $G\subseteq T$ and $G$ is inhabited we have $\inters{G}\in T$} \}$.

Claim: For all $G,g$ such that $g$ is a bijection from $\initialSegment{1}$ to $G$ and $G\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ and $G$ is inhabited we have $\inters{G}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.

Fix $G$.
Fix $g$ such that $g$ is a bijection from $\initialSegment{1}$ to $G$ and $G\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ and $G$ is inhabited.
$g$ is a function by Proposition 390.
$\dom{g} = \initialSegment{1}$ by Proposition 391.
$1\class{latex-symbol-tip latex-symbol-id-in}{\in}\dom{g}$ by Lemma 119, Proposition 20.
Let $a = g(1)$.
$(1,a)\class{latex-symbol-tip latex-symbol-id-in}{\in} g$ by Proposition 348.
$g\class{latex-symbol-tip latex-symbol-id-in}{\in}\surj{\initialSegment{1}}{G}$ by Definition 58.
$\ran{g} = G$ by Corollary 7.
$a\class{latex-symbol-tip latex-symbol-id-in}{\in} G$ by Proposition 208.
$a\class{latex-symbol-tip latex-symbol-id-in}{\in} T$ by Proposition 4.

Claim: For all $z\class{latex-symbol-tip latex-symbol-id-in}{\in} G$ we have $z\class{latex-symbol-tip latex-symbol-id-in}{\in}\{a\}$.

Fix $z\class{latex-symbol-tip latex-symbol-id-in}{\in} G$.
Take $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{1}$ such that $g(x)=z$ by Definition 57, Definition 58.
$x = 1$ by Lemma 119, Proposition 22.
$a = z$.
Thus $z\class{latex-symbol-tip latex-symbol-id-in}{\in}\{a\}$ by Proposition 22.

$G\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq}\{a\}$ by Definition 1.
$\{a\}\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} G$ by Proposition 25.
$G = \{a\}$ by Proposition 3.
$\inters{G}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$ by Proposition 36.

$1\class{latex-symbol-tip latex-symbol-id-in}{\in} A$.

Claim: For all $n\class{latex-symbol-tip latex-symbol-id-in}{\in} A$ we have $n + 1\class{latex-symbol-tip latex-symbol-id-in}{\in} A$.

Fix $n\class{latex-symbol-tip latex-symbol-id-in}{\in} A$.

Claim: For all $G,g$ such that $g$ is a bijection from $\initialSegment{n + 1}$ to $G$ and $G\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ and $G$ is inhabited we have $\inters{G}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.

Fix $G$.
Fix $g$ such that $g$ is a bijection from $\initialSegment{n + 1}$ to $G$ and $G\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ and $G$ is inhabited.
$g$ is a function by Proposition 390.
$\dom{g} = \initialSegment{n + 1}$ by Proposition 391.
$n + 1\class{latex-symbol-tip latex-symbol-id-in}{\in}\dom{g}$ by Axiom 45, Definition 84.
Let $a = g(n + 1)$.
Let $G_1 = \img{g}{\initialSegment{n}}$.
$\initialSegment{n}\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} \initialSegment{n + 1}$ by Lemma 121.
$G_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} G$ by Definition 58, Proposition 236, Proposition 238, Proposition 391, Corollary 7.
$G_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ by Proposition 6.
$g\class{latex-symbol-tip latex-symbol-id-in}{\in}\surj{\initialSegment{n + 1}}{G}$ by Definition 58.
$\ran{g} = G$ by Corollary 7.
$(n + 1,a)\class{latex-symbol-tip latex-symbol-id-in}{\in} g$ by Proposition 348.
$a\class{latex-symbol-tip latex-symbol-id-in}{\in} G$ by Proposition 208.
$a\class{latex-symbol-tip latex-symbol-id-in}{\in} T$ by Proposition 4.

Claim: For all $z\class{latex-symbol-tip latex-symbol-id-in}{\in} G$ we have $z\class{latex-symbol-tip latex-symbol-id-in}{\in} G_1\union\{a\}$.

Fix $z\class{latex-symbol-tip latex-symbol-id-in}{\in} G$.
There exists $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n + 1}$ such that $g(x)=z$ by Definition 57, Definition 58.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ or $x = n + 1$ by Lemma 122.

Case. $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$.

$z\class{latex-symbol-tip latex-symbol-id-in}{\in} G_1\union\{a\}$ by Proposition 38, Proposition 235, Proposition 348.

Case. $x = n + 1$.

$z\class{latex-symbol-tip latex-symbol-id-in}{\in} G_1\union\{a\}$ by Proposition 20, Proposition 39, Proposition 348.

LaTeX source
\begin{byCase}
                        \caseOf{$x\in\initialSegment{n}$.}
                            $z\in G_1\union\{a\}$ by \cref{function_apply_elim,img_iff,union_intro_left}.
                        \caseOf{$x = n + 1$.}
                            $z\in G_1\union\{a\}$ by \cref{function_apply_elim,union_intro_right,singleton_intro}.
                        
\end{byCase}

Thus $G = G_1\union\{a\}$ by Definition 1, Proposition 3, Proposition 25, Proposition 44.
Take $x_0$ such that $x_0\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ by Lemma 123.
$x_0\class{latex-symbol-tip latex-symbol-id-in}{\in}\dom{g}$ by Definition 1, Lemma 121, Proposition 391.
$g(x_0)\class{latex-symbol-tip latex-symbol-id-in}{\in} G_1$ by Proposition 235, Proposition 348.
$G_1$ is inhabited.
Let $h = \restrl{g}{\initialSegment{n}}$.
$h$ is a function by Proposition 383.
For all $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ we have $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\dom{g}$ by Definition 1, Lemma 121, Proposition 391.
$\dom{h} = \initialSegment{n}$ by Definition 1, Proposition 70, Corollary 3.
$h\class{latex-symbol-tip latex-symbol-id-in}{\in}\funs{\initialSegment{n}}{G_1}$ by Proposition 4, Proposition 235, Proposition 263, Proposition 348, Proposition 358.
For all $y\class{latex-symbol-tip latex-symbol-id-in}{\in} G_1$ there exists $x\class{latex-symbol-tip latex-symbol-id-in}{\in}\initialSegment{n}$ such that $h(x) = y$ by Proposition 235, Proposition 349, Proposition 384.
$h$ is a bijection from $\initialSegment{n}$ to $G_1$ by Definition 57, Definition 58, Proposition 384, Proposition 386.
Therefore $\inters{G_1}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.
$G = \cons{a}{G_1}$ by Proposition 41 [Commutativity of union], Proposition 132.
$\inters{G}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$ by Definition 101, Proposition 137.

$A\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq}\naturalsPlus$ by Definition 1.
$k\class{latex-symbol-tip latex-symbol-id-in}{\in} A$ by Proposition 445.
For all $G,g$ such that $g$ is a bijection from $\initialSegment{k}$ to $G$ and $G\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ and $G$ is inhabited we have $\inters{G}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.
$\inters{F}\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.

LaTeX source
\begin{proof}
    Take $k\in\naturalsPlus$ such that there exists a bijection from $\initialSegment{k}$ to $F$ by \cref{finite}.
    Let $A = \{ n\in\naturalsPlus \mid \text{for all $G,g$ such that $g$ is a bijection from $\initialSegment{n}$ to $G$ and $G\subseteq T$ and $G$ is inhabited we have $\inters{G}\in T$} \}$.
    Show that for all $G,g$ such that $g$ is a bijection from $\initialSegment{1}$ to $G$ and $G\subseteq T$ and $G$ is inhabited we have $\inters{G}\in T$.
    \begin{subproof}
        Fix $G$.
        Fix $g$ such that $g$ is a bijection from $\initialSegment{1}$ to $G$ and $G\subseteq T$ and $G$ is inhabited.
        $g$ is a function by \cref{bijection_is_function}.
        $\dom{g} = \initialSegment{1}$ by \cref{bijections_dom}.
        $1\in\dom{g}$ by \cref{initial_segment_one,singleton_intro}.
        Let $a = g(1)$.
        $(1,a)\in g$ by \cref{function_apply_elim}.
        $g\in\surj{\initialSegment{1}}{G}$ by \cref{bijections}.
        $\ran{g} = G$ by \cref{ran_of_surj}.
        $a\in G$ by \cref{ran_iff}.
        $a\in T$ by \cref{elem_subseteq}.
        Show that for all $z\in G$ we have $z\in\{a\}$.
        \begin{subproof}
            Fix $z\in G$.
            Take $x\in\initialSegment{1}$ such that $g(x)=z$ by \cref{bijections,surj}.
            $x = 1$ by \cref{initial_segment_one,singleton_iff}.
            $a = z$.
            Thus $z\in\{a\}$ by \cref{singleton_iff}.
        \end{subproof}
        $G\subseteq\{a\}$ by \cref{subseteq}.
        $\{a\}\subseteq G$ by \cref{singleton_subset_intro}.
        $G = \{a\}$ by \cref{subseteq_antisymmetric}.
        $\inters{G}\in T$ by \cref{inters_singleton}.
    \end{subproof}
    $1\in A$.
    Show that for all $n\in A$ we have $n + 1\in A$.
    \begin{subproof}
            Fix $n\in A$.
            Show that for all $G,g$ such that $g$ is a bijection from $\initialSegment{n + 1}$ to $G$ and $G\subseteq T$ and $G$ is inhabited we have $\inters{G}\in T$.
            \begin{subproof}
                Fix $G$.
                Fix $g$ such that $g$ is a bijection from $\initialSegment{n + 1}$ to $G$ and $G\subseteq T$ and $G$ is inhabited.
                $g$ is a function by \cref{bijection_is_function}.
                $\dom{g} = \initialSegment{n + 1}$ by \cref{bijections_dom}.
                $n + 1\in\dom{g}$ by \cref{initial_segment_naturalsplus,real_naturals_closed_succ}.
                Let $a = g(n + 1)$.
                Let $G_1 = \img{g}{\initialSegment{n}}$.
                $\initialSegment{n}\subseteq \initialSegment{n + 1}$ by \cref{initial_segment_subset_succ}.
                $G_1\subseteq G$ by \cref{img_subseteq,bijections_dom,img_dom,bijections,ran_of_surj}.
                $G_1\subseteq T$ by \cref{subseteq_transitive}.
                $g\in\surj{\initialSegment{n + 1}}{G}$ by \cref{bijections}.
                $\ran{g} = G$ by \cref{ran_of_surj}.
                $(n + 1,a)\in g$ by \cref{function_apply_elim}.
                $a\in G$ by \cref{ran_iff}.
                $a\in T$ by \cref{elem_subseteq}.
                Show that for all $z\in G$ we have $z\in G_1\union\{a\}$.
                    \begin{subproof}
                        Fix $z\in G$.
                        There exists $x\in\initialSegment{n + 1}$ such that $g(x)=z$ by \cref{bijections,surj}.
                        $x\in\initialSegment{n}$ or $x = n + 1$ by \cref{initial_segment_succ_split}.
                        \begin{byCase}
                        \caseOf{$x\in\initialSegment{n}$.}
                            $z\in G_1\union\{a\}$ by \cref{function_apply_elim,img_iff,union_intro_left}.
                        \caseOf{$x = n + 1$.}
                            $z\in G_1\union\{a\}$ by \cref{function_apply_elim,union_intro_right,singleton_intro}.
                        \end{byCase}
                \end{subproof}
                Thus $G = G_1\union\{a\}$
                    by \cref{subseteq,singleton_subset_intro,union_subsets_is_subset,subseteq_antisymmetric}.
                Take $x_0$ such that $x_0\in\initialSegment{n}$ by \cref{initial_segment_inhabited}.
                $x_0\in\dom{g}$ by \cref{initial_segment_subset_succ,bijections_dom,subseteq}.
                $g(x_0)\in G_1$ by \cref{function_apply_elim,img_iff}.
                $G_1$ is inhabited.
                Let $h = \restrl{g}{\initialSegment{n}}$.
                $h$ is a function by \cref{restrl_of_function_is_function}.
                For all $x\in\initialSegment{n}$ we have $x\in\dom{g}$ by \cref{initial_segment_subset_succ,bijections_dom,subseteq}.
                $\dom{h} = \initialSegment{n}$ by \cref{subseteq,dom_of_restrl_eq_inter,inter_absorb_supseteq_left}.
                $h\in\funs{\initialSegment{n}}{G_1}$ by \cref{function_apply_elim,restrl_subseteq,elem_subseteq,img_iff,funs_intro}.
                For all $y\in G_1$ there exists $x\in\initialSegment{n}$ such that $h(x) = y$
                    by \cref{img_iff,function_apply_iff,restrl_of_function_apply}.
                $h$ is a bijection from $\initialSegment{n}$ to $G_1$ by \cref{surj,restrl_of_function_apply,bijections,injective_function}.
                Therefore $\inters{G_1}\in T$.
                $G = \cons{a}{G_1}$ by \cref{union_comm,union_eq_cons}.
                $\inters{G}\in T$ by \cref{inters_cons,topology_on}.
            \end{subproof}
    \end{subproof}
    $A\subseteq\naturalsPlus$ by \cref{subseteq}.
    $k\in A$ by \cref{real_naturals_induction}.
    For all $G,g$ such that $g$ is a bijection from $\initialSegment{k}$ to $G$ and $G\subseteq T$ and $G$ is inhabited we have $\inters{G}\in T$.
    $\inters{F}\in T$.
\end{proof}
Lemma 125
open_rays_subbasis

Assume $R$ is a simple order relation on $X$.
Assume $X$ has more than one element.
Assume $T$ is the order topology on $X$ with respect to $R$.
Then $\subbasisTopology{\openRays{R}{X}}{X} = T$.

LaTeX source
\begin{lemma}
\label{open_rays_subbasis}
    Assume $R$ is a simple order relation on $X$.
    Assume $X$ has more than one element.
    Assume $T$ is the order topology on $X$ with respect to $R$.
    Then $\subbasisTopology{\openRays{R}{X}}{X} = T$.
\end{lemma}
Proof

Let $S = \openRays{R}{X}$.
Let $B = \orderBasis{R}{X}$.
Let $T_1 = \subbasisTopology{S}{X}$.
$T = \basisTopology{B}{X}$ by Definition 134.
$B$ is a basis for $T$ on $X$ by Definition 115, Definition 134, Lemma 113.
$\finiteIntersections{S}$ is a basis for $T_1$ on $X$ by Definition 115, Definition 126, Lemma 99, Lemma 117.

Claim: For all $x,B_2$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ and $B_2\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_2$ there exists $B_3\class{latex-symbol-tip latex-symbol-id-in}{\in}\finiteIntersections{S}$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_3$ and $B_3\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_2$.

Thus $T\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T_1$ by Definition 108, Lemma 80.

Claim: For all $U\class{latex-symbol-tip latex-symbol-id-in}{\in} S$ we have $U\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.

Fix $U\class{latex-symbol-tip latex-symbol-id-in}{\in} S$.
Take $a\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $U = \openrayright{R}{X}{a}$ or $U = \openrayleft{R}{X}{a}$ by Definition 139.

Case. $U = \openrayright{R}{X}{a}$.
Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0)$.

Take $b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $b_0$ is a largest element of $X$ with respect to $R$.
$U = \intervalopenclosedrel{R}{X}{a}{b_0}$ by Lemma 116.
$\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. x\mathrel{R}b_0 \class{latex-symbol-tip latex-symbol-id-lor}{\lor} x = b_0) \class{latex-symbol-tip latex-symbol-id-land}{\land} U = \intervalopenclosedrel{R}{X}{a}{b_0}$.

Claim: $U\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ and $U\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.
Case. it is wrong that there exists $b_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that for all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ we have $x\mathrel{R}b_0$ or $x = b_0$.
Claim: For all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} U$ there exists $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ and $B_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} U$.

Fix $x\class{latex-symbol-tip latex-symbol-id-in}{\in} U$.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ and $a\mathrel{R}x$ by Definition 135.
$x$ is not a largest element of $X$ with respect to $R$.
Take $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $x\mathrel{R}b$ by Lemma 102.
Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
Hence $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ and $B_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} U$ by Definition 1, Definition 37 [Transitivity], Definition 98, Definition 129, Definition 133, Definition 135, Proposition 155.

$U\class{latex-symbol-tip latex-symbol-id-in}{\in} T$ by Definition 1, Definition 114, Definition 135, Proposition 155.

LaTeX source
\begin{byCase}
            \caseOf{$\exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$.}
                Take $b_0\in X$ such that $b_0$ is a largest element of $X$ with respect to $R$.
                $U = \intervalopenclosedrel{R}{X}{a}{b_0}$ by \cref{intervalopenclosedrel_largest_eq_openrayright}.
                $\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land U = \intervalopenclosedrel{R}{X}{a}{b_0}$.
                Show that $U\in B$ and $U\in T$.
                \begin{subproof}
                    Follows by \cref{intervalopenclosed_rel,subseteq,powerset_intro,order_basis,basis_elem_open_in_generated,order_basis_is_basis}.
                \end{subproof}
            \caseOf{it is wrong that there exists $b_0\in X$ such that for all $x\in X$ we have $x\mathrel{R}b_0$ or $x = b_0$.}
                Show that for all $x\in U$ there exists $B_1\in B$ such that $x\in B_1$ and $B_1\subseteq U$.
                \begin{subproof}
                    Fix $x\in U$.
                    $x\in X$ and $a\mathrel{R}x$ by \cref{openray_right}.
                    $x$ is not a largest element of $X$ with respect to $R$.
                    Take $b\in X$ such that $x\mathrel{R}b$ by \cref{non_largest_has_successor}.
                    Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
                    Hence $B_1\in B$ and $x\in B_1$ and $B_1\subseteq U$
                        by \cref{simple_order_relation,transitive,order_basis,intervalopen_rel,subseteq,powerset_intro,openray_right}.
                \end{subproof}
                $U\in T$ by \cref{openray_right,subseteq,powerset_intro,topology_generated_by_basis}.
            
\end{byCase}
Case. $U = \openrayleft{R}{X}{a}$.
Case. $\class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x)$.

Take $a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $a_0$ is a smallest element of $X$ with respect to $R$.
$U = \intervalclosedopenrel{R}{X}{a_0}{a}$ by Lemma 115.
$\class{latex-symbol-tip latex-symbol-id-exists}{\exists} b\class{latex-symbol-tip latex-symbol-id-in}{\in} X. \class{latex-symbol-tip latex-symbol-id-exists}{\exists} a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X. (\class{latex-symbol-tip latex-symbol-id-forall}{\forall} x\class{latex-symbol-tip latex-symbol-id-in}{\in} X. a_0\mathrel{R}x \class{latex-symbol-tip latex-symbol-id-lor}{\lor} a_0 = x) \class{latex-symbol-tip latex-symbol-id-land}{\land} U = \intervalclosedopenrel{R}{X}{a_0}{b}$.

Claim: $U\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ and $U\class{latex-symbol-tip latex-symbol-id-in}{\in} T$.
Case. it is wrong that there exists $a_0\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that for all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ we have $a_0\mathrel{R}x$ or $a_0 = x$.
Claim: For all $x\class{latex-symbol-tip latex-symbol-id-in}{\in} U$ there exists $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ and $B_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} U$.

Fix $x\class{latex-symbol-tip latex-symbol-id-in}{\in} U$.
$x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ and $x\mathrel{R}a$ by Definition 136.
$x$ is not a smallest element of $X$ with respect to $R$.
Take $b\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ such that $b\mathrel{R}x$ by Lemma 101.
Let $B_1 = \intervalopenrel{R}{X}{b}{a}$.
Thus $B_1\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_1$ and $B_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} U$ by Definition 1, Definition 37 [Transitivity], Definition 98, Definition 129, Definition 133, Definition 136, Proposition 155.

$U\class{latex-symbol-tip latex-symbol-id-in}{\in} T$ by Definition 1, Definition 114, Definition 136, Proposition 155.

LaTeX source
\begin{byCase}
            \caseOf{$\exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$.}
                Take $a_0\in X$ such that $a_0$ is a smallest element of $X$ with respect to $R$.
                $U = \intervalclosedopenrel{R}{X}{a_0}{a}$ by \cref{intervalclosedopenrel_smallest_eq_openrayleft}.
                $\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land U = \intervalclosedopenrel{R}{X}{a_0}{b}$.
                Show that $U\in B$ and $U\in T$.
                \begin{subproof}
                    Follows by \cref{intervalclosedopen_rel,subseteq,powerset_intro,order_basis,basis_elem_open_in_generated,order_basis_is_basis}.
                \end{subproof}
            \caseOf{it is wrong that there exists $a_0\in X$ such that for all $x\in X$ we have $a_0\mathrel{R}x$ or $a_0 = x$.}
                Show that for all $x\in U$ there exists $B_1\in B$ such that $x\in B_1$ and $B_1\subseteq U$.
                \begin{subproof}
                    Fix $x\in U$.
                    $x\in X$ and $x\mathrel{R}a$ by \cref{openray_left}.
                    $x$ is not a smallest element of $X$ with respect to $R$.
                    Take $b\in X$ such that $b\mathrel{R}x$ by \cref{non_smallest_has_predecessor}.
                    Let $B_1 = \intervalopenrel{R}{X}{b}{a}$.
                    Thus $B_1\in B$ and $x\in B_1$ and $B_1\subseteq U$
                        by \cref{simple_order_relation,transitive,order_basis,intervalopen_rel,subseteq,powerset_intro,openray_left}.
                \end{subproof}
                $U\in T$ by \cref{openray_left,subseteq,powerset_intro,topology_generated_by_basis}.
            
\end{byCase}
LaTeX source
\begin{byCase}
        \caseOf{$U = \openrayright{R}{X}{a}$.}
            \begin{byCase}
            \caseOf{$\exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$.}
                Take $b_0\in X$ such that $b_0$ is a largest element of $X$ with respect to $R$.
                $U = \intervalopenclosedrel{R}{X}{a}{b_0}$ by \cref{intervalopenclosedrel_largest_eq_openrayright}.
                $\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land U = \intervalopenclosedrel{R}{X}{a}{b_0}$.
                Show that $U\in B$ and $U\in T$.
                \begin{subproof}
                    Follows by \cref{intervalopenclosed_rel,subseteq,powerset_intro,order_basis,basis_elem_open_in_generated,order_basis_is_basis}.
                \end{subproof}
            \caseOf{it is wrong that there exists $b_0\in X$ such that for all $x\in X$ we have $x\mathrel{R}b_0$ or $x = b_0$.}
                Show that for all $x\in U$ there exists $B_1\in B$ such that $x\in B_1$ and $B_1\subseteq U$.
                \begin{subproof}
                    Fix $x\in U$.
                    $x\in X$ and $a\mathrel{R}x$ by \cref{openray_right}.
                    $x$ is not a largest element of $X$ with respect to $R$.
                    Take $b\in X$ such that $x\mathrel{R}b$ by \cref{non_largest_has_successor}.
                    Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
                    Hence $B_1\in B$ and $x\in B_1$ and $B_1\subseteq U$
                        by \cref{simple_order_relation,transitive,order_basis,intervalopen_rel,subseteq,powerset_intro,openray_right}.
                \end{subproof}
                $U\in T$ by \cref{openray_right,subseteq,powerset_intro,topology_generated_by_basis}.
            \end{byCase}
        \caseOf{$U = \openrayleft{R}{X}{a}$.}
            \begin{byCase}
            \caseOf{$\exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$.}
                Take $a_0\in X$ such that $a_0$ is a smallest element of $X$ with respect to $R$.
                $U = \intervalclosedopenrel{R}{X}{a_0}{a}$ by \cref{intervalclosedopenrel_smallest_eq_openrayleft}.
                $\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land U = \intervalclosedopenrel{R}{X}{a_0}{b}$.
                Show that $U\in B$ and $U\in T$.
                \begin{subproof}
                    Follows by \cref{intervalclosedopen_rel,subseteq,powerset_intro,order_basis,basis_elem_open_in_generated,order_basis_is_basis}.
                \end{subproof}
            \caseOf{it is wrong that there exists $a_0\in X$ such that for all $x\in X$ we have $a_0\mathrel{R}x$ or $a_0 = x$.}
                Show that for all $x\in U$ there exists $B_1\in B$ such that $x\in B_1$ and $B_1\subseteq U$.
                \begin{subproof}
                    Fix $x\in U$.
                    $x\in X$ and $x\mathrel{R}a$ by \cref{openray_left}.
                    $x$ is not a smallest element of $X$ with respect to $R$.
                    Take $b\in X$ such that $b\mathrel{R}x$ by \cref{non_smallest_has_predecessor}.
                    Let $B_1 = \intervalopenrel{R}{X}{b}{a}$.
                    Thus $B_1\in B$ and $x\in B_1$ and $B_1\subseteq U$
                        by \cref{simple_order_relation,transitive,order_basis,intervalopen_rel,subseteq,powerset_intro,openray_left}.
                \end{subproof}
                $U\in T$ by \cref{openray_left,subseteq,powerset_intro,topology_generated_by_basis}.
            \end{byCase}
        
\end{byCase}
Claim: For all $x,B_2$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} X$ and $B_2\class{latex-symbol-tip latex-symbol-id-in}{\in}\finiteIntersections{S}$ and $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_2$ there exists $B_3\class{latex-symbol-tip latex-symbol-id-in}{\in} B$ such that $x\class{latex-symbol-tip latex-symbol-id-in}{\in} B_3$ and $B_3\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} B_2$.

Hence $T_1\class{latex-symbol-tip latex-symbol-id-subseteq}{\subseteq} T$ by Definition 108, Lemma 80.
$T_1 = T$ by Proposition 3.

LaTeX source
\begin{proof}
    Let $S = \openRays{R}{X}$.
    Let $B = \orderBasis{R}{X}$.
    Let $T_1 = \subbasisTopology{S}{X}$.
    $T = \basisTopology{B}{X}$ by \cref{order_topology}.
    $B$ is a basis for $T$ on $X$ by \cref{order_basis_is_basis,basis_for_topology,order_topology}.
    $\finiteIntersections{S}$ is a basis for $T_1$ on $X$
        by \cref{open_rays_subbasis_on,subbasis_finite_intersections_basis,basis_for_topology,topology_generated_by_subbasis}.
    Show that for all $x,B_2$ such that $x\in X$ and $B_2\in B$ and $x\in B_2$
        there exists $B_3\in\finiteIntersections{S}$ such that $x\in B_3$ and $B_3\subseteq B_2$.
    \begin{subproof}
        Follows by \cref{order_basis_in_finite_intersections,subseteq_refl}.
    \end{subproof}
    Thus $T\subseteq T_1$ by \cref{basis_finer_criterion,finer_topology}.
    Show that for all $U\in S$ we have $U\in T$.
    \begin{subproof}
        Fix $U\in S$.
        Take $a\in X$ such that $U = \openrayright{R}{X}{a}$ or $U = \openrayleft{R}{X}{a}$ by \cref{open_rays}.
        \begin{byCase}
        \caseOf{$U = \openrayright{R}{X}{a}$.}
            \begin{byCase}
            \caseOf{$\exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0)$.}
                Take $b_0\in X$ such that $b_0$ is a largest element of $X$ with respect to $R$.
                $U = \intervalopenclosedrel{R}{X}{a}{b_0}$ by \cref{intervalopenclosedrel_largest_eq_openrayright}.
                $\exists a\in X. \exists b_0\in X. (\forall x\in X. x\mathrel{R}b_0 \lor x = b_0) \land U = \intervalopenclosedrel{R}{X}{a}{b_0}$.
                Show that $U\in B$ and $U\in T$.
                \begin{subproof}
                    Follows by \cref{intervalopenclosed_rel,subseteq,powerset_intro,order_basis,basis_elem_open_in_generated,order_basis_is_basis}.
                \end{subproof}
            \caseOf{it is wrong that there exists $b_0\in X$ such that for all $x\in X$ we have $x\mathrel{R}b_0$ or $x = b_0$.}
                Show that for all $x\in U$ there exists $B_1\in B$ such that $x\in B_1$ and $B_1\subseteq U$.
                \begin{subproof}
                    Fix $x\in U$.
                    $x\in X$ and $a\mathrel{R}x$ by \cref{openray_right}.
                    $x$ is not a largest element of $X$ with respect to $R$.
                    Take $b\in X$ such that $x\mathrel{R}b$ by \cref{non_largest_has_successor}.
                    Let $B_1 = \intervalopenrel{R}{X}{a}{b}$.
                    Hence $B_1\in B$ and $x\in B_1$ and $B_1\subseteq U$
                        by \cref{simple_order_relation,transitive,order_basis,intervalopen_rel,subseteq,powerset_intro,openray_right}.
                \end{subproof}
                $U\in T$ by \cref{openray_right,subseteq,powerset_intro,topology_generated_by_basis}.
            \end{byCase}
        \caseOf{$U = \openrayleft{R}{X}{a}$.}
            \begin{byCase}
            \caseOf{$\exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x)$.}
                Take $a_0\in X$ such that $a_0$ is a smallest element of $X$ with respect to $R$.
                $U = \intervalclosedopenrel{R}{X}{a_0}{a}$ by \cref{intervalclosedopenrel_smallest_eq_openrayleft}.
                $\exists b\in X. \exists a_0\in X. (\forall x\in X. a_0\mathrel{R}x \lor a_0 = x) \land U = \intervalclosedopenrel{R}{X}{a_0}{b}$.
                Show that $U\in B$ and $U\in T$.
                \begin{subproof}
                    Follows by \cref{intervalclosedopen_rel,subseteq,powerset_intro,order_basis,basis_elem_open_in_generated,order_basis_is_basis}.
                \end{subproof}
            \caseOf{it is wrong that there exists $a_0\in X$ such that for all $x\in X$ we have $a_0\mathrel{R}x$ or $a_0 = x$.}
                Show that for all $x\in U$ there exists $B_1\in B$ such that $x\in B_1$ and $B_1\subseteq U$.
                \begin{subproof}
                    Fix $x\in U$.
                    $x\in X$ and $x\mathrel{R}a$ by \cref{openray_left}.
                    $x$ is not a smallest element of $X$ with respect to $R$.
                    Take $b\in X$ such that $b\mathrel{R}x$ by \cref{non_smallest_has_predecessor}.
                    Let $B_1 = \intervalopenrel{R}{X}{b}{a}$.
                    Thus $B_1\in B$ and $x\in B_1$ and $B_1\subseteq U$
                        by \cref{simple_order_relation,transitive,order_basis,intervalopen_rel,subseteq,powerset_intro,openray_left}.
                \end{subproof}
                $U\in T$ by \cref{openray_left,subseteq,powerset_intro,topology_generated_by_basis}.
            \end{byCase}
        \end{byCase}
    \end{subproof}
    Show that for all $x,B_2$ such that $x\in X$ and $B_2\in\finiteIntersections{S}$ and $x\in B_2$
        there exists $B_3\in B$ such that $x\in B_3$ and $B_3\subseteq B_2$.
    \begin{subproof}
        Follows by \cref{finite_intersections,subseteq,order_basis_is_basis,basis_topology_is_topology,order_topology,finite_intersections_open_in_topology,topology_generated_by_basis}.
    \end{subproof}
    Hence $T_1\subseteq T$ by \cref{basis_finer_criterion,finer_topology}.
    $T_1 = T$ by \cref{subseteq_antisymmetric}.
\end{proof}