The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A243158 Smallest k>=0 such that prime(n)*prime(n+k) + 2 is prime. 3

%I #15 May 08 2021 11:51:16

%S 0,1,1,3,1,5,1,3,4,4,3,5,2,6,13,5,6,1,9,28,8,2,10,8,5,8,3,3,31,2,2,9,

%T 6,1,3,6,2,5,4,1,10,3,7,3,6,7,4,4,1,14,1,1,4,4,18,1,8,1,3,10,3,1,6,1,

%U 7,2,26,19,6,2,8,30,23,6,19,5,1,1,12,1,7

%N Smallest k>=0 such that prime(n)*prime(n+k) + 2 is prime.

%C A dual sequence to A243154. The sequence contains a unique zero term. Indeed, every prime p>3 has the form 3*k +/- 1. So, p^2 + 2 == 0 (mod 3).

%t skp[n_]:=Module[{c=Prime[n],k=0},While[!PrimeQ[c*Prime[n+k]+2],k++];k]; Array[ skp,90,2] (* _Harvey P. Dale_, May 08 2021 *)

%o (PARI) vector(200, n, k=0; while(!isprime(prime(n+1)*prime(n+1+k)+2), k++); k) \\ _Colin Barker_, May 31 2014

%Y Cf. A243154.

%K nonn

%O 2,4

%A _Vladimir Shevelev_, May 31 2014

%E More terms from _Colin Barker_, May 31 2014

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 June 5 04:27 EDT 2024. Contains 373102 sequences. (Running on oeis4.)