Tuesday, 1 September 2009

I was recently reading an interesting blog posted by Rick Regan at Exploring Binary
talking about the binary expansion of base ten numbers that are made up of repeating nines...

"I discovered a cool property of positive integers of the form 10n-1, that is, integers made up of n digits of 9s: they have binary representations that have exactly n digits of trailing 1s. For example, 9,999,999 in decimal is 100110001001011001111111 in binary. "

Rick went on to show that this must always be the case with some pretty simple algebra. He noticed that the part of the number preceding the repeating ones is the binary for 5n-1... ok here is a simple example... 102-1 =99 in base ten and in base two that is 1100011,.... the two repeating 1's at the end have a value of 22-1, the 11000 in front is the binary expression for 24 or 52-1.
Rick showed that 10n-1 can always be expressed as
(5n – 1) 2n + (2n – 1)...

It occurred to me as I read his blog, that we could also expres 10n-1 as

2n (5n) - 5n + 5n-1 by adding and subtracting 5n instead of 2n

Regrouping that as (2n-1 )5n +( 5n-1) shows that when expressed in base five, 10n -1 will begin with 2n-1 base five followed by a string of n fours,

9 [5] = 1 4

99[5]= 344

999[5]= 12444


A similar event happens (I think, but do not prove) for any (pq)n -1 if p and q are (relatively?) Prime when expressed in base p or base q
... for example instead of 10n-1, if we used 6n-1 we would get
2n(3n) - 2n+2n-1 In base two that would show up as the base two number for 3n followed by a string of n ones.

For example 63-1 in base two is 11010111. The front part, 11010, is 26 or 33-1 in base ten, and then followed by three ones..

We could do the same switch to express it in base three.
The same number (63-1) in base three would give 21222, with 21 in front being the base three for 7 or 23-1 and then followed by a string of three twos..

If you want to explore binary problems, he Rick also has a convertor on his web page to go between decimal and binary. Of course you can always use Wolfram-alpha [I have a little "alpha" gadget on my I-google page to keep it handy]... By writing "convert 315 base 8 to base 3" it gave me 211213.

As a side note, I find that using alternate bases helps lots of kids really get a feel for polynomials they never had before (and perhaps a deeper understanding of the decimal system they thought they had fully mastered. Quickly students, can you see why 11010111 in base two would be 3113 in base four?
Post a Comment