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!)
A035093 Smallest k such that k*n! + 1 is prime. 9

%I #23 Sep 26 2020 03:13:50

%S 1,1,1,3,2,3,3,4,3,3,1,2,3,13,7,4,5,2,7,17,15,18,3,6,3,16,1,4,7,20,8,

%T 3,9,5,2,7,1,3,10,3,1,29,7,9,45,8,3,6,35,66,2,20,2,4,25,52,14,34,24,6,

%U 10,22,38,16,20,91,69,12,19,20,21,42,1,5,33,77,1,2,12,29,193,74,40,55,19

%N Smallest k such that k*n! + 1 is prime.

%C This is one possible generalization of "the least prime problem" for n*k+1 arithmetic progression when n is replaced by n!, a special difference.

%H <a href="/index/Pri#primes_AP">Index entries for sequences related to primes in arithmetic progressions</a>

%e a(7)=3 because in progression of 5040*k+1 the terms 5041 and 10081 are not prime and so 15121 is the first prime.

%t Table[k = 1; While[! PrimeQ[1 + k*n!], k++]; k, {n, 85}] (* _T. D. Noe_, Nov 04 2013 *)

%o (PARI) a(n) = my(k=1); while(!isprime(k*n!+1), k++); k; \\ _Michel Marcus_, Sep 26 2020

%Y Analogous case is A034693. Special case for k=1 is A002981.

%K nonn

%O 1,4

%A _Labos Elemer_

%E a(80) corrected by _Alex Ratushnyak_, Nov 03 2013

%E Simpler title by _Sean A. Irvine_, Sep 25 2020

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 18 22:18 EDT 2024. Contains 371782 sequences. (Running on oeis4.)