My wife told me about someone on the radio yesterday discussing voluntary water rationing. People in odd-numbered houses are being asked to water their yards only on odd-numbered days. This person said “I suppose they’re talking about the last digit.”
When she told me about this, my first two thoughts were:
- Yes, that’s what it means to be odd.
- Nearly every house number in suburban Houston starts with 1, so going by first digit would be a bad idea.
Strictly speaking, it’s a theorem that odd numbers are those that end in odd digits. The definition of an odd number is one that leaves a remainder of 1 when divided by 2. And in base 10, a number is odd if and only if it ends in an odd digit.
But what if you were using a base other than 10? If the base is even, then a number is odd if and only if the last digit is odd, just like base 10. But what if you’re using an odd base, say base 7? Then the theorem doesn’t hold. For example the number 122 in base 7 is odd, and the number 33 is even. And it’s not just the opposite of the rule for base 10 because 43 is also odd in base 7.
In an odd base, a number is odd iff it has an odd number of odd digits.
(In case you haven’t seen “iff” before, it’s an abbreviation for “if and only if.”)
So, for example, in base 7, the number 642341 is even because it contains two odd digits. And the number 744017 in base 9 is odd because it has three odd digits.
Why does this rule work? Suppose, for example, you have a 4-digit number number pqrs in base b where b is odd. Then pqrs represents
p b3 + q b2 + r b + s
All the powers of b are odd, so a number like p times a power of b is odd iff p is odd. So every odd digit in the number contributes an odd number to the sum that expands what the number means. Even digits contribute even terms. A sum is odd iff it has an odd number of odd terms, so a number in an odd base is odd iff it has an odd number of odd digits.
Similar posts:
Divisibility by 7
Divisibility rules in hex
Casting out z’s


{ 2 trackbacks }
{ 9 comments… read them below or add one }
Glenn 08.17.11 at 08:52
Side note: The most obvious case for this rule is “base 1″, where a natural number N is represented as a string of N ones.
jd long 08.17.11 at 09:14
… which reminds me of an interesting pub discussion I had with some colleagues at one point. In short, is there any reason we use base 10 other than the fact we have 10 fingers? If all humans had 8 fingers would we use base 8?
What do you think?
ssam 08.17.11 at 10:36
your second thought is a good example of Benford’s law.
amy (john's wife) 08.17.11 at 15:08
Gee whiz, honey, I was just telling you about the dumb comment the newscaster made and you had to go all mathematical on me!
Matthias 08.17.11 at 19:01
>When she told me about this, my first two thoughts were:
> Yes, that’s what it means to be odd.
Give her the benefit of doubt: Perhaps she was talking about the days? Because you can either number the days again each month (last digit), or you can, say, number them continuously.
Matthias 08.17.11 at 19:07
jd long, base 10 vs base 8 is quite close together, so the number of fingers might have decided. But there are practical reasons why we don’t use base 2 or base 1043. The first leads to `long’ numbers, while the latter requires too many different digits.
IMHO we should all use base 11: We can comfortable count from zero to ten on our hands. So the jump should be afterwards. Also, no matter what base you choose, some rational numbers will lead to periodic fractions. So by choosing a prime base, we reduce the prevalence of the special case of fractions with a finite representation.
Lori Mathhead 08.18.11 at 00:14
Excellent post, John. Educators can use this explanation but stop at the “But what if you were using a base other than 10?…” question and lead students with many questions to figure out the rest. It will make a great project or math club exercise. Thanks!
Mike Albaugh 08.26.11 at 10:41
A not-so-esoteric case of this was the use of bi-qinary to encode decimal digits in some early computers (e.g. IBM 650, Univac SolidState). Each digit was encoded in four bits, weighted 5421. You only had to look at the least significant digit, as a number was odd if that digit had only one of 5 or 1 set. The only other mixed-radix system I recall was the use of LSD (Pounds, Shillings, and Pence) currency encoding. For more esoteric, you’d be looking for the radix -3 machine(s?) built by the Soviets in the 1950s. Odd in may ways, but “summing odd digits” still worked.
(Pedants: yes, the 650 used 2-of-7 coding, but was effectively bi-quinary)
Speedmaster 09.14.11 at 11:17
Posts like this are further evidence that you are much smarter than I am. Perhaps by an order of magnitude. Is it necessary to rub it my face so often?!