\( \def\naturals{\mathbb{N}} \def\integers{\mathbb{Z}} \def\rationals{\mathbb{Q}} \def\reals{\mathbb{R}} \)

The Rational Numbers

We are all familiar with the rational numbers: a rational number is any number that can be written as $\frac{p}{q}$, where $p$ and $q$ are integers, and $q \neq 0$.

A more formal definition must not draw upon the concept of division, which is not defined for integers, which do not have multiplicative inverses. Instead we will define rationals in terms of pairs of numbers $p$ and $q$, specifying that $q$ cannot be 0.

Fun Facts

Rational numbers are instances of constructible numbers. Constructible numbers are numbers that can be built with rulers and compasses.

The ancient greeks, who discovered the rationals, originally assumed that all constructible numbers were rational. They were very shocked to realize that some constructible numbers were not rational.

Constructing the Rationals

Rational numbers are defined over ordered pairs $(p,q)$ from the set $\integers \times \integers^*$, where $\integers^* = \integers\setminus\{0\}$, the set of non-zero integers (represented here as the set of integers minus the elements of the set containing only zero).

Formally, a rational number is an equivalence class $[(p,q)]$ of ordered pairs from $\integers \times \integers^*$, defined over the equivalence relation $(p,q) \sim (n,m)$ if $pm = nq$.

Notate Bene

Note that we didn't simply define rationals as ordered pairs $(p,q)$, since such a definition would treat every ordered pair of integers as unique, so for instance, $(3,6)$ and $(1,2)$ would be treated as being distinct, whereas we know that they are both the same rational number. Our definition of rationals must also account for this.

In order to do so, we had to first define an equivalence relation for rationals. We know that informally two rational numbers $(p,q)$ and $(n,m)$ are identical if $\frac{p}{q} = \frac{n}{m}$, which is identical to saying that $pm = nq$ (since $q$ and $m$ are not $0$ by definition). We build our definition of rationals on this equivalence.

The set of all rationals is denoted by the symbols $\rationals$.

For formal notation, we will specify any rational as $[(p,q)]$. We will also use the informal notation $\frac{p}{q}$.

More generally, we will simply use a symbol such as $x$, instead of explicitly specifying the elements of the ordered pair, and denote that it is a rational number by saying $x \in \rationals$. We will explicitly use the numerator-denominator representation only if it is needed.


Arithmetic Operations on Rationals

Multiplication

We define a multiplication operation “$\times$” between two rational numbers $\frac{p}{q}$ and $\frac{n}{m}$ as follows. \[ \frac{p}{q} \times \frac{n}{m} = \frac{pn}{qm} \]

We can verify that this is, in fact, a well-defined operation. For it to be well defined, we must find the following:

Note that this definition of multiplication was defined such that it had this “well-defined” property.

Addition

We define the addition operation “+” in the following manner. For any two rational numbers $\frac{p}{q}$ and $\frac{r}{s}$, the addition of the two is defined by \[ \frac{p}{q} + \frac{r}{s} = \frac{ps + rq}{qs} \]

It is easy to verify that the above definition is well defined.

Consider any rational number $\frac{x}{y}$ that is equivalent to $\frac{p}{q}$ (i.e. $qx = py$). Similarly consider any rational number $\frac{n}{m}$ that is equivalent to $\frac{r}{s}$ (i.e. $ns = rm$). By the above definition, their sum is given by \[ \frac{x}{y} + \frac{n}{m} = \frac{xm + ny}{ym} \]

To show that our definition is well defined, we only need to show that $ \frac{xm + ny}{ym} = \frac{ps + rq}{qs}$. To show this we must show that $(xm +ny)qs = (ps + rq)ym$.

Expanding the right hand side, $RHS = (ps + rq)ym = psym + rqym$.

The left hand side becomes $(xm + ny)qs = xmqs + nyqs$. Using the equivalences $qx = py$ and $ns = rm$, we can rewrite the LHS as \[ LHS = xmqs + nyqs = xqms + nsyq = pyms + rmyq = psym + rqym = RHS. \]

How not to define addition

