OFFSET
1,2
COMMENTS
Conjectured to be a permutation of the natural numbers.
MATHEMATICA
nn = 2^20; c[_] = 0; q[_] = 1;
Array[Set[{a[#], c[#]}, {#, #}] &, 2];
Set[{i, j}, {a[1], a[2]}]; u = 3;
Monitor[Do[
(k = q[#]; While[c[k #] > 0, k++]; k *= #;
While[c[# q[#]] > 0, q[#]++]) &[(p = 2;
While[Divisible[i j, p], p = NextPrime[p]]; p)]; Sow[p];
Set[{a[n], c[k], i, j}, {k, n, j, k}];
If[k == u, While[c[u] > 0, u++]], {n, 3, nn}], n];
TakeWhile[Array[c, 120], # > 0 &] (* Michael De Vlieger, Mar 18 2023 *)
CROSSREFS
KEYWORD
nonn,more
AUTHOR
N. J. A. Sloane, Mar 18 2023
STATUS
approved