Irrational Numbers

by Shelley Walsh ©2000

The textbook that I teach algebra from gives the following characterization of rational and irrational numbers. Many other textbooks and internet sites as well give the same characterization.

Rational numbers - all terminating or repeating decimals
Irrational numbers - all nonterminating, nonrepeating decimals
Then after reading such a characterization I give my students the problem of deciding whether 22/7 is a rational number on a test and they always get it wrong, because they divide it out on their calculator, and since it takes 6 places before 7ths repeat, they can't tell from the calculator display for sure that it is repeating, so they say it is irrational. Obviously I have neglected to explain something. By looking at the long division involved in converting a fraction to a decimal it is possible to see that all fractions can be converted either to terminating or repeating decimals. The way to see this is that as soon as you get a remainder which is the same as one you have gotten before the pattern of decimals will have to repeat, and since the remainder has to be smaller than the divisor, there are only finitely many possible remainders, so this must happen. Using this argument I should be able to convince you that all fractions with natural numbers for numerator and demoninator are rational numbers.

Great! Problem solved. Now nobody should ever want to tell me that 22/7 is an irrational number again. At least not unless they think it is pi. (See Pi on the Web to find out all about pi.)

But what's wrong with this picture?

Well, to start, it makes me cringe like fingernails on a chalkboard. Why hasn't anyone asked why anyone cares about such a silly definition? Decimals that either terminate or repeat? I can possibly see the reason maybe in making a 3 part distinction, between those that end, those that repeat, and those don't terminate and don't repeat, but even that seems a bit unmotivated. What is so special about repeating decimals and why in the world would one want to lump together the terminating and the repeating ones? The answer to this is that is that nobody is in the slightest bit interested in this distinction, it is a totally different and much simpler and more basic distinction that lies behind the classification of numbers as rational and irrational. The emphasis on decimal expansion for telling about rational and irrational numbers is also grossly wrong from a historical point of view as well. The concept that rational and irrational numbers came from originated in ancient times when they didn't even use decimal representations of fractions.

Here's the story.

For most of man's history we didn't even know what a number was, beyond 3, people counted 1, 2, many, and that was good enough. For most of man's numerate history number meant what it means to a small child, what you count with, 1,2,3,4,..., what mathematicians nowadays call natural numbers. The ancient Greeks didn't even regard 1 as a number. Instead it was the unit, out of which all other numbers are made of. But the Greeks and others found that you could use numbers to measure as well as count, by using ratios of numbers, which eventually became what we know of as fractions. Actually early people didn't really quite think of fractions exactly the way we do nowadays, but that is just a minor detail.

The Pythagoreans in ancient Greece believed in a religious way that all was number, and all physical reality could be expressed and understood through numbers, and in particular that all lengths could be expressed in terms of ratios of one another. And indeed this seems at least to me to be a perfectly reasonable belief. After all, I can certainly take out a ruler and measure any distance I want, and express this measurement as a ratio of counting numbers. For example if the length is
 

5
7
8
units, then this can be written as the ratio 47/8. Of course if my ruler was only marked in eighths, this measurement might be only an approximation, but it would seem that if I could have a super ruler so that I could divide up my units into as many pieces as you want, that I should be able to measure any distance I want accurately and by doing this express the distance as a ratio of the unit.

But no, life or human thought, however you look at it, is not that simple, and to their great surprise, the ancient Greeks and many others made the shattering discovery that there are incommensurable lengths, lengths that cannot be written as ratios of eachother. Lengths that seemingly cannot be measured by numbers or ratios of numbers. Probably the first such discovery that was made was that the diagonal of a square is not commensurable with its side length, but there are many others.

To understand what is happening with the diagonal of a square you need to look at this picture.

If the side lengths of the small squares are 1, then the area of the big square is 4. The area of the red square whose sides are the diagonals of the little squares then must be 2. That means that the length of the diagonal must be a number whose square is 2. 1 times 1 is 1 and 2 times 2 is 4, so there is no counting number that you can multiply by itself to get 2, but that diagonal is a perfectly good real length, so one ought to be able to take a ruler out and measure it and get something somewhere between 1 and 2 that can be converted to an improper fraction and seen to be a ratio of counting numbers. Since it is not a whole number its denominator when reduced to lowest terms would have to be bigger than 1. So we should be able to write this number as a/b, where a/b is reduced to lowest terms, a and b are counting numbers, and b>1. But if you square such a number you will get a2/b2, and the key important thing to realize here is that this too must be in lowest terms, because for it not to be there would have to have been some cross canceling, which is impossible because the numbers to cross cancel are the same as those in the original fraction, and we are assuming that the original fraction was in lowest terms. But that means that a2/b2 couldn't possibly be 2 or for that matter any whole number, because its denominator is the square of a number bigger than 1, so must also be bigger than 1.

So here we have a very strange thing indeed, a length that we cannot attach a number or even a ratio of numbers too. It is interesting to explore a bit further what this means, because I think if you do you too will find it a very strange and exotic thing. Another way of thinking about incommensurable lengths is that if you chose to try to measure them without using fractions at all, but simply by using a small enough unit, no matter how small a unit you chose you couldn't get a whole number answer for both the side and the diagonal of the square. You could also look at this by thinking about the image on the computer screen. Here is the corner of my square in fat bits.