If one were to define addition analogously to multiplication, we would define it as \[ \frac{p}{q} + \frac{n}{m} = \frac{p+q}{n+m}, \] but a quick inspection shows this to be not well defined.

For it to be well defined, we should be able to add any rational number that is equivalent to $\frac{p}{q}$ and add it to any rational number that is equivalent to $\frac{n}{m}$, and the result must be equivalent to $\frac{p+q}{n+m}$. We can show that this isn't always true with a simple example.

Consider $\frac{1}{2} + \frac{3}{4}$. According to this dubious definition, we would get the sum to be $\frac{1+3}{2+4} = \frac{4}{6}$.

Now consider $\frac{2}{4} + \frac{3}{4}$. The above definition of addition would give the sum as $\frac{5}{9}$. But $\frac{2}{4} = \frac{1}{2}$. If the definition of addition were well defined, we should have $\frac{5}{9} = \frac{4}{6}$ But $5\times 6 \neq 4\times 9$, so $\frac{5}{9} \neq \frac{4}{6}$. The operation is not well defined.


Properties of the Rationals

Arithmetic operations over the rationals have most of the properties of the natural numbers.

  1. Closure: $\rationals$ are closed under addition and multiplication. For all $x,y \in \rationals$, $x+ y \in \rationals$, $x \times y \in \rationals$.
  2. Commutativity: Addition and multiplication are commutative: $x + y = y + x$, $x \times y = y \times x$.
  3. Associativity: For any $x,y,y \in \rationals$, $x + (y + z) = (x + y) + z$, and $x \times (y \times z) = (x \times y) \times z$.
  4. Distributivity: Addition distributes over multiplication: $x \times (y + z) = x \times y + x \times z$.

The identity properties of rationals must be more carefully defined than for integers. Moreover rationals include at least one identity operation that is not permitted in the integers.

Addition:

  1. Additive Identity: $\rationals$ includes the additive identity $[(0,n)]$. Note that this is the equivalence class where the first entry is $0$. Alternately, we may think of it as any rational number of the form $\frac{0}{n}$. For brevity, we will simply represent this element as “$0$”. For all $x \in \rationals$ $x + 0 = x$.
  2. Additive inverse: Every rational number $x \in \rationals$ has an additive inverse $y \in \rationals$ such that $x + y = 0$. The additive inverse is generally represented as $-x$. We will call adding an additive inverse “subtraction”.
  3. Zero divisors: For $x,y \in \rationals$, if $x \times y = 0$, then $y = 0$ or $y = 0$ or both.

Multiplication:

  1. Multiplicative Identity: $\rationals$ includes a multiplicative identity element $[(1,1)]$. Alternately, we can define is as the equivalence class of all rational numbers $\frac{n}{n}$, where the numerator is equal to the denominator. For brevity, we will simply represent this element as $1$. For all $x \in \rationals$, $x \times 1 = x$.
  2. Multiplicative inverse: All rational numbers other than $0$ (the additive identity element) have a multiplicative inverse that is also a rational number. The multiplicative inverse of an element $x \in \rationals$ is an element $y \in \rationals$ such that $x \times y = 1$. We will also represent the multiplicative inverse of $x$ as $\frac{1}{x}$, and the multiplication of $y$ by the multiplicative inverse of $x$ as $\frac{y}{x}$. We will call multiplying by a multiplicative inverse “division”.

The rationals are closed under exponentiation to integer powers. For any non-negative $n \in \integers$, $n \geq 0$ \[ \left(\frac{x}{y}\right)^n = \frac{x^n}{y^n} \]

For $n \lt 0$, the following holds only if $x \neq 0$ \[ \left(\frac{x}{y}\right)^{-n} = \frac{y^n}{x^n} \]


Defining Positive and Negative Numbers

Like the integers, positive and negative numbers are also obtained by definition

Positive Numbers: A rational number $\frac{m}{n}$ is defined as being positive if $m\times n \gt 0$. Note that here we are ussing multiplication and “$\gt$” as defined for integers, not rationals. As a matter of fact, we are yet to define order relations for rationals.

Negative Numbers: Any rational number $\frac{m}{n}$ is negative if $m\times n \lt 0$.

