OFFSET
1,1
COMMENTS
If a(n) < 4*5^(n-1) then the non-identical condition does not change terms. - David A. Corneth, May 29 2026
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..1000 (terms 501..800 from David A. Corneth)
David A. Corneth, PARI program
EXAMPLE
For a(1), k = 5, j = 1 since the last digit of 2^5 = 32 and 2^1 = 2 are the same.
For a(2), k = 14, j = 11 since the last two digits of 2^14 = 16384 and 2^11 = 2048 are distinct anagrams.
a(3) = 21 as 21 is the smallest k whose last 3 digits (152) are an anagram of the last 3 digits of 2^j (j = 9 with anagram 512) and both anagrams have no leading zeros. - David A. Corneth, May 28 2026
For a(5), k = 85, j = 56 since the last five digits of 2^85 = 3...97632 and 2^56 = 7...27936 are anagrams. (If leading zeros were allowed, we would have k = 71 and j = 26 from 2^71 = 2...06848 and 2^26 = 6...08864.)
PROG
(Python)
def a(n):
if n == 1: return 5
seen, modder = dict(), 10**n
pow2mod = pow(2, 3*n, modder)
for k in range(3*n, modder+1):
s = str(pow2mod)
if len(s) == n:
key = "".join(sorted(s))
if key in seen and seen[key][0] != s:
return k
else:
seen[key] = (s, k)
pow2mod = 2*pow2mod%modder
return -1
print([a(n) for n in range(1, 51)]) # Michael S. Branicky, May 28 2026
(PARI) \\ See Corneth link
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rhys Feltman, Apr 10 2026
EXTENSIONS
a(7) onward from Michael S. Branicky, May 27 2026
STATUS
approved
