In this script, we define the rational numbers Q\mathbb{Q} and show that they form an ordered field. At the end of this script, we show that any ordered field contains a canonical copy of the rational numbers.

Definition 7.1. Let X={(a,b)∣a,b∈Z,b≠0}X = \{(a,b) \mid a,b \in \mathbb{Z}, b \neq 0\}. We define a relation ∼\sim on XX as:

(a,b)∼(c,d)if and only ifad=bc.(a,b) \sim (c,d) \quad \text{if and only if} \quad ad = bc.

Lemma 7.2. The relation ∼\sim is reflexive. That is, (a,b)∼(a,b)(a,b) \sim (a,b) for every (a,b)∈X(a,b) \in X.

Lemma 7.3. The relation ∼\sim is symmetric. That is, if (a,b)∼(c,d)(a,b) \sim (c,d), then (c,d)∼(a,b)(c,d) \sim (a,b).

Lemma 7.4. The relation ∼\sim is transitive. That is, if (a,b)∼(c,d)(a,b) \sim (c,d) and (c,d)∼(e,f)(c,d) \sim (e,f), then (a,b)∼(e,f)(a,b) \sim (e,f).

Remark 7.5. A relation on any set that is reflexive, symmetric, and transitive is called an equivalence relation. Thus, the preceding lemmas show that ∼\sim is an equivalence relation on XX.

Remark 7.6. A partition of a set is a collection of non-empty disjoint subsets whose union is the original set. Any equivalence relation on a set creates a partition of that set by collecting into subsets all of the elements that are equivalent (related) to each other. When the partition of a set arises from an equivalence relation in this manner, the subsets are referred to as equivalence classes.

Remark 7.7. If we think of the set XX as representing the collection of all fractions whose denominators are not zero, then the relation ∼\sim may be thought of as representing the equivalence of two fractions.

Definition 7.8. As a set, the rational numbers, denoted Q\mathbb{Q}, are the equivalence classes in the set XX under the equivalence relation ∼\sim. If (a,b)∈X(a,b) \in X, we denote the equivalence class of this element as [(a,b)][(a,b)]. Thus,

Q={[(a,b)]∣(a,b)∈X}.\mathbb{Q} = \{ [(a,b)] \mid (a,b) \in X \}.

Definition 7.9. We define addition and multiplication in Q\mathbb{Q} as follows. If [(a,b)][(a,b)] and [(c,d)][(c,d)] are in Q\mathbb{Q}, then:

[(a,b)]+Q[(c,d)]=[(ad+bc, bd)],[(a,b)]⋅Q[(c,d)]=[(ac, bd)].[(a,b)] +_{\mathbb{Q}} [(c,d)] = [(ad + bc,\, bd)], \qquad [(a,b)] \cdot_{\mathbb{Q}} [(c,d)] = [(ac,\, bd)].

We use the notation +Q+_{\mathbb{Q}} and ⋅Q\cdot_{\mathbb{Q}} to represent addition and multiplication in Q\mathbb{Q} so as to distinguish these operations from the usual addition (+)(+) and multiplication (⋅)(\cdot) in Z\mathbb{Z}.

Theorem 7.10. Addition in Q\mathbb{Q} is well-defined. That is, if (a,b)∼(a′,b′)(a,b) \sim (a',b') and (c,d)∼(c′,d′)(c,d) \sim (c',d'), then

[(a,b)]+Q[(c,d)]=[(a′,b′)]+Q[(c′,d′)].[(a,b)] +_{\mathbb{Q}} [(c,d)] = [(a',b')] +_{\mathbb{Q}} [(c',d')].

Theorem 7.11. Multiplication in Q\mathbb{Q} is well-defined. That is, if (a,b)∼(a′,b′)(a,b) \sim (a',b') and (c,d)∼(c′,d′)(c,d) \sim (c',d'), then

[(a,b)]⋅Q[(c,d)]=[(a′,b′)]⋅Q[(c′,d′)].[(a,b)] \cdot_{\mathbb{Q}} [(c,d)] = [(a',b')] \cdot_{\mathbb{Q}} [(c',d')].

Theorem 7.12. The rational numbers Q\mathbb{Q} satisfy axiom FA1 for fields.

Theorem 7.13. The rational numbers Q\mathbb{Q} satisfy axiom FA2 for fields.

Theorem 7.14. The rational numbers Q\mathbb{Q} satisfy axiom FA3 for fields, where the additive identity is the element [(0,1)][(0,1)].

