OFFSET
1,1
COMMENTS
The corresponding primes n!-1 are often called factorial primes.
REFERENCES
J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 166, p. 53, Ellipses, Paris 2008.
R. K. Guy, Unsolved Problems in Number Theory, Section A2.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See entry 719 at p. 160.
LINKS
A. Borning, Some results for k!+-1 and 2.3.5...p+-1, Math. Comp., 26:118 (1972), pp. 567-570.
J. P. Buhler et al., Primes of the form n!+-1 and 2.3.5....p+-1, Math. Comp., 38:158 (1982), pp. 639-643.
Chris K. Caldwell, Factorial Primes.
C. K. Caldwell and Y. Gallot, On the primality of n!+-1 and 2*3*5*...*p+-1, Math. Comp., 71:237 (2002), pp. 441-448.
P. Carmody, Factorial Prime Search Progress Pages.
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.
R. K. Guy and N. J. A. Sloane, Correspondence, 1985.
H. Dubner, Factorial and primorial primes, J. Rec. Math., 19 (No. 3, 1987), 197-203. (Annotated scanned copy)
Des MacHale and Joseph Manning, Maximal runs of strictly composite integers, The Mathematical Gazette, 99 (2015), pp 213-219. doi:10.1017/mag.2015.28.
R. Mestrovic, Euclid's theorem on the infinitude of primes: a historical survey of its proofs (300 BC--2012) and another new proof, arXiv preprint arXiv:1202.3670 [math.HO], 2012.
R. Ondrejka, The Top Ten: a Catalogue of Primal Configurations.
PrimeGrid, World Record Factorial Prime!!!.
PrimeGrid, Announcement of 94550, (2010). - Felix Fröhlich, Jul 11 2014
PrimeGrid, Announcement of 103040, (2010). - Felix Fröhlich, Jul 11 2014
PrimeGrid, Announcement of 147855, (2013). - Felix Fröhlich, Jul 11 2014
Maxie D. Schmidt, New Congruences and Finite Difference Equations for Generalized Factorial Functions, arXiv:1701.04741 [math.CO], 2017.
Eric Weisstein's World of Mathematics, Factorial.
Eric Weisstein's World of Mathematics, Factorial Prime.
Eric Weisstein's World of Mathematics, Integer Sequence Primes.
Robert G. Wilson v, Letter to N. J. A. Sloane, Jan. 1989.
EXAMPLE
From Gus Wiseman, Jul 04 2019: (Start)
The sequence of numbers n! - 1 together with their prime indices begins:
1: {}
5: {3}
23: {9}
119: {4,7}
719: {128}
5039: {675}
40319: {9,273}
362879: {5,5,430}
3628799: {10,11746}
39916799: {6,7,9,992}
479001599: {25306287}
6227020799: {270,256263}
87178291199: {3610490805}
1307674367999: {7,11,11,16,114905}
20922789887999: {436,318519035}
355687428095999: {8,21,10165484947}
6402373705727999: {17,20157,25293727}
121645100408831999: {119,175195,4567455}
2432902008176639999: {11715,659539127675}
(End)
MATHEMATICA
Select[Range[10^3], PrimeQ[ #!-1] &] (* Vladimir Joseph Stephan Orlovsky, May 01 2008 *)
PROG
(PARI) is(n)=ispseudoprime(n!-1) \\ Charles R Greathouse IV, Mar 21 2013
(Magma) [n: n in [0..500] | IsPrime(Factorial(n)-1)]; // Vincenzo Librandi, Sep 07 2017
(Python)
from sympy import factorial, isprime
A002982_list = [n for n in range(1, 10**2) if isprime(factorial(n)-1)] # Chai Wah Wu, Apr 04 2021
CROSSREFS
KEYWORD
hard,more,nonn,nice
AUTHOR
EXTENSIONS
21480 sent in by Ken Davis (ken.davis(AT)softwareag.com), Oct 29 2001
Updated Feb 26 2007 by Max Alekseyev, based on progress reported in the Carmody web site.
Inserted missing 21480 and 34790 (see Caldwell). Added 94550, discovered Oct 05 2010. Eric W. Weisstein, Oct 06 2010
103040 was discovered by James Winskill, Dec 14 2010. It has 471794 digits. Corrected by Jens Kruse Andersen, Mar 22 2011
a(26) = 147855 from Felix Fröhlich, Sep 02 2013
a(27) = 208003 from Sou Fukui, Jul 27 2016
STATUS
approved