A002822 Numbers m such that 6m-1, 6m+1 are twin primes.
1, 2, 3, 5, 7, 10, 12, 17, 18, 23, 25, 30, 32, 33, 38, 40, 45, 47, 52, 58, 70, 72, 77, 87, 95, 100, 103, 107, 110, 135, 137, 138, 143, 147, 170, 172, 175, 177, 182, 192, 205, 213, 215, 217, 220, 238, 242, 247, 248, 268, 270, 278, 283, 287, 298, 312, 313, 322, 325
Offset: 1
References
- W. J. LeVeque, Topics in Number Theory. Addison-Wesley, Reading, MA, 2 vols., 1956, Vol. 1, p. 69.
- W. SierpiĆski, A Selection of Problems in the Theory of Numbers. Macmillan, NY, 1964, p. 120.
- N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
Links
- T. D. Noe, Table of n, a(n) for n = 1..10000
- F. Balestrieri, An Equivalent Problem To The Twin Prime Conjecture, arXiv:1106.6050v1 [math.GM], 2011.
- A. Dinculescu, On Some Infinite Series Related to the Twin Primes, The Open Mathematics Journal, 5 (2012), 8-14.
- A. Dinculescu, The Twin Primes Seen from a Different Perspective, The British Journal of Mathematics & Computer Science, 3 (2013), Issue 4, 691-698.
- A. Dinculescu, On the Numbers that Determine the Distribution of Twin Primes, Surveys in Mathematics and its Applications, 13 (2018), 171-181.
- S. W. Golomb, Problem E969, Solution, Amer. Math. Monthly, 58 (1951), 338; 59 (1952), 44.
- S. W. Golomb, Letter to N. J. A. Sloane, Mar 26 1984
- Matthew A. Myers, Comments on A002822, Letter to N. J. A. Sloane, Dec 04 2018
Crossrefs
Programs
-
Haskell
a002822 n = a002822_list !! (n-1) a002822_list = f a000040_list where f (q:ps'@(p:ps)) | p > q + 2 || r > 0 = f ps' | otherwise = y : f ps where (y,r) = divMod (q + 1) 6 -- Reinhard Zumkeller, Jul 13 2014
-
Magma
[n: n in [1..200] | IsPrime(6*n+1) and IsPrime(6*n-1)] // Vincenzo Librandi, Nov 21 2010
-
Maple
select(n -> isprime(6*n-1) and isprime(6*n+1), [$1..1000]); # Robert Israel, Jan 11 2015
-
Mathematica
Select[ Range[350], PrimeQ[6# - 1] && PrimeQ[6# + 1] & ] Select[Range[400],AllTrue[6#+{1,-1},PrimeQ]&] (* Harvey P. Dale, Jul 27 2022 *) #/6&/@Select[Range[6,2500,6],AllTrue[#+{1,-1},PrimeQ]&] (* Harvey P. Dale, Mar 31 2023 *)
-
PARI
select(primes(100),n->isprime(n-2)&&n>5)\6 \\ Charles R Greathouse IV, Jul 05 2011
-
PARI
p=5; forprime(q=5, 1e4, if(q-p==2, print1((p+1)/6", ")); p=q); \\ Altug Alkan, Oct 13 2015
-
PARI
list(lim)=my(v=List(),p=5); forprime(q=7,6*lim+1, if(q-p==2, listput(v,q\6)); p=q); Vec(v) \\ Charles R Greathouse IV, Dec 03 2016
Formula
a(n) = A014574(n+1)/6. - Ivan N. Ianakiev, Aug 19 2013
Extensions
More terms from Larry Reeves (larryr(AT)acm.org), Mar 27 2001
Comments