# Rational arithmetic all works together

We have seen what the rational numbers are, and five things we can do with them:

These might seem like five standalone operations, but in fact they all play nicely together in a particular way. You don’t need to know the fancy name, but here it is anyway: mathematicians say that the rationals form an ordered field, meaning that the five operations above:

• work in the rationals

• slot together, behaving in certain specific ways that make it easy to calculate

You shouldn’t bother learning this page particularly deeply, because none of the properties alone is very interesting; instead, try and absorb it as a whole.

We’ve already seen the “instant rules” for manipulating the rationals, and where they come from. Here, we’ll first quickly define the rational numbers themselves, and all the operations above, in “instant rule” format, just to have them all here in one place. Then we’ll go through all the properties that are required for mathematicians to be able to say that the operations on rationals “play nicely together” in the above sense; and we’ll be relying on the instant rules as our definitions, because they’re totally unambiguous. That way we can be much more sure that we’re not making some small error. (Relying on an intuition about how apples work could in theory lead us astray; but the rules leave no wiggle-room or scope for interpretation.)

The letters $$a, b, c, d$$ should be read as standing for integers (possibly positive, negative or $$0$$), and $$b$$ and $$d$$ should be assumed not to be $$0$$ (recalling that it makes no sense to divide by $$0$$).

• A rational number is a pair of integers, written as $$\frac{a}{b}$$, where $$b$$ is not $$0$$, such that $$\frac{a}{b}$$ is viewed as being the same as $$\frac{c}{d}$$ precisely when $$a \times d = b \times c$$. noteThis is just the instant rule for subtraction, below, together with the assumption that $$\frac{0}{x} = \frac{0}{y}$$ for any $$x, y$$ nonzero integers; in particular, the assumption that $$\frac{0}{b \times d} = \frac{0}{1}$$ when $$b, d$$ are not $$0$$, which we will need later.

• Addition: $$\frac{a}{b} + \frac{c}{d} = \frac{a \times d + b \times c} {b \times d}$$$• Subtraction: $$\frac{a}{b} - \frac{c}{d} = \frac{a}{b} + \frac{-c}{d} = \frac{a \times d - b \times c}{b \times d}$$$

• Multiplication: $$\frac{a}{b} \times \frac{c}{d} = \frac{a \times c}{b \times d}$$$• Division (where also $$c$$ is not $$0$$): $$\frac{a}{b} \big/ \frac{c}{d} = \frac{a}{b} \times \frac{d}{c} = \frac{a \times d}{b \times c}$$$

• Comparison (where we write $$\frac{a}{b}$$ and $$\frac{c}{d}$$ such that both $$b$$ and $$d$$ are positive noteRemember, we can do that: if $$b$$ is negative, for instance, we may instead write $$\frac{a}{b}$$ as $$\frac{-a}{-b}$$, and the extra minus-sign we introduce has now flipped $$b$$ from being negative to being positive.): $$\frac{a}{b} < \frac{c}{d}$$ precisely when $$\frac{c}{d}-\frac{a}{b}$$ is positive: that is, when $$\frac{b \times c - a \times d}{b \times d} > 0$$$which is in turn when $$b \times c - a \times d > 0$$$

## Every rational must have an anti-rational under addition noteMathematicians say that addition is invertible.

Concretely, every rational $$\frac{a}{b}$$ must have some rational $$\frac{c}{d}$$ such that $$\frac{a}{b} + \frac{c}{d} = \frac{0}{1}$$. We’ve already seen that we can define $$-\frac{a}{b}$$ to be such an “anti-rational”, but remember that in order to fit in with our instant rules above, $$-\frac{a}{b}$$ is also not a pair of integers; we should instead use $$\frac{-a}{b}$$.

Then $$\frac{a}{b} + \frac{-a}{b} = \frac{a \times b + (-a) \times b}{b \times b} = \frac{0}{b \times b}$$$Finally, we want $$\frac{0}{b \times b} = \frac{0}{1}$$; but this is immediate by the instant-rule definition of “rational number”, since $$0 \times 1 = 0 \times (b \times b)$$ (both being equal to $$0$$). ## Addition doesn’t care which way round we do it noteMathematicians say that addition is commutative. Concretely, this is the fact that $$\frac{a}{b} + \frac{c}{d} = \frac{c}{d} + \frac{a}{b}$$$ This is intuitively plausible because “addition” is just “placing apples next to each other”, and if I put five apples down and then seven apples, I get the same number of apples as if I put down seven and then five.

