cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-8 of 8 results.

A052168 Primes at which difference pattern X4242Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

1867, 3457, 5647, 15727, 79687, 88807, 101107, 257857, 266677, 276037, 284737, 340927, 354247, 375247, 402757, 419047, 427237, 463447, 470077, 626617, 666427, 736357, 823717, 855727, 959467, 978067, 1022377, 1043587, 1068247, 1118857
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Comments

All terms are == 7 (mod 30). - Zak Seidov, May 07 2017

Examples

			1867 is here because the successor primes (1867),1871,1873,1877,1879 give 4242 difference pattern. The primes around this island are 1861 and 1889 in distance 6 and 10 resp. Thus the d-pattern "around 1867" is {6,4,2,4,2,10}. [corrected by _Zak Seidov_, May 07 2017]
		

Crossrefs

Programs

  • Mathematica
    m=1867; Reap[Do[While[ PrimeQ[m] m = m + 30]; If[
    m > NextPrime[m, -1] + 5 &&  AllTrue[m + {4, 6, 10, 12}, PrimeQ] && NextPrime[m + 12] > m + 17, Sow[m]]; m = m + 30, {10^5}]][[2, 1]] (* Zak Seidov, May 07 2017 *)

A052162 Primes at which difference pattern X4Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

79, 127, 163, 379, 397, 439, 487, 499, 673, 739, 757, 769, 907, 937, 967, 1009, 1213, 1549, 1567, 1579, 1597, 2203, 2293, 2347, 2389, 2437, 2473, 2539, 2617, 2749, 2833, 2857, 2953, 3019, 3037, 3079, 3187, 3217, 3319, 3343, 3613, 3697, 3793, 3877, 3907
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Examples

			127 is in the sequence because 127 + 4 = 131 is prime, but the difference pattern around 127 is {[113] 14 [127] 4 [131] 6 [137]}.
		

Crossrefs