In the imperfect computer screen image both the sides and the diagonal are made by little squares. They both can be made up of the same sized squares, because the diagonal length is created with little diagonals of those squares, but if I were to rotate the diagonal to try to form the same length on its side, I actually couldn't quite do it. The line would have to change its length slightly in order to accommodate to the resolution of the screen. This may not seem so surprising when thinking about just one screen resolution, but the fact that these lengths are incommensurable says that it would happen no matter how good the screen resolution was. Even if your resolution was a google dpi or even a googleplex dpi or even some weird number like a google and three dpi, all diagonal lines will change size just a little bit if they are rotated to be horizontal or vertical.

Getting back to the idea of rational and irrational numbers, gradually in the course of the history of mathematics ratios of numbers came to be thought of as numbers, but it took a bit longer for an idea of numbers that could measure incommensurable lengths to be invented. It is indeed somewhat complicated to do this properly, but it is possible to use infinite decimals to represent them, provided you can believe that such decimals really represent anything at all. It takes mathematics that is more complicated than I want to include here to do this really mathematically properly, but hopefully you can see that it is at least plausible for them to be capable of representing such lengths. To think of this matter without making it too complicated we imagine a number system where the numbers correspond to point on a line called the real numbers. The line goes in both directions, so that we can deal with another kind of numbers also not considered by the ancients, negative numbers. The real numbers that can be represented by positive or negative ratios of natural numbers, along with also 0 are called the rational numbers. A concise way of stating this is that a rational number is any real number that can be written as p/q where p and q are integers (the integers are the positive and negative counting numbers along with 0) and q is not zero. This includes all the integers as well, because q can be 1. It includes everything except for those weird kind of numbers that are difficult to believe in that correspond to incommensurable lengths.

Okay, so what does this all have to do with decimals? In some sense not really much. They certainly had nothing to do with the original motivation for classifying numbers into rational and irrational. Decimal representation of fractions was a relative late invention, promoted in Europe first by Simon Stevin in the 17th century as a method for simplifying fraction computations, allowing for fraction computations to be performed just like whole number computations. There is a weakness, however, to decimals, that becomes also their strength with respect to irrational numbers. Because finite decimals can only express fractions with denominators that are powers of 10, many fractions must have infinite decimal expansions, so this opens the way to using other infinite decimals for representing irrational numbers.

Any fraction whose denominator doesn't divide evenly into a power of ten can't be written as a finite decimal, so from the decimal form it might seem that it would be difficult to tell such rational numbers from irrational numbers, except for one interesting thing about infinite decimals that come from fractions. They repeat. When you try to convert fractions whose denominators are not powers of 10 into decimals, what stops you from ever finishing is that at some point you end up with a remainder that is the same as one that you got before, so you end up getting the same sequence of digits over and over again. This is what I was talking about above with 22/7. In fact you can say a bit more than that. The repetition pattern will always be no more that 1 less than the denominator. So for example it could take 16 places for the decimal expansion of 1/17 to repeat, but no more than that. This is because when dividing out 1/17 there are only 16 possible remainders. (0 doesn't count because if the remainder where 0 it would be a finite decimal.) Because of this after 16 places all the possible remainders will be used up, so the next remainder will have to be one of the previous ones and from there on the same things will happen over and over again in the long division creating a repeating sequence.

The converse is true as well, every repeating decimal can be written as a fraction. To show you why this is true I will show you how to do it by looking at some examples.

Example 1:

Convert .333... to a fraction.

Solution:

If x=.333..., then 10x=3.3333..., so 10x-x=3. But 10x-x is also 9x, so 9x=3. By dividing both sides by 9, we get x=3/9=1/3.

Example 2:

Convert .12121212... to a fraction.

Solution:

If x=.12121212..., then 100x=12.121212...., so 100x-x=12. But 100x-x is also 99x, so 99x=12. By dividing by sides by 99, we get x=12/99=4/33.

Example 3:

Convert .1666666.... to a fraction.

Solution:

If x=.1666666...., then 100x=16.66666.... and 10x=1.6666..., so 100x-10x=15. But 100x-10x is also 90x, so 90x=15. By dividing both sides by 90 we get x=15/90=1/6.

I think you can see from these examples that this kind of technique will work for any repeating decimal. The idea is to multiply by two powers of ten so that the decimal parts are the same, so that when you subtract the decimal part will go away.

Putting these two together we get a way to tell whether a decimal represents a fraction, that is a rational number.

A decimal represents a fraction if and only if it terminates or repeats.

This is the origin of the textbook characterization of rational numbers that I quoted at the beginning of this article. The characterization is of course true, because of this, but it is totally missing the point to use such a characterization to determine whether a fraction like 22/7 is rational. 22/7 is rational, because it is a ratio of integers, which is the original meaning of rational number. An irrational fraction is a contradiction in terms. It would be like saying that a fraction was not a fraction. Yes, you could see this by seeing that the decimal expansion repeats, but there is no reason to do that, because for one it is known that this is true for all fractions and for another if it weren't true for all fractions that wouldn't be a proper characterization of rational, because the whole point of that characterization was for it to be a way to tell if a decimal came from a fraction in the first place.

So what use is this characterization then? Not really much. Any time you would need to do some computing with a calculator in order to get a number into decimal form, it is of no use, because you can't possibly tell from your calculator whether a decimal repeats or even whether it terminates, because it might do either way beyond the number of place that your calculator displays. Remember a number like 1/17 could take as many as 16 places before it repeats. The only real use for this characterization of rational and irrational numbers is for determining if a number that is already in decimal form is a rational number.

Shelley's Math Articles