Its easy to see that the above definitions are well defined.


Order

We define an order relationship $\lt$ between two rationals analogously to integers.

For any two rational numbers $x, y \in \rationals$, we $x \lt y$ if $y - x$ is a positive rational number. The order relation “$\lt$” is generally read as “ less than ”.

Notation: We will write $x \gt y$ (where $\gt$ is read as “greater than”) if $y \lt x$. We will say $x \leq y$ if x may either be less than or equal to $y$. Similarly $x \geq y$ means that $x$ may either be greater than or equal to $y$.

Note that the above definition is a total order -- for any two rational numbers $x$ and $y$ one of the following holds true: $x \lt y$, or $y \lt x$ or $x = y$.

Since the rationals are a totally ordered set, the order naturally permits us to place the rationals on a line where every rational that is lesser than any other rational number is placed to the left of it. FIGURE.


The Archimedean property of rational numbers

The Archimedean property is a property of many algebraic systems that states, in effect, that no number is too large or too small. There are multiple formal definitions for it, but the most common one states that given any number $x$ in the system, there exists a natural number $n$ such that $n \gt x$.

The set of rationals $\rationals$ has the Archimedean property. Its rather trivial to prove.

Proposition: Given any rational numbers $x \in \rationals$, there exists a natural number $n$, such that $n \gt x$.

Proof:

We only need to worry about positive rationals, since for negative rationals $n = 0$ satisfies $ n \gt x$.

Let $x = \frac{p}{q}$ such that $q \gt 0$, $p \gt 0$.

Let $n = p + 1$. Clearly $n \gt \frac{p}{q}$.

This is easily proved. \[ n - x = \frac{p+1}{1} - \frac{p}{q} = \frac{(p+1)q - p}{q} = \frac{p(q-1) + q}{q} \]

But since $q \gt 0 \Rightarrow q-1 \geq 0 \Rightarrow p(q-1) + q \gt 0 \Rightarrow \frac{p(q-1) + q}{q} \gt 0 \Rightarrow n - x \gt 0$, proving that $n \gt x$.

Corollary: Given any two rational numbers $x, y \in \rationals$ such that $x \gt 0$, there exists a natural number $n$ such that $nx \gt y$.

Proof:

Since we have already specified that $x \gt 0$, we only need to consider the case where $y \gt x$. Let $x = \frac{a}{b}$,$b \gt 0$, and $y = \frac{c}{d}$, $d \gt 0$. Since $x, y \gt 0$, it follows that $a, c \gt 0$.

Since $c \gt 0$, we can define the rational number $z = \frac{y}{x}$.

By the Archimedean property, there exists a natural number $n$ such that $n \gt z$, \[ \frac{y}{x} \lt n \Rightarrow y \lt nx \]

Corollary: For any rational number $x \gt 0$, there exists a natural number $n$ such that $\frac{1}{n} \lt x$.

Proof:

This follows from the earlier corollary: If we set $y = 1$, we get that there is a natural number $n \gt 0$ such that $nx \gt 1$, or, alternately, $x \gt \frac{1}{n}$.


The rationals are a Field

The set of rationals $\rationals$ belongs to a structure called a Field. A Field is a set $F$ with two operations $+$ (addition) and $\times$ (multiplication) defined over it such that

It is easy to see that $\rationals$ satisfies all the above conditions.

Specifically, $\rationals$ is an ordered Field, implying that order is preserved by Field operations.


The rationals extend the integers

The set of rationals $\rationals$ extend the set of integers, $\integers$. Alternately stated, $\integers$ is embedded in $\rationals$, i.e. there is a subset $\integers_\rationals$ of $\rationals$ that has a one-to-one correspondence with $\integers$, and the order, equality and other relationships within this subset $\integers_\rationals$ are identical to those of $\integers$.

The set $\integers_\rationals$ is easy to define: for each integer $n$ in $\integers$ the corresponding rational number in $\integers_\rationals$ is $\frac{n}{1}$.

We can now verify that the addition and multiplication operations on the rational equivalents of the integers are consistent with the corresponding operations on the integers.