OFFSET
1,2
COMMENTS
The integer tetration (or hyper-4) n^^b is characterized by a well-known property involving its rightmost digits (as b grows an increasing number of the rightmost digits of n^^b are frozen - following the general rule described by Equation (16) of the linked paper "Number of stable digits of any integer tetration", p. 454).
In 2011 Ripà conjectured that, for any n >= 1, if b >= n + 2, then the n rightmost digits of n^^b are stable.
The above-mentioned paper, published in 2022, proved that this conjecture is true and also stated the stronger sufficient condition that the height of the hyperexponent is greater than or equal to tilde(v(a)) + 2, where tilde(v(a)) := v_5(a - 1) iff a == 1 (mod 5), v_5(a^2 + 1) iff a == {2, 3} (mod 5), v_5(a + 1) iff a == 4 (mod 5), v_2(a^2 - 1) - 1 iff a == 5 (mod 10), where v_2(x) = A007814(x) and v_5(x) = A112765(x) are the 2-adic and 5-adic valuations of x, respectively. - Marco Ripà, Jul 24 2024
REFERENCES
Marco Ripà, La strana coda della serie n^n^...^n, Trento, UNI Service, Nov 2011. ISBN 978-88-6178-789-6.
LINKS
Marco Ripà, On the constant congruence speed of tetration, Notes on Number Theory and Discrete Mathematics, 2020, 26(3), 245-260.
Marco Ripà, The congruence speed formula, Notes on Number Theory and Discrete Mathematics, 2021, 27(4), 43-61.
Marco Ripà and Luca Onnis, Number of stable digits of any integer tetration, Notes on Number Theory and Discrete Mathematics, 2022, 28(3), 441—457.
Wikipedia, Tetration.
FORMULA
a(n) = (n^^(n + 2)(mod 10^n) - n^^(n + 2)(mod 10^(n - 1)))/10^(n - 1).
EXAMPLE
For n = 3, a(3) = 3 since 3^^5 == 387(mod 10^3). Thus, (387(mod 10^3) - 387(mod 10^2))/10^2 = 3.
MAPLE
b:= proc(n) option remember; local m, v, w; m, w:= 10^n, n;
do v:= n&^w mod m; if w=v then return v else w:=v fi od
end:
a:= n-> `if`(irem(n, 10)=0, 0, iquo(b(n), 10^(n-1))):
seq(a(n), n=1..100); # Alois P. Heinz, Nov 17 2021
PROG
(Python)
def A349425(n):
if n % 10 == 0: return 0
m, n1, n2 = n, 10**n, 10**(n-1)
while (k := pow(n, m, n1)) != m: m = k
return k//n2 # Chai Wah Wu, Dec 19 2021
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Marco Ripà, Nov 17 2021
STATUS
approved