login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

a(n) = number of iterations of x -> 2 x - 5 to reach a nonprime, starting with prime(n+4).
5

%I #4 Nov 13 2024 17:26:27

%S 8,1,7,1,2,6,1,1,1,1,3,5,2,1,1,3,1,1,1,2,1,4,1,1,1,1,1,4,2,1,2,1,1,1,

%T 1,1,3,1,1,1,3,1,1,1,2,1,2,1,1,1,3,2,1,1,1,7,1,1,1,3,1,1,1,1,1,1,2,1,

%U 1,1,1,2,2,1,2,1,1,1,4,1,1,2,1,1,1,1

%N a(n) = number of iterations of x -> 2 x - 5 to reach a nonprime, starting with prime(n+4).

%C See A377120 for a guide to related sequences.

%e prime(5) = 11 -> 17 -> 29 -> 53 -> 101 -> 197 -> 389 -> 773 -> 1541 = 23*67,

%e so a(1) = 8.

%t Table[p = Prime[n + 4]; c = 1; While[p = 2*p - 5; PrimeQ[p], c++]; c, {n, 200}]

%Y Cf. A377120, A377510, A377511, A377512, A377514.

%K nonn

%O 1,1

%A _Clark Kimberling_, Nov 05 2024