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!)
A068016 Lonely non-twin primes: non-twins sandwiched between two pairs of twins. 1

%I #16 Apr 22 2021 17:56:35

%S 23,37,67,233,277,631,1039,1283,1297,1307,1613,1693,1709,2099,2137,

%T 2333,2719,2797,3271,3533,3547,3571,3923,4027,4253,4523,4643,4793,

%U 5483,5507,5647,6563,7321,8831,8849,9007,9029,10061,10079,10289,10513,12049,13687

%N Lonely non-twin primes: non-twins sandwiched between two pairs of twins.

%H Zak Seidov, <a href="/A068016/b068016.txt">Table of n, a(n) for n = 1..1000</a>

%H Brian Hopkins, <a href="http://ecajournal.haifa.ac.il/Volume2021/ECA2021_S1H1.pdf">Euler's Enumerations</a>, Enumerative Combinatorics and Applications (2021) Vol. 1, No. 1, Article #S1H1.

%e 37 is in the sequence because it is adjacent to two pairs of twins (29,31 and 41,43). 47 is not because the primes adjacent to it are 43 and 53 and although 43 is a twin, 53 is not.

%t PrimeNext[n_]:=Module[{k},k=n+1;While[ !PrimeQ[k],k++ ];k]; PrimePrev[n_]:=Module[{k},k=n-1;While[ !PrimeQ[k],k-- ];k]; lst={};Do[p=Prime[n];If[ !PrimeQ[p-2]&&PrimeQ[PrimePrev[p]-2]&&!PrimeQ[p+2]&&PrimeQ[PrimeNext[p]+2],AppendTo[lst,p]],{n,7!}];lst (* _Vladimir Joseph Stephan Orlovsky_, Jul 22 2009 *)

%t m = 2000; #[[3]] & /@ Select[Partition[Prime[Range[7, m]], 5, 1], #[[2]] - #[[1]] == #[[5]] - #[[4]] == 2 &] (* _Zak Seidov_, Nov 25 2012 *)

%Y Cf. A001097, A069453.

%K nonn

%O 1,1

%A _Neil Fernandez_, Mar 22 2002

%E More terms from _Vladimir Joseph Stephan Orlovsky_, Dec 04 2009

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 24 20:08 EDT 2024. Contains 371963 sequences. (Running on oeis4.)