A350314 The catch-up points of the Redstone permutation A350313.
2, 5, 11, 17, 23, 29, 37, 41, 47, 53, 59, 67, 71, 77, 83, 89, 97, 101, 107, 113, 119, 127, 131, 137, 143, 149, 157, 161, 167, 173, 179, 187, 191, 197, 203, 209, 221, 227, 233, 239, 247, 251, 257, 263, 269, 277, 281, 287, 293, 299, 307, 311, 317, 323, 329, 337
Offset: 1
Keywords
Programs
-
Mathematica
s = {2, 1}; c[] = 0; Array[Set[c[s[[#]]], #] &, Length[s]]; j = Last[s]; u = 3; {2}~Join~Reap[Monitor[Do[If[j == u, While[c[u] > 0, u++]]; k = u; While[Nand[c[k] == 0, CoprimeQ[i, k], ! Divisible[i - 1, k]], k++]; If[k == u, Sow[i]]; Set[c[k], i]; j = k, {i, Length[s] + 1, 337}], i]][[-1, -1]] (* _Michael De Vlieger, Dec 24 2021 *)
Comments