2 5 1 2 5 2 2 5 3 2 5 4 ⋮ ≡ 2 5 ≡ 6 2 5 ≡ 6 2 5 ≡ 6 2 5 ⋮ ( m o d 1 0 0 0 ) ( m o d 1 0 0 0 ) ( m o d 1 0 0 0 ) ( m o d 1 0 0 0 ) ⋮
We know that the last 3 digits of 2 5 n will always be a constant 625 for large enough integer values of n .
What is the smallest positive integer value a such that the last 5 digits of ( 5 a ) n will always be a constant for large enough integer values of n ?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Great work! I was slightly amazed at this result when I was working it out, and then it became "obvious" why it had to be true.
I'm hosting a Wiki Collaboration party on Finding the last few digits of a power this Saturday at 8am PDT. Would you be able to contribute?
How do we find the multiplicative order of large numbers sir?
I generated the first several powers of 5 and noticed that the first recurrence of the same 5 digits is 5 5 = 0 3 1 2 5 ; 5 1 3 = … 0 3 1 2 5 . Since the last five digits determine the last five digits for all subsequent powers of five, the period at which they repeat is 1 3 − 5 = 8 . Thus we choose a = 8 , and conclude that all ( 5 8 ) n must end in 90625.
It's great that you spotted the pattern. Can you explain in further detail why this pattern exists?
Log in to reply
There must be a pattern.
Let L ( n ) be the last five digits of 5 n . Then L ( n + 1 ) is uniquely determined by L ( n ) , so that (by simple induction) if L ( n + a ) = L ( n ) then L ( n + k a + m ) = L ( n + m ) ( k , m = 0 , 1 , … ) . In other words, the a numbers L ( n ) through L ( n + a − 1 ) repeat infinitely.
Now suppose that there were no repeating pattern. Then all L ( n ) must be different, because as soon as there is a repeat there is an infinite pattern. However, for the last five digits there are only 1 0 5 possibilities. Therefore the L ( n ) cannot be all different; there must be repetition at some point; and therefore an infinitely repeating pattern.
Following this argument, it may take up to 1 0 5 steps to enter the repeating pattern; even if we account for the fact that all higher powers of 5 end in 125 and 625, there are still 200 possibilities to try. In a sense I was therefore lucky to spot the pattern so soon!
Log in to reply
Great, that's the existence proof for the pattern, which is the typical periodic in a linear recurrence argument.
Can you give the construction proof? What is so special about 8, in particular A = 5 8 − 1 , such that A × 5 n ≡ 5 n ( m o d 1 0 5 ) ?
@Calvin Lin There is slight error in problem. 2 5 ≡ 2 5 ( m o d 1 0 0 ) should be 2 5 ≡ 2 5 ( m o d 1 0 0 0 ) , and so since it says last 3 digits.
Problem Loading...
Note Loading...
Set Loading...
For large enough n , we need that 1 0 5 ∣ ( 5 a ( n + 1 ) − 5 a n ) , or 1 0 5 ∣ 5 a n ( 5 a − 1 ) . For large enough n , this happens if and only if 2 5 ∣ ( 5 a − 1 ) . The multiplicative order of 5 mod 3 2 is easily found to be 8 .