*Rough Maths 6*

When we last looked at arithmetic, we had found that we had to make 90 repayments, and we couldn’t get an exact answer to the question of how many years that would take if we paid it every fortnight. So let’s see:

90 ÷ 26 = 90/26

This fraction is both vulgar and improper: the former means that it is a simple ratio of a/b, the latter means that the number on top is greater than that on the bottom. It’s also a tautology, because our formula means “90 divided by 26 equals 90 divided by 26”.

(As an aside: Wittgenstein thought that all of mathematics was an endlessly elaborated tautology of this nature, which, in my opinion, makes Wittgenstein as wrong about maths as as any genius has been about anything. Which is very wrong indeed.)

A proper fraction – I don’t know why fractions terminology is so snooty: perhaps it was once used to sort out the sheep from the goats – shows a whole number, giving the number of times the dividing number can go into the divided, and a fraction showing the remainder:

90/26 = 3 12/26

This is a social step upward, with none of those top-heavy fractions. But we are still left with a remainder – 12/26 – which we can’t express in terms of our set of positive and negative numbers.

We can reduce it by dividing the top and the bottom by 2 (which is allowed: trust me) giving us 6/13: another division. I have a confession to make: the number line from Rough Maths 3 was slightly deceptive. Since we had only integers, our number line is not a line in the strictest sense: it is a set of points, each 1 unit away from its two neighbours.

The question “what sort of number is 6/13” should give us an intuitive hint as to what lies between the integers on the number line: something six thirteenths of the way along the gap between zero and one.

A way of making this intuition more concrete is to express our fraction as a decimal. Decimal fractions take the way in which a positional number system can express any integer as a sum of powers of ten:

1, 10, 100, 1000, 10000 …

And extend these backwards, into negative powers of ten (just trust me on that one for now):

0.1, 0.01, 0.001, 0.0001 …

Since we can represent any integer by choosing the right set of powers of ten, we should be able to use decimals to represent any of the numbers which lie between the integers.

Shouldn’t we?

If we follow this line of argument much further, we’ll get us into surprisingly deep water, and a fair chunk of the history of 19^{th} century mathematics, before long.

For now, we just want 6/13 as a decimal fraction. Doing this from scratch requires a peculiar form of long division: but here’s one I prepared earlier.

6/13 = 0.461538 461538 461538 …

The peculiarity of the long division is that it is cyclical: the same digits, 4, 6, 1, 5, 3, 8 will continue for as long as we care to calculate them. But this gives us something: we can now say that 6/13 is a little shy of halfway along the gap between 0 and 1, or that our 90 ÷ 26 = 3.4615.

However, we’ve also lost something: a tiny amount of accuracy. The number 90 6/13 is, by definition, exactly 90 6/13. However, 3.4615 is not: it is around 0.00004 away from the exact value.

The only fractions which can be written as non-repeating decimals in our base-10 number system are those which have a common divisor with 10: all other fractions are repeating decimals. For example, 1/2 = 0.5 and 1/5 = 0.2, but 1/3 = 0.3333… and 1/7 = 0.142857…

This isn’t important if you’re trying to measure a piece of timber which is 3 and 6/13ths of a meter long, but it matters if you are trying to get a computer to perform arithmetic on numbers which aren’t integers.

Computers represent numbers in binary, or base 2: this means that the only fractions which have a finite number of digits are those where the denominator is a power of two: 4, 8, 16, 32 and so on. All other fractions will have an indefinite repeating expansion, like 6/13. As any computer is only going to have a finite number of bits to store a value, there will be a fudge factor between the actual value and the real digital value, and this fudge factor can cause weird, slightly wrong values when the binary number is converted back to base 10.

This is one reason for why, on the inside, any computer program dealing with monetary values will count it in cents, rather than dollars: storing 20.95 as 2095 removes the possibility of rounding errors.

Leaving computers aside, we now have a way of expressing any fraction a / b (tautologically) and representing the fraction as a decimal (usually with a small fudge factor which we can make as negligible as we like).

This gets us a fairly modern, up-to-date number system which was state-of-the art in roughly 800CE, and which will start to come adrift as soon as we try to do anything like calculate the diagonal of a square.

6/13 = 0.461538 461538*4* 4615386 …

(You have an extra trailing “4” on the second repeating block)

…as well as an extra trailing 6 at the end. Thanks!

AKAIK yo’uve got the answer in one!