OFFSET
1,2
COMMENTS
This sequence consists of the positive integers m such that m^m == m^(m^m) (mod 10^m).
All multiples of 10 are terms, since then m^m == m^(m^m) == 0 (mod 10^m).
5 is the only term m > 1 not a multiple of 10 (5^5 = 3125 and 5^(5^5) = ...03125). A compact proof of this fact has been published on Mathematics Stack Exchange by John Omelian (see Links).
LINKS
Marco Ripà, Congruence speed of tetration bases ending with 0, arXiv:2402.07929 [math.NT], 2024.
Mathematics Stack Exchange, Easy proof that n = 5 is the only solution of n^n == n^n^n (mod 10^(n - 1)) if n > 1 is not a multiple of 10 .
Index entries for linear recurrences with constant coefficients, signature (2,-1).
FORMULA
a(n) = 10*(n - 2) for any n > 2.
From Stefano Spezia, Mar 03 2024: (Start)
G.f.: x*(1 + 3*x + x^2 + 5*x^3)/(1 - x)^2.
E.g.f.: 20 + 10*exp(x)*(x - 2) + 11*x + 5*x^2/2. (End)
EXAMPLE
20 is a term since 20^20 == 0 (mod 10^20) and also 20^(20^20) == 0 (mod 10^20).
MATHEMATICA
Join[{1, 5}, 10*Range[100]] (* Paolo Xausa, Mar 15 2024 *)
PROG
(Python)
def A370532(n): return 10*(n-2) if n>2 else 4*n-3 # Chai Wah Wu, Mar 11 2024
CROSSREFS
KEYWORD
nonn,easy,base
AUTHOR
Marco Ripà, Feb 21 2024
STATUS
approved