login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A053708 Nearest prime to n! (but not equal to n!). 0
2, 3, 5, 23, 113, 719, 5039, 40343, 362867, 3628789, 39916801, 479001599, 6227020777, 87178291199, 1307674368043, 20922789888023, 355687428096031, 6402373705728037, 121645100408832089, 2432902008176640029 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
If n! is the average of its closest prime neighbors then the smaller prime is to be chosen (as in A051701).
LINKS
EXAMPLE
For 8!=40320 the closest upper and lower primes are 40289 and 40343 with d=31 and d=23, so 40343 is closer to 8! than the lower neighbor.
MATHEMATICA
f[n_]:=Module[{nf=n!, s, l}, s=NextPrime[nf, -1]; l=NextPrime[nf]; If[nf-s>l-nf, l, s]]
Table[f[i], {i, 25}] (* Harvey P. Dale, Dec 08 2010 *)
CROSSREFS
Sequence in context: A042363 A208220 A138655 * A137070 A084730 A117696
KEYWORD
nonn
AUTHOR
Labos Elemer, Feb 10 2000
EXTENSIONS
Corrected by Rick L. Shepherd, Jan 11 2006
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 13 15:24 EDT 2024. Contains 371644 sequences. (Running on oeis4.)