OFFSET
1,2
COMMENTS
Erdős and Selfridge (1982) proved that if f(n) = primepi(a(n)) (or, equivalently, a(n) = prime(f(n))), then |f(n+1) - f(n)| <= 1, and that for infinitely many values of n, f(n+1) = f(n) - 1.
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
Paul Erdős, Miscellaneous problems in number theory, Proceedings of the Eleventh Manitoba Conference on Numerical Mathematics and Computing (Winnipeg, Man., 1981), Congr. Numer., Vol. 34 (1982), pp. 25-45.
Paul Erdős and John L. Selfridge, Problem 6339, Advanced problems, The American Mathematical Monthly, Vol. 88, No. 4 (1981), p. 294; Factorizationf n!, solution to problem 6339, solved by the proposers, ibid., Vol. 89, No. 10 (1982), pp. 790-794.
FORMULA
MATHEMATICA
f[1] = 1; f[n_] := Module[{fct = FactorInteger[n], prods, ind}, prods = Rest @ FoldList[Times, 1, Power @@@ fct]; ind = FirstPosition[prods^2, _?(# > n &)][[1]]; fct[[ind, 1]]]; a[n_] := f[n!]; Array[a, 100]
CROSSREFS
KEYWORD
nonn
AUTHOR
Amiram Eldar, Jul 07 2021
STATUS
approved