But we have to use the instant rules now, so that we can be sure our definition is completely watertight.

So here we go: $$\frac{a}{b} + \frac{c}{d} = \frac{a \times d + b \times c}{b \times d} = \frac{c \times b + d \times a}{d \times b} = \frac{c}{d} + \frac{a}{b}$$$where we have used the fact that multiplication of integers doesn’t care about the order in which we do it, and similarly addition of integers. ## Addition doesn’t care about the grouping of terms noteMathematicians say that addition is associative. Here, we mean that $$\left(\frac{a}{b} + \frac{c}{d}\right) + \frac{e}{f} = \frac{a}{b} + \left( \frac{c}{d} + \frac{e}{f} \right)$$$ This is an intuitively plausible fact, because “addition” is just “placing apples next to each other”, and if I put down three apples, then two apples to the right, then one apple to the left, I get the same number ($6$) of apples as if I had put down one apple on the left, then three apples in the middle, then two on the right.

But we have to use the instant rules now, so that we can be sure our definition is completely watertight. So here goes, starting from the left-hand side:

$$\left(\frac{a}{b} + \frac{c}{d}\right) + \frac{e}{f} = \frac{a \times d + b \times c}{b \times d} + \frac{e}{f} = \frac{(a \times d + b \times c) \times f + (b \times d) \times e}{(b \times d) \times f}$$

Since addition and multiplication of integers don’t care about grouping of terms, this is just $$\frac{a \times d \times f + b \times c \times f + b \times d \times e}{b \times d \times f}$$$Now going from the right-hand side: $$\frac{a}{b} + \left( \frac{c}{d} + \frac{e}{f} \right) = \frac{a}{b} + \frac{c \times f + d \times e}{d \times f} = \frac{a \times (d \times f) + b \times (c \times f + d \times e))}{b \times (d \times f)}$$ and similarly we can write this $$\frac{a \times d \times f + b \times c \times f + b \times d \times e}{b \times d \times f}$$$ which is the same as we got by starting on the left-hand side.

Since we showed that both the left-hand and the right-hand side are equal to the same thing, they are in fact equal to each other.

# How multiplication behaves

## Multiplication always spits out a rational number noteMathematicians say that the rationals are closed under multiplication.

This one is very easy to show: $$\frac{a}{b} \times \frac{c}{d} = \frac{a \times c}{b \times d}$$, but $$b \times d$$ is not zero when $$b$$ and $$d$$ are not zero, so this is a valid rational number.

## There must be a rational $$1$$ such that multiplying a thing by $$1$$ doesn’t change the thing noteMathematicians say that multiplication has an identity element.

From our motivation of what multiplication was (“do unto $$\frac{a}{b}$$ what you would otherwise have done unto $$1$$”), it should be clear that the number $$1$$ ought to work here. However, $$1$$ is not strictly speaking a rational number according to the letter of the “instant rules” above; so instead we use $$\frac{1}{1}$$.

## Multiplication doesn’t care which way round we do it noteMathematicians say that multiplication is commutative.

This had its own section on the multiplication page, and its justification there was by rotating a certain picture. Here, we’ll use the instant rule:

$$\frac{a}{b} \times \frac{c}{d} = \frac{a \times c}{b \times d} = \frac{c \times a}{d \times b} = \frac{c}{d} \times \frac{a}{b}$$
where we have used that multiplication of integers doesn’t care about order.

## Multiplication doesn’t care about the grouping of terms noteMathematicians say that multiplication is associative.

This is much harder to see from our intuition, because while addition is a very natural operation (“put something next to something else”), multiplication is much less natural (it boils down to “make something bigger”). In a sense, we’re trying to show that “make something bigger and then bigger again” is the same as “make something bigger by a bigger amount”. However, it turns out to be the case that multiplication also doesn’t care about the grouping of terms.

Using the instant rule for multiplication, it’s quite easy to show that $$\frac{a}{b} \times \left(\frac{c}{d} \times \frac{e}{f} \right) = \left(\frac{a}{b} \times \frac{c}{d} \right) \times \frac{e}{f}$$$Indeed, working from the left-hand side: $$\frac{a}{b} \times \left(\frac{c}{d} \times \frac{e}{f} \right) = \frac{a}{b} \times \frac{c \times e}{d \times f} = \frac{a \times (c \times e)}{b \times (d \times f)}$$ which is $$\frac{a \times c \times e}{b \times d \times f}$$ because multiplication of integers doesn’t care about the grouping of terms. On the other hand, $$\left(\frac{a}{b} \times \frac{c}{d} \right) \times \frac{e}{f} = \frac{a \times c}{b \times d} \times \frac{e}{f} = \frac{(a \times c) \times e}{(b \times d) \times f} = \frac{a \times c \times e}{b \times d \times f}$$$

