A054800
First term of balanced prime quartets: p(m+1)-p(m) = p(m+2)-p(m+1) = p(m+3)-p(m+2).
Original entry on oeis.org
251, 1741, 3301, 5101, 5381, 6311, 6361, 12641, 13451, 14741, 15791, 15901, 17471, 18211, 19471, 23321, 26171, 30091, 30631, 53611, 56081, 62201, 63691, 71341, 74453, 75521, 76543, 77551, 78791, 80911, 82781, 83431, 84431, 89101, 89381
Offset: 1
a(1) = 251 = prime(54) = A000040(54) and prime(55) - prime(54) = prime(56)-prime(55) = 6. - _Zak Seidov_, Apr 23 2011
Cf.
A006560 (first prime to start a CPAP-n).
-
Select[Partition[Prime[Range[9000]],4,1],Length[Union[Differences[#]]] == 1&][[All,1]] (* Harvey P. Dale, Aug 08 2017 *)
-
p=2;q=3;r=5;forprime(s=7,1e4, t=s-r; if(t==r-q&&t==q-p, print1(p", ")); p=q;q=r;r=s) \\ Charles R Greathouse IV, Feb 14 2013
A033451
Initial prime in set of 4 consecutive primes with common difference 6.
Original entry on oeis.org
251, 1741, 3301, 5101, 5381, 6311, 6361, 12641, 13451, 14741, 15791, 15901, 17471, 18211, 19471, 23321, 26171, 30091, 30631, 53611, 56081, 62201, 63691, 71341, 75521, 77551, 78791, 80911, 82781, 83431, 84431, 89101, 89381, 91291, 94421
Offset: 1
251, 257, 263, 269 are consecutive primes: 257 = 251 + 6, 263 = 251 + 12, 269 = 251 + 18.
- T. D. Noe, Table of n, a(n) for n = 1..1000
- Jens Kruse Andersen, The Largest Known CPAP's
- Ben Green and Terence Tao, The primes contain arbitrarily long arithmetic progressions, arXiv:math/0404188 [math.NT], 2004-2007.
- B. Green and T. Tao, The primes contain arbitrarily long arithmetic progressions, Annals of Math. 167(2008), 481-547.
- OEIS wiki, Consecutive primes in arithmetic progression: CPAP with given gap, updated Jan. 2020
- Index entries for sequences related to primes in arithmetic progressions
-
N:=10^5: # to get all terms <= N.
Primes:=select(isprime,[seq(i,i=3..N+18,2)]):
Primes[select(t->[Primes[t+1]-Primes[t], Primes[t+2]-Primes[t+1],
Primes[t+3]-Primes[t+2]]=[6,6,6], [$1..nops(Primes)-3])]; # Muniru A Asiru, Aug 04 2017
-
A033451 = Reap[ For[p = 2, p < 100000, p = NextPrime[p], p2 = NextPrime[p]; If[p2 - p == 6, p3 = NextPrime[p2]; If[p3 - p2 == 6, p4 = NextPrime[p3]; If[p4 - p3 == 6, Sow[p]]]]]][[2, 1]] (* Jean-François Alcover, Jun 28 2012 *)
Transpose[Select[Partition[Prime[Range[16000]],4,1],Union[ Differences[ #]] == {6}&]][[1]] (* Harvey P. Dale, Jun 17 2014 *)
-
p=2;q=3;r=5;forprime(s=7,1e4,if(s-p==18 && s-q==12 && s-r==6, print1(p", ")); p=q;q=r;r=s) \\ Charles R Greathouse IV, Feb 14 2013
A033447
Initial prime in set of 4 consecutive primes with common difference 12.
Original entry on oeis.org
111497, 258527, 286777, 318407, 332767, 341827, 358447, 439787, 473887, 480737, 495377, 634187, 647417, 658367, 663857, 703837, 732497, 816317, 819787, 827767, 843067, 862307, 937777, 970457, 970537, 1001267, 1012147, 1032727, 1052707, 1055827, 1104307, 1117877, 1164817, 1165837
Offset: 1
Also subsequence of
A054800: start of a CPAP-4, any common difference.
-
A033447 = Reap[For[p = 2, p < 1100000, p = NextPrime[p], p2 = NextPrime[p]; If[p2 - p == 12, p3 = NextPrime[p2]; If[p3 - p2 == 12, p4 = NextPrime[p3]; If[p4 - p3 == 12, Sow[p]]]]]][[2, 1]] (* Jean-François Alcover, Jun 28 2012 *)
Transpose[Select[Partition[Prime[Range[160000]],4,1],Union[ Differences[#]] =={12}&]][[1]] (* Harvey P. Dale, Jun 17 2014 *)
-
A033447(n, p=2, show_all=1, g=12,c,o)={forprime(q=p+1,, if(p+g!=p=q, next, q!=o+2*g, c=2, c++>3, show_all&& print1(o-g", "); n--||break); o=q-g); o-g} \\ Can be used as next(p)=A033447(1, p+1) to get the next term, e.g.:
p=0; A033447_vec=vector(30,i,p=A033447(1,p+1)) \\ M. F. Hasler, Oct 26 2018
A052243
Initial prime in set of (at least) 4 consecutive primes in arithmetic progression with difference 30.
Original entry on oeis.org
642427, 1058861, 3431903, 4176587, 4560121, 4721047, 5072269, 5145403, 5669099, 5893141, 6248969, 6285047, 6503179, 6682969, 8545357, 8776121, 8778739, 9490571, 9836227, 9843019, 9843049, 10023787, 11697979, 12057919, 12340313, 12687119, 12794641, 12845849
Offset: 1
642427, 642457, 642487, 642517 are consecutive primes, so 642427 is in the sequence.
Subsequence of
A052195 and of
A054800 (start of CPAP-4 with any common difference).
-
f:=func; a:=[]; for p in PrimesInInterval(2,13000000) do if (f(p)-p eq 30) and (f(f(p))-p eq 60) and (f(f(f(p)))-p eq 90) then Append(~a,p); end if; end for; a; // Marius A. Burtea, Jan 04 2020
-
p := 2 : q := 3 : r := 5 : s := 7 : for i from 1 do if q-p = 30 and r-q=30 and s-r=30 then printf("%d,\n",p) ; fi ; p := q ; q := r ; r := s ; s := nextprime(r) ; od: # R. J. Mathar, Apr 12 2008
-
p=2; q=3; r=5; s=7; A052243 = Reap[For[i=1, i<1000000, i++, If[ q-p == 30 && r-q == 30 && s-r == 30 , Print[p]; Sow[p]]; p=q; q=r; r=s; s=NextPrime[r]]][[2, 1]] (* Jean-François Alcover, Jun 28 2012, after R. J. Mathar *)
Transpose[Select[Partition[Prime[Range[1100000]],4,1],Union[ Differences[#]] =={30}&]][[1]] (* Harvey P. Dale, Jun 17 2014 *)
-
A052243(n,p=2,print_all=0,g=30,c,o)={forprime(q=p+1,,if(p+g!=p=q, next, q!=o+2*g, c=2, c++>3, print_all&& print1(o-g","); n--||break); o=q-g);o-g} \\ optional 2nd arg specifies starting point, allows to define:
next_A052243(p)=A052243(1,p+1) \\ replacing older code from 2008. - M. F. Hasler, Oct 26 2018
A033448
Initial prime in set of 4 consecutive primes in arithmetic progression with common difference 18.
Original entry on oeis.org
74453, 76543, 132893, 182243, 202823, 297403, 358793, 485923, 655453, 735883, 759113, 780613, 797833, 849143, 1260383, 1306033, 1442173, 1531093, 1534153, 1586953, 1691033, 1717063, 1877243, 1945763, 1973633, 2035513, 2067083, 2216803, 2266993, 2542513, 2556803, 2565203, 2805773
Offset: 1
{74453, 74471, 74489, 74507} is the first such set of 4 consecutive primes with common difference 18, so a(1) = 74453.
-
A033448 = Reap[For[p = 2, p < 2100000, p = NextPrime[p], p2 = NextPrime[p]; If[p2 - p == 18, p3 = NextPrime[p2]; If[p3 - p2 == 18, p4 = NextPrime[p3]; If[p4 - p3 == 18, Sow[p]]]]]][[2, 1]] (* Jean-François Alcover, Jun 28 2012 *)
Transpose[Select[Partition[Prime[Range[160000]],4,1],Union[ Differences[ #]] == {18}&]][[1]] (* Harvey P. Dale, Jun 17 2014 *)
-
A033448(n,show_all=1,g=18,p=2,o,c)={forprime(q=p+1,,if(p+g!=p=q,next, q!=o+2*g, c=3, c++>4, print1(o-g","); n--||break); o=q-g);o-g} \\ Can be used as nxt(p)=A033448(1,,,p+1), e.g.: {p=0;vector(20,i,p=nxt(p))} or {p=0;for(i=1,1e4,write("b.txt",i" "nxt(p)))}. - M. F. Hasler, Oct 26 2018
A059044
Initial primes of sets of 5 consecutive primes in arithmetic progression.
Original entry on oeis.org
9843019, 37772429, 53868649, 71427757, 78364549, 79080577, 98150021, 99591433, 104436889, 106457509, 111267419, 121174811, 121174841, 168236119, 199450099, 203908891, 207068803, 216618187, 230952859, 234058871, 235524781, 253412317, 263651161, 268843033, 294485363, 296239787
Offset: 1
Harvey Dubner (harvey(AT)dubner.com), Dec 18 2000
- David Wells, The Penguin Dictionary of Curious and Interesting Numbers (Rev. ed. 1997), p. 181.
Cf.
A054800: start of 4 consecutive primes in arithmetic progression (CPAP-4).
Cf.
A033451,
A033447,
A033448,
A052242,
A052243,
A058252,
A058323,
A067388: start of CPAP-4 with common difference 6, 12, 18, ..., 48.
Cf.
A052239: start of first CPAP-4 with common difference 6n.
Cf.
A058362: start of 6 consecutive primes in arithmetic progression.
Cf.
A006560: first prime to start a CPAP-n.
-
Select[Partition[Prime[Range[14000000]],5,1],Length[Union[ Differences[ #]]]==1&] (* Harvey P. Dale, Jun 22 2013 *)
-
A059044(n,p=2,c,g,P)={forprime(q=p+1,, if(p+g!=p+=g=q-p, next, q!=P+2*g, c=3, c++>4, print1(P-2*g,",");n--||break);P=q-g);P-2*g} \\ This does not impose the gap to be 30, but it happens to be the case for the first values. - M. F. Hasler, Oct 26 2018
Edited (definition clarified, cross-references corrected and extended) by
M. F. Hasler, Oct 26 2018
A052239
Smallest prime p in set of 4 consecutive primes in arithmetic progression with common difference 6n.
Original entry on oeis.org
251, 111497, 74453, 1397609, 642427, 5321191, 23921257, 55410683, 400948369, 253444777, 1140813701, 491525857, 998051413, 2060959049, 4480114337, 55140921491, 38415872947, 315392068463, 15162919459, 60600021611, 278300877401, 477836574947, 1486135570643
Offset: 1
a(5) = 642427, 642457, 642487, 642517 are the smallest consecutive primes with 3 consecutive gaps of 30, cf. A052243.
From _M. F. Hasler_, Nov 06 2018: (Start)
Other terms are also initial terms of corresponding sequences:
a(1) = 251 = A033451(1) = A054800(1), start of first CPAP-4 with common gap of 6,
a(2) = 111497 = A033447(1), start of first CPAP-4 with common gap of 12,
a(3) = 74453 = A033448(1) = A054800(25), first CPAP-4 with common gap of 18,
a(4) = 1397609 = A052242(1), start of first CPAP-4 with common gap of 24,
a(5) = 642427 = A052243(1) = A052195(16), first CPAP-4 with common gap of 30,
a(6) = 5321191 = A058252(1) = A161534(26), first CPAP-4 with common gap 36 = 6^2,
a(7) = 23921257 = A058323(1), start of first CPAP-4 with common gap of 42,
a(8) = 55410683 = A067388(1), start of first CPAP-4 with common gap of 48,
a(9) = 400948369 = A259224(1), start of first CPAP-4 with common gap of 54,
a(10) = 253444777 = A210683(1) = A089234(417), CPAP-4 with common gap of 60,
a(11) = 1140813701 = A287547(1), start of first CPAP-4 with common gap of 66,
a(12) = 491525857 = A287550(1), start of first CPAP-4 with common gap of 72,
a(13) = 998051413 = A287171(1), start of first CPAP-4 with common gap of 78,
a(14) = 2060959049 = A287593(1), start of first CPAP-4 with common gap of 84,
a(15) = 4480114337 = A286817(1) = A204852(444), common distance 90. (End)
Range is a subset of
A054800: start of 4 consecutive primes in arithmetic progression (CPAP-4).
Cf.
A054701: gaps are possibly distinct multiples of 6n (not CPAP's).
-
Transpose[Flatten[Table[Select[Partition[Prime[Range[2000000]],4,1], Union[ Differences[ #]] =={6n}&,1],{n,7}],1]][[1]] (* Harvey P. Dale, Aug 12 2012 *)
-
a(n, p=[2, 0, 0], d=6*[n, n, n])={while(p+d!=p=[nextprime(p[1]+1), p[1], p[2]], ); p[3]-d[3]} \\ after M. F. Hasler in A052243; Graziano Aglietti (mg5055(AT)mclink.it), Aug 22 2010, Corrected by M. F. Hasler, Nov 06 2018
-
A052239(n, p=2, c, o)={n*=6; forprime(q=p+1, , if(p+n!=p=q, next, q!=o+2*n, c=2, c++>3, break); o=q-n); o-n} \\ M. F. Hasler, Nov 06 2018
a(7) corrected and more terms added by Graziano Aglietti (mg5055(AT)mclink.it), Aug 22 2010
A210683
Primes p such that p, p+60, p+120, p+180 are consecutive primes.
Original entry on oeis.org
253444777, 271386581, 286000489, 415893013, 475992773, 523294549, 620164949, 794689481, 838188877, 840725323, 846389227, 884106599, 884951807, 908725507, 941796223, 952288331, 971614151, 1002290693, 1003166771, 1006976797, 1053792359, 1097338313, 1163141201
Offset: 1
Cf.
A054800: union of all sequences of this type (start of CPAP-4).
-
A210683(n, p=2, v=1, g=60, c, o)={forprime(q=p+1, , if(p+g!=p=q, next, q!=o+2*g, c=2, c++>3, v&& print1(o-g", "); n--||break); o=q-g); o-g} \\ Can be used as next(p)=A210683(1, p) to get the next term, e.g.:
p=0; A210683_vec=vector(10,i,p=A210683(1,p)) \\ Will take a long time! - M. F. Hasler, Oct 26 2018
A259224
Initial primes in sets of 4 consecutive primes with common gap 54.
Original entry on oeis.org
400948369, 473838319, 583946599, 678953059, 816604199, 972598819, 1136526949, 1466715139, 1475790529, 1499794999, 1502149559, 1610895679, 1643313869, 1673057219, 1686181579, 1845792019, 1867046639, 1907478889, 1992202439, 2011077869, 2030490479, 2207714969
Offset: 1
Subsequence of
A054800: start of a CPAP-4 with arbitrary common difference.
-
A259224(n, p=2, v=1, g=54, c, o)={forprime(q=p+1, , if(p+g!=p=q, next, q!=o+2*g, c=2, c++>3, v&& print1(o-g", "); n--||break); o=q-g); o-g} \\ Can be used as next(p)=A259224(1,p+1) to get the next term, e.g.:
p=0; A259224_vec=vector(10,i,p=A259224(1,p+1)) \\ Will be slow! - M. F. Hasler, Oct 26 2018
A058362
Initial primes of sets of 6 consecutive primes in arithmetic progression.
Original entry on oeis.org
121174811, 1128318991, 2201579179, 2715239543, 2840465567, 3510848161, 3688067693, 3893783651, 5089850089, 5825680093, 6649068043, 6778294049, 7064865859, 7912975891, 8099786711, 9010802341, 9327115723, 9491161423, 9544001791, 10101930253, 10523406343, 13193702321
Offset: 1
Harvey Dubner (harvey(AT)dubner.com), Dec 18 2000
Cf.
A006560: first prime to start a CPAP-n.
Cf.
A033451,
A033447,
A033448,
A052242,
A052243,
A058252,
A058323,
A067388: start of CPAP-4 with common difference 6, 12, 18, ..., 48.
Cf.
A054800: start of 4 consecutive primes in arithmetic progression (CPAP-4).
Cf.
A052239: starting prime of first CPAP-4 with common difference 6n.
Cf.
A059044: starting primes of CPAP-5.
Cf.
A210727: starting primes of CPAP-5 with common difference 60.
-
p=c=g=P=0;forprime(q=1,, p+g==(p+=g=q-p)|| next; q==P+2*g&& c++|| c=3; c>5&& print1(P-3*g,","); P=q-g) \\ M. F. Hasler, Oct 26 2018
Comment split off from Name (to clarify definition) by
M. F. Hasler, Oct 27 2018
Showing 1-10 of 13 results.
Comments