Theorem 7.15. The rational numbers Q\mathbb{Q} satisfy axiom FA4 for fields, where the additive inverse of the element [(a,b)][(a,b)] is given by −[(a,b)]=[(−a,b)]-[(a,b)] = [(-a,b)].

Theorem 7.16. The rational numbers Q\mathbb{Q} satisfy axiom FA5 for fields.

Theorem 7.17. The rational numbers Q\mathbb{Q} satisfy axiom FA6 for fields.

Theorem 7.18. The rational numbers Q\mathbb{Q} satisfy axiom FA7 for fields, where the multiplicative identity is the element [(1,1)][(1,1)].

Theorem 7.19. The rational numbers Q\mathbb{Q} satisfy axiom FA8 for fields, where the multiplicative inverse of the element [(a,b)]≠[(0,1)][(a,b)] \neq [(0,1)] is given by [(a,b)]−1=[(b,a)][(a,b)]^{-1} = [(b,a)].

Theorem 7.20. The rational numbers Q\mathbb{Q} satisfy axiom FA9 for fields.

Theorem 7.21. The rational numbers Q\mathbb{Q} satisfy axiom FA10 for fields.

Remark 7.22. Thus, the rational numbers Q\mathbb{Q} with +Q+_{\mathbb{Q}} and ⋅Q\cdot_{\mathbb{Q}} form a field.

Next, we define an ordering on Q\mathbb{Q}.

Definition 7.23. Let [(a,b)],[(c,d)]∈Q[(a,b)], [(c,d)] \in \mathbb{Q}. Assuming b,d>0b,d > 0 in Z\mathbb{Z}, we say that [(a,b)]<Q[(c,d)][(a,b)] <_{\mathbb{Q}} [(c,d)] if and only if ad<bcad < bc. Note that we use the symbol <Q<_{\mathbb{Q}} to denote our ordering relation in Q\mathbb{Q} so as to distinguish it from the usual ordering << in Z\mathbb{Z}. Note also that, given an element in Q\mathbb{Q}, it is always possible to choose a representative (a,b)(a,b) with b>0b > 0.

Theorem 7.24. Ordering in Q\mathbb{Q} is well-defined. That is, if (a,b)∼(a′,b′)(a,b) \sim (a',b') and (c,d)∼(c′,d′)(c,d) \sim (c',d'), then

[(a,b)]<Q[(c,d)]if and only if[(a′,b′)]<Q[(c′,d′)].[(a,b)] <_{\mathbb{Q}} [(c,d)] \quad \text{if and only if} \quad [(a',b')] <_{\mathbb{Q}} [(c',d')].

Theorem 7.25. The relation <Q<_{\mathbb{Q}} is an ordering on the rational numbers Q\mathbb{Q}.

Theorem 7.26. The rational numbers Q\mathbb{Q} form an ordered field.

There is an important sense in which every ordered field contains a "copy" of the rational numbers. Let FF be an ordered field with additive identity 0F0_F and multiplicative identity 1F1_F. To prevent ambiguity, denote the additive identity in the rational numbers by 0Q0_{\mathbb{Q}} and the multiplicative identity in the rational numbers by 1Q1_{\mathbb{Q}}.

Theorem 7.27. Any ordered field FF contains a copy of the rational numbers Q\mathbb{Q} in the following sense. There exists an injective map i:Q⟶Fi: \mathbb{Q} \longrightarrow F that respects all of the axioms for an ordered field. In particular:

i(0Q)=0F,i(1Q)=1F,If a,b∈Q, then i(a+b)=i(a)+i(b),If a,b∈Q, then i(a⋅b)=i(a)⋅i(b),If a,b∈Q and a<b, then i(a)<i(b).\begin{aligned} i(0_{\mathbb{Q}}) &= 0_F, \\ i(1_{\mathbb{Q}}) &= 1_F, \\ \text{If } a,b \in \mathbb{Q}, &\text{ then } i(a + b) = i(a) + i(b), \\ \text{If } a,b \in \mathbb{Q}, &\text{ then } i(a \cdot b) = i(a) \cdot i(b), \\ \text{If } a,b \in \mathbb{Q} \text{ and } a < b, &\text{ then } i(a) < i(b). \end{aligned}

Since we know that Q\mathbb{Q} is an ordered field, this result says that Q\mathbb{Q} is the "minimal" ordered field.