These two are equal, so we have shown that the left-hand and right-hand sides are both equal to the same thing, and hence they are the equal to each other.

# How addition and multiplication interact

## Multiplication “filters through” addition noteMathematicians say that multiplication distributes over addition.

What we will show is that $$\left(\frac{c}{d} + \frac{e}{f}\right) \times \frac{a}{b} = \left(\frac{a}{b} \times \frac{c}{d}\right) + \left(\frac{a}{b} \times \frac{e}{f}\right)$$$This is intuitively true: the left-hand side is “make $$\frac{a}{b}$$, but instead of starting out with $$1$$, start with $$\left(\frac{c}{d} + \frac{e}{f}\right)$$”; while the right-hand side is “make $$\frac{a}{b}$$, but instead of starting out with $$1$$, start with $$\frac{c}{d}$$; then do the same but start with $$\frac{e}{f}$$; and then put the two together”. If we draw out diagrams for the right-hand side, and put them next to each other, we get the diagram for the left-hand side. (As an exercise, you should do this for some specific values of $$a,b,c,d,e,f$$.) We’ll prove it now using the instant rules. The left-hand side is $$\left(\frac{c}{d} + \frac{e}{f}\right) \times \frac{a}{b} = \frac{c \times f + d \times e}{d \times f} \times \frac{a}{b} = \frac{(c \times f + d \times e) \times a}{(d \times f) \times b}$$$ which is $$\frac{c \times f \times a + d \times e \times a}{d \times f \times b}$$.

## How comparison interacts with multiplication

The aim here is basically to show that we can’t multiply two things and get an anti-thing. Written out in the notation, we wish to show that if $$0 < \frac{a}{b}$$ and if $$0 < \frac{c}{d}$$ then $$0 < \frac{a}{b} \times \frac{c}{d}$$, since the test for anti-ness is “am I less than $$0$$?”.

Since $$0 < \frac{a}{b}$$, there are two options: either both $$a$$ and $$b$$ are positive, or they are both negative. (If one is negative and one is positive, then the fraction will be negative.)

Likewise either both $$c$$ and $$d$$ are positive, or both are negative.

So we have four options in total:

• $$a, b, c, d$$ are positive

• $$a, b, c, d$$ are negative

• $$a, b$$ are positive; $$c, d$$ are negative

• $$a, b$$ are negative; $$c, d$$ are positive.

In the first case, we have $$\frac{a \times c}{b \times d}$$ positive, because all of $$a, b, c, d$$ are.

In the second case, we have $$a \times c$$ positive and $$b \times d$$ also positive (because both are two negative integers multiplied together); so again the fraction $$\frac{a \times c}{b \times d}$$ is positive.

In the third case, we have $$a \times c$$ negative and $$b \times d$$ also negative (because both are a positive number times a negative number); so the fraction $$\frac{a \times c}{b \times d}$$ is a negative divided by a negative. Therefore it is positive, because we can multiply the numerator and the denominator by $$-1$$ to turn it into a positive divided by a positive.

We’ll consider $$\frac{1}{3}$$ and $$\frac{-2}{-5}$$. Then the product is $$\frac{1}{3} \times \frac{-2}{-5} = \frac{-2}{-15}$$; but that is the same as $$\frac{2}{15}$$.

In the fourth case, we can do the same as the above, or we can be a bit sneaky: using the fact from earlier that multiplication doesn’t care about order, we can note that $$\frac{a}{b} \times \frac{c}{d}$$ is the same as $$\frac{c}{d} \times \frac{a}{b}$$. But now $$c$$ and $$d$$ are positive, and $$a$$ and $$b$$ are negative; we’ve already shown (in the previous case) that if the first fraction is “positive divided by positive”, and the second fraction is “negative divided by negative”. By swapping $$a$$ for $$c$$, and $$b$$ for $$d$$, we can use a result we’ve already proved to obtain this final case.

Hence we’ve shown all four possible cases, and so the final result follows.

Parents:

• Do you think we could have the actual names of the rules as subheadings or as footnotes? Like, at the end of the “Multiplication doesn’t care about the grouping terms” we could write “Mathematicians call this the associative property of multiplication”.