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”).

A037151
Smallest prime > n!.
17
2, 3, 7, 29, 127, 727, 5051, 40343, 362897, 3628811, 39916801, 479001629, 6227020867, 87178291219, 1307674368043, 20922789888023, 355687428096031, 6402373705728037, 121645100408832089, 2432902008176640029, 51090942171709440031, 1124000727777607680031
OFFSET
1,1
LINKS
Antonín Čejchan, Michal Křížek, and Lawrence Somer, On Remarkable Properties of Primes Near Factorials and Primorials, Journal of Integer Sequences, Vol. 25 (2022), Article 22.1.4.
FORMULA
a(n) = A151800(A000142(n)) = A000142(n) + A033932(n).
MATHEMATICA
PrimeNext[n_]:=Module[{k}, k=n+1; While[ !PrimeQ[k], k++ ]; k]; Table[PrimeNext[n! ], {n, 40}] (* Vladimir Joseph Stephan Orlovsky, May 30 2010 *)
Table[NextPrime[n!], {n, 25}] (* Harvey P. Dale, Dec 12 2010 *)
PROG
(Python)
from sympy import factorial, nextprime
def a(n): return nextprime(factorial(n))
print([a(n) for n in range(1, 23)]) # Michael S. Branicky, May 22 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
Extended by Ray Chandler, Mar 07 2010
STATUS
approved