cp's OEIS Frontend

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.

A377403 For n >= 2, a(n) is the number of iterations needed for the map: x -> x / A085392(x) if A085392(x) > 1, otherwise x -> x + A151800(x), to (the first occurrence of) 2.

This page as a plain text file.
%I A377403 #19 Oct 31 2024 01:40:11
%S A377403 0,3,1,3,1,3,2,4,1,4,2,3,1,4,3,4,2,3,2,4,1,3,3,4,1,5,2,4,2,3,4,4,1,4,
%T A377403 3,3,1,4,3,4,2,4,2,5,1,4,4,4,2,4,2,5,3,4,3,4,1,5,3,7,1,5,5,4,2,3,2,4,
%U A377403 2,6,4,4,1,5,2,4,2,5,4,6,1,3,3,4,1,4,3,3,3,4,2,4,1,4,5,4,2,5,3,4,2,4,3,5,1,6,4,3,2,4,4,6,2,4,2,5,1,4,4,5
%N A377403 For n >= 2, a(n) is the number of iterations needed for the map: x -> x / A085392(x) if A085392(x) > 1, otherwise x -> x + A151800(x), to (the first occurrence of) 2.
%C A377403 Also a(2*k + 1) = A001222(2*k + 1) + 2 + s, where s >= 1 for k = 5, 8, 14, 20, 21, 23, 26, 29, 30, 35, 36, 39, 48, 50, 51, ...
%F A377403 For n even: a(n) = A001222(n) - 1.
%F A377403 For n odd: a(n) = A001222(n) - 1 + A001222(A013634(A020639(n))).
%e A377403 n = 3: 3 -> 8 -> 4 -> 2, 3 iterations needed to reach 2, thus a(3) = 3.
%e A377403 n = 9: 9 -> 3 -> 8 -> 4 -> 2, 4 iterations needed to reach 2, thus a(9) = 4.
%e A377403 n = 11: 11 -> 24 -> 8 -> 4 - > 2, 4 iterations needed to reach 2, thus a(11) = 4.
%t A377403 a[2] = 0; a[n_] := -1 + Length@ NestWhileList[If[CompositeQ[#], #/FactorInteger[#][[-1, 1]], # + NextPrime[#]] &, n, # > 2 &]; Array[a, 120, 2] (* _Amiram Eldar_, Oct 27 2024 *)
%Y A377403 Cf. A001222, A013634, A020639, A085392, A107286, A151800.
%K A377403 nonn
%O A377403 2,2
%A A377403 _Ctibor O. Zizka_, Oct 27 2024