%I #42 Jun 02 2021 15:11:03
%S 0,1,5,6,11,19,55,64,66,111,555,666,1111,1919,4268,4862,5555,6464,
%T 6666,9317,9713,11111,55555,66666,111111,191919,555555,646464,666666,
%U 1111111,5555555,6666666,11111111,19191919,42684268,48624862,55555555,64646464,66666666,93179317
%N Numbers k such that the infinite sequence of digits consisting of the final digit of k^m for m = 2, 3, 4, ... is the same as the sequence of digits obtained by concatenating infinitely many copies of k.
%C The numbers k of this sequence repeat from k^2 onward. For example, if number ends in 8, the last digit of the square of k will always be 4, the last digit of the cube of k will always be 2, the last digit of the fourth power of k will always be 6, and the fifth power of k will always be 8. Base numbers that end in 0, 1, 5, and 6 will always result in numbers with the same digit when they have positive integers as exponents. For k that have a 2 in the ones place, then the square of k will have 4 in the ones place, the cube of k will have 8 in the ones place, the fourth power of k will have 6 in the ones place, and the fifth power of k will have 2 in the ones place.
%C For any integer k, the ones digit of each higher power, i.e., k^2, k^3, k^4, etc., depends only on the ones digit of k as follows:
%C .
%C Ones digits in k and larger powers of k
%C --+------------------------------------ Resulting string of
%C k | k^2 k^3 k^4 k^5 k^6 k^7 k^8 k^9 ... concatenated digits
%C --+------------------------------------ -------------------
%C 0 | 0 0 0 0 0 0 0 0 ... 0000000000000000...
%C 1 | 1 1 1 1 1 1 1 1 ... 1111111111111111...
%C 2 | 4 8 6 2 4 8 6 2 ... 4862486248624862...
%C 3 | 9 7 1 3 9 7 1 3 ... 9713971397139713...
%C 4 | 6 4 6 4 6 4 6 4 ... 6464646464646464...
%C 5 | 5 5 5 5 5 5 5 5 ... 5555555555555555...
%C 6 | 6 6 6 6 6 6 6 6 ... 6666666666666666...
%C 7 | 9 3 1 7 9 3 1 7 ... 9317931793179317...
%C 8 | 4 2 6 8 4 2 6 8 ... 4268426842684268...
%C 9 | 1 9 1 9 1 9 1 9 ... 1919191919191919...
%C .
%C This sequence consists of each of the nonnegative integers that, when repeated infinitely, yields one of the digit strings in the column at the right.
%e The patterns that I have noticed and seen confirmed demonstrate that the infinite patterns that result with the end digits of exponents when n has a particular numerical value from k^2, k^3, k^4, and k^5 before they repeat are as follows: k with final digit 0 (0000); k with final digit 1 (1111); k with final digit 2 (4862); k with final digit 3 (9713); k with final digit 4 (6464); k with final digit 5 (5555); k with final digit 6 (6666); k with final digit 7 (9317); k with final digit 8 (4268); and k with final digit 9 (1919).
%e Therefore, the number 64 infinitely repeats because 64^2 equals 4096 (which ends in 6), 64^3 equals 262144 (which ends in 4), 64^4 equals 16777216 (which ends in 6), and 1073741824 (which ends in 4). 64 repeated twice in the previous demonstration, but all numbers infinitely repeat in the same way.
%e Additionally, 4862^2=23639044 (ends in 4), 4862^3=114933031928 (ends in 8), 4862^4=558804401233936 (ends in 6), and 4862^5=2716906998799396832 (ends in 2). The 4862 sequence among the final digits of the power for 4862 then continues infinitely as 4862^6 ends in 4, 4862^7 ends in 8, 4862^8 ends in 6), 4862 ends in 2, and so on.
%e One interesting fact about this sequence is that only the last digit of an odd-numbered power of k is necessary to determine the last digit of k itself.
%K nonn,base
%O 1,3
%A _Luke Voyles_, May 22 2021