This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A373387 #35 May 03 2025 18:52:22 %S A373387 0,0,1,1,1,2,1,2,1,1,-1,1,1,1,1,4,1,1,2,1,-1,1,1,1,2,3,2,1,1,1,-1,1,2, %T A373387 1,1,2,1,1,1,1,-1,1,1,2,1,2,1,1,1,2,-1,2,1,1,1,3,1,3,1,1,-1,1,1,1,1,6, %U A373387 1,1,3,1,-1,1,1,1,2,2,2,1,1,1,-1,1,2,1 %N A373387 Constant congruence speed of the tetration base n (in radix-10), or -1 if n is a multiple of 10. %C A373387 It has been proved that this sequence contains arbitrarily large entries, while a(0) = a(1) = 0 by definition (given the fact that 0^0 = 1 is a reasonable choice and then 0^^b is 1 if b is even, whereas 0^^b is 0 if b is even). For any nonnegative integer n which is not a multiple of 10, a(n) is given by Equation (16) of the paper "Number of stable digits of any integer tetration" (see Links). %C A373387 Moreover, a sufficient condition for having a constant congruence speed of any tetration base n, greater than 1 and not a multiple of 10, is that b >= 2 + v(n), where v(n) is equal to %C A373387 u_5(n - 1) iff n == 1 (mod 5), %C A373387 u_5(n^2 + 1) iff n == 2,3 (mod 5), %C A373387 u_5(n + 1) iff n == 4 (mod 5), %C A373387 u_2(n^2 - 1) - 1 iff n == 5 (mod 10) %C A373387 (u_5 and u_2 indicate the 5-adic and the 2-adic valuation of the argument, respectively). %C A373387 Therefore b >= n + 1 is always a sufficient condition for the constancy of the congruence speed (as long as n > 1 and n <> 0 (mod 10)). %C A373387 As a trivial application of this property, we note that the constant congruence speed of the tetration 3^^b is 1 for any b > 1, while 3^3 is not congruent to 3 modulo 10. Thus, we can easily calculate the exact number of the rightmost digits of Graham’s number, G(64) (see A133613), that are the same of the homologous rightmost digits of 3^3^3^... since 3^3 is not congruent to 3 modulo 10, while the congruence speed of n = 3 is constant from height 2 (see A372490). This means that the last slog_3(G(64))-1 digits of G(64) are the same slog_3(G(64))-1 final digits of 3^3^3^..., whereas the difference between the slog_3(G(64))-th digit of G(64) and the slog_3(G(64))-th digit of 3^3^3^... is congruent to 6 modulo 10. %C A373387 The constant congruence speed of tetration satisfies the following multiplicative constraint: for each pair (n_1, n_2) of nonnegative integers whose product is not divisible by 10, a(n_1*n_2) is necessarily greater than or equal to the minimum between a(n_1) and a(n_2) (see Equation 2.4 and Appendix of "A Compact Notation for Peculiar Properties Characterizing Integer Tetration" in Links). - _Marco Ripà_, Apr 26 2025 %D A373387 Marco Ripà, La strana coda della serie n^n^...^n, Trento, UNI Service, Nov 2011. ISBN 978-88-6178-789-6. %H A373387 Marco Ripà, <a href="https://doi.org/10.7546/nntdm.2020.26.3.245-260">On the constant congruence speed of tetration</a>, Notes on Number Theory and Discrete Mathematics, Volume 26, 2020, Number 3, Pages 245—260. %H A373387 Marco Ripà, <a href="https://doi.org/10.7546/nntdm.2021.27.4.43-61">The congruence speed formula</a>, Notes on Number Theory and Discrete Mathematics, 2021, 27(4), 43—61. %H A373387 Marco Ripà, <a href="https://www.researchgate.net/publication/387314761_Twelve_Python_Programs_to_Help_Readers_Test_Peculiar_Properties_of_Integer_Tetration">Twelve Python Programs to Help Readers Test Peculiar Properties of Integer Tetration</a>, ResearchGate, 2024. See pp. 22-23, 27. %H A373387 Marco Ripà and Gabriele Di Pietro, <a href="https://doi.org/10.5281/zenodo.15276825">A Compact Notation for Peculiar Properties Characterizing Integer Tetration</a>, Zenodo, 2025. %H A373387 Marco Ripà and Luca Onnis, <a href="https://doi.org/10.7546/nntdm.2022.28.3.441-457">Number of stable digits of any integer tetration</a>, Notes on Number Theory and Discrete Mathematics, 2022, 28(3), 441—457. %H A373387 Wikipedia, <a href="https://en.wikipedia.org/wiki/Graham's_number">Graham's Number</a>. %H A373387 Wikipedia, <a href="https://en.wikipedia.org/wiki/Tetration">Tetration</a>. %F A373387 a(n) = -1 iff n == 0 (mod 10), a(n) = 0 iff n = 1 or 2. Otherwise, a(n) >= 1 and it is given by Equation (16) from Ripà and Onnis. %e A373387 a(3) = 1 since 3^^b := 3^3^3^... freezes 1 more rightmost digit for each unit increment of b, starting from b = 2. %o A373387 (Python) %o A373387 def v2(n): %o A373387 count = 0 %o A373387 while n % 2 == 0 and n > 0: %o A373387 n //= 2 %o A373387 count += 1 %o A373387 return count %o A373387 def v5(n): %o A373387 count = 0 %o A373387 while n % 5 == 0 and n > 0: %o A373387 n //= 5 %o A373387 count += 1 %o A373387 return count %o A373387 def V(a): %o A373387 mod_20 = a % 20 %o A373387 mod_10 = a % 10 %o A373387 if mod_20 == 1: %o A373387 return min(v2(a - 1), v5(a - 1)) %o A373387 elif mod_20 == 11: %o A373387 return min(v2(a + 1), v5(a - 1)) %o A373387 elif mod_10 in {2, 8}: %o A373387 return v5(a ** 2 + 1) %o A373387 elif mod_20 in {3, 7}: %o A373387 return min(v2(a + 1), v5(a ** 2 + 1)) %o A373387 elif mod_20 in {13, 17}: %o A373387 return min(v2(a - 1), v5(a ** 2 + 1)) %o A373387 elif mod_10 == 4: %o A373387 return v5(a + 1) %o A373387 elif mod_20 == 5: %o A373387 return v2(a - 1) %o A373387 elif mod_20 == 15: %o A373387 return v2(a + 1) %o A373387 elif mod_10 == 6: %o A373387 return v5(a - 1) %o A373387 elif mod_20 == 9: %o A373387 return min(v2(a - 1), v5(a + 1)) %o A373387 elif mod_20 == 19: %o A373387 return min(v2(a + 1), v5(a + 1)) %o A373387 def generate_sequence(): %o A373387 sequence = [] %o A373387 for a in range(1026): %o A373387 if a == 0 or a == 1: %o A373387 sequence.append(0) %o A373387 elif a % 10 == 0: %o A373387 sequence.append(-1) %o A373387 else: %o A373387 sequence.append(V(a)) %o A373387 return sequence %o A373387 sequence = generate_sequence() %o A373387 print("a(0), a(1), a(2), ..., a(1025) =", ", ".join(map(str, sequence))) %Y A373387 Cf. A067251, A133613, A317824, A317903, A317905, A349425, A370211, A370775, A371129, A371671, A372490. %Y A373387 Cf. A000007, A018247, A018248, A063006, A091661, A091663, A091664, A120817, A120818, A290372, A290373, A290374, A290375. %K A373387 sign,base %O A373387 0,6 %A A373387 _Marco Ripà_, Jun 02 2024