Programs

  • Mathematica
    s = Differences@ Prime@ Range[600]; Prime@ Select[Position[s, 4][[All, 1]], And[s[[# - 1]] >= 6, s[[# + 1]] >= 6] &] (* Michael De Vlieger, Aug 17 2023 *)

A052165 Primes at which the difference pattern X,2,4,2,Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

191, 821, 2081, 3251, 9431, 13001, 15641, 18041, 18911, 25301, 31721, 34841, 51341, 62981, 67211, 69491, 72221, 77261, 81041, 82721, 97841, 99131, 109841, 116531, 119291, 122201, 135461, 157271, 171161, 187631, 194861, 201491, 217361
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Comments

All terms == 11 (mod 30). - Robert Israel, Nov 30 2015

Examples

			191 is here because 191 + 2 = 193, 191 + 4 + 2 = 197, 191 + 2 + 4 + 2 = 199 are primes; the prime preceding 191 is 181; the prime following 199 is 211; and the corresponding differences are 10 and 12. Thus the d-pattern "around 191" is {10,2,4,2,12}.
		

Crossrefs

Programs

  • Maple
    Primes:= select(isprime,[2,seq(i,i=3..10^6,2)]):
    Gaps:= Primes[2..-1]-Primes[1..-2]:
    Primes[select(t -> Gaps[t] = 2 and Gaps[t+1] = 4 and Gaps[t+2] = 2 and Gaps[t-1] >= 6 and Gaps[t+3]>=6, [$2..nops(Gaps)-3])]; # Robert Israel, Nov 30 2015
  • Mathematica
    With[{x = 6, y = 6, s = Partition[#, 6, 1] &@ Prime@ Range[3*10^4]}, Select[s, And[First@ # >= x, Last@ # >= y, Most@ Rest@ # == {2, 4, 2}] &@ Differences@ # &]][[All, 2]] (* Michael De Vlieger, Oct 26 2017 *)

A047078 Primes at which difference pattern X2Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

29, 59, 137, 149, 179, 239, 269, 419, 431, 521, 569, 599, 659, 809, 1019, 1031, 1049, 1061, 1151, 1229, 1289, 1319, 1619, 1721, 1931, 1949, 2027, 2111, 2129, 2309, 2339, 2549, 2591, 2729, 2789, 2969, 2999, 3119, 3299, 3329, 3359, 3371, 3389, 3539, 3557
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Examples

			59 is here because 59 + 2 = 61 is prime, but the difference pattern around 59 is {[53] 6 [59] 2 [61] 6 [67]}.
		

Crossrefs

Programs

  • Mathematica
    Select[Prime@ Range[2, 500], Times @@ Boole@ {First@ # >= 6, #[[2]] == 2, Last@ # >= 6} == 1 &@ Differences@ Prime[# + Range[-1, 2]] &@ PrimePi@ # &] (* Michael De Vlieger, Jul 04 2016 *)

A052163 Primes at which the difference pattern X24Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

347, 641, 1277, 1607, 2237, 2267, 2657, 3527, 3671, 3917, 4001, 4127, 4637, 4931, 4967, 5477, 5501, 6197, 8087, 8231, 8537, 8861, 9461, 10331, 10427, 11171, 11777, 12107, 12917, 13757, 13901, 14081, 14321, 14627, 17027, 18251, 19991, 20477
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Examples

			641 is in the sequence because 641 + 2 = 643, 641 + 2 + 4 = 647 is prime, the prime prior to 641 is 631, the prime after 647 is 653, and the corresponding differences are 10 or 6. The d-pattern is {10,2,4,6}.
		

Crossrefs

A052166 Primes at which the difference pattern X424Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

37, 223, 307, 457, 853, 877, 1087, 1297, 1423, 1993, 2683, 4513, 4783, 5227, 6823, 7873, 8287, 10453, 13687, 13873, 16183, 17383, 20743, 21313, 23053, 23557, 23623, 24103, 27733, 29017, 31387, 33343, 33613, 35527, 36007, 37987, 40423, 42013
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Examples

			37 is here because 37 + 4 = 41, 37 + 4 + 2 = 43, 37 + 4 + 2 + 4 = 47 are consecutive primes and the prime preceding 37 is 31, the prime following 47 is 53, and the corresponding differences are 6 and 6. Thus the d-pattern "around 37" is {6,4,2,4}.
		

Crossrefs

Programs

  • Mathematica
    okQ[n_List]:=Module[{d=Differences[n]},Take[d,{2,4}]=={4,2,4} && First[d]>5&&Last[d]>5]; Transpose[Select[ Partition[ Prime[ Range[ 4400]], 6, 1],okQ]][[2]] (* Harvey P. Dale, Jul 17 2011 *)

A052167 Primes at which difference pattern X2424Y (X and Y >= 6) occurs in A001223.

Original entry on oeis.org

1481, 21011, 22271, 55331, 144161, 165701, 166841, 195731, 201821, 225341, 247601, 268811, 326141, 347981, 361211, 397751, 465161, 518801, 536441, 633461, 633791, 661091, 768191, 795791, 829721, 857951, 876011, 958541, 1008851
Offset: 1

Views

Author

Labos Elemer, Jan 26 2000

Keywords

Examples

			21011 is here because 21011+{2,2+4,2+4+2,2+4+2+4}=21011+{1,6,8,12}= {21013,21013,21017,21019,21023} are consecutive primes but the primes in the immediate neighborhood (21001 and 21031) are in distance 10 and 8. Thus the d-pattern "around 21011" is {10,2,4,2,4,12}.
		

Crossrefs

Programs

  • Mathematica
    patQ[n_]:=Module[{d=Differences[n]},First[d]>5&&Last[d]>5&&Most[ Rest[d]] == {2,4,2,4}]; Transpose[Select[Partition[Prime[ Range[ 80000]],7,1],patQ]] [[2]] (* Harvey P. Dale, Dec 11 2013 *)

A052187 a(n) is the smallest prime p such that p, p+d, and p+2d are consecutive primes where d = 2 for n = 1 and d = 6*(n-1) for n > 1.

Original entry on oeis.org

3, 47, 199, 20183, 16763, 69593, 255767, 247099, 3565931, 6314393, 4911251, 12012677, 23346737, 43607351, 34346203, 36598517, 51041957, 460475467, 652576321, 742585183, 530324329, 807620651, 2988119207, 12447231761, 383204539, 4470607951, 5007182707
Offset: 1

Views

Author

Labos Elemer, Jan 28 2000

Keywords

Comments

The first term 3 is anomalous since for all others d is divisible by 6. These are minimal terms if in A047948 d=6 is replaced by possible differences: (2), 6, 12, 18, ..., 54, 60.
a(54) > 5*10^13, while a(55) = 46186474937633. - Giovanni Resta, Apr 08 2013

Examples

			a(2)=47 and it is the lower border of a dd pattern: 47[6 ]53[6 ]59. a(10)=6314393 and a(10)+54=6314447, a(10)+108=6314501 are consecutive primes and 6314393 is the smallest prime prior to a (54,54) difference pattern of A001223.
		

Crossrefs

Programs

  • Mathematica
    a = Table[0, {100}]; NextPrime[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; p = q = r = 0; Do[r = NextPrime[r]; If[r + p == 2q && r - q < 201 && a[[(r - q)/2]] == 0, a[[(r - q)/2]] = p]; p = q; q = r, {n, 1, 10^6}]; a (* Typos fixed by Zak Seidov, May 01 2020 *)
  • PARI
    list(n)=ve=vector(n);ppp=2;pp=3;forprime(p=5,,d=p-pp;if(pp-ppp==d,i=d\6+1;if(i<=n&&ve[i]==0,ve[i]=ppp;print1(".");vecprod(ve)>0&&return(ve)));ppp=pp;pp=p) \\ Jeppe Stig Nielsen, Apr 17 2022

Formula

The least prime(k) such that prime(k+1) = (prime(k) + prime(k+2))/2 and prime(k+1) - prime(k) = d is either 2 or divisible by 6.
a(1) = A054342(1) - 2. For n>1, a(n) = A054342(n) - 6*(n-1). - Jeppe Stig Nielsen, Apr 16 2022

Extensions

More terms from Labos Elemer, Jan 04 2002
More terms from Robert G. Wilson v, Jan 06 2002
Definition clarified by Harvey P. Dale, Aug 29 2012
a(23)-a(27) from Donovan Johnson, Aug 30 2012
Name edited by Jon E. Schoenfield, Nov 30 2023
Showing 1-8 of 8 results.