This site is supported by donations to The OEIS Foundation. Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing. Other ways to donate

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A001097 Twin primes. 195
 3, 5, 7, 11, 13, 17, 19, 29, 31, 41, 43, 59, 61, 71, 73, 101, 103, 107, 109, 137, 139, 149, 151, 179, 181, 191, 193, 197, 199, 227, 229, 239, 241, 269, 271, 281, 283, 311, 313, 347, 349, 419, 421, 431, 433, 461, 463, 521, 523, 569, 571, 599, 601, 617, 619, 641, 643 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,1 COMMENTS Union of A001359 and A006512. The only twin primes that are Fibonacci numbers are 3, 5 and 13 [MacKinnon]. - Emeric Deutsch, Apr 24 2005 (p, p+2) are twin primes if and only if p + 2 can be represented as the sum of two primes. Brun (1919): Even if there are infinitely many twin primes, the series of all twin prime reciprocals does converges to [Brun's constant] (A065421). Clement (1949): For every n > 1, (n, n+2) are twin primes if and only if 4((n-1)! + 1) == -n (mod n(n+2)). - Stefan Steinerberger, Dec 04 2005 A164292(a(n)) = 1. - Reinhard Zumkeller, Mar 29 2010 The 100355-digit numbers, 65516468355 · 2^333333 +/- 1, are currently the largest known twin primes. They were discovered by Twin Prime Search and Primegrid in August 2009. - Paul Muljadi, Mar 07 2011 For every n > 2, the pair (n, n+2) is a twin prime if and only if ((n-1)!!)^4 == 1 (mod n(n+2)). - Thomas Ordowski, Aug 15 2016 REFERENCES P. Ribenboim, The New Book of Prime Number Records, Springer-Verlag, p. 259-265. LINKS T. D. Noe, Table of n, a(n) for n = 1..10000 M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards, Applied Math. Series 55, Tenth Printing, 1972, p. 870. J. P. Delahaye, Premiers jumeaux: frères ennemis? [Twin primes: Enemy Brothers?], Pour la science, No. 260 (Juin 1999), 102-106. Harvey Dubner, Twin Prime Statistics, Journal of Integer Sequences, Vol. 8 (2005), Article 05.4.2. J. C. Evard, Twin primes and their applications [Cached copy on the Wayback Machine] J. C. Evard, Twin primes and their applications [Local cached copy] J. C. Evard, Twin primes and their applications [Pdf file of cached copy] Andrew Granville, Primes in intervals of bounded length, Joint Math Meeting, Current Events Bulletin, Baltimore, Friday, Jan 17 2014. N. MacKinnon, Problem 10844, Amer. Math. Monthly 109, (2002), p. 78. James Maynard, Small gaps between primes, arXiv:1311.4600 [math.NT], 2013, Annals of Mathematics, to appear. D. H. J. Polymath, New equidistribution estimates of Zhang type, and bounded gaps between primes, arXiv:1402.0811 [math.NT], 2014. D. H. J. Polymath, Variants of the Selberg sieve, and bounded intervals containing many primes, arXiv:1407.4897 [math.NT], 2014. Eric Weisstein's World of Mathematics, Twin Primes Yitang Zhang, Bounded gaps between primes, Annals of Mathematics, Pages 1121-1174, Volume 179 (2014), Issue 3. MAPLE A001097 := proc(n)     option remember;     if n = 1 then         3;     else         for a from procname(n-1)+1 do             if isprime(a) and ( isprime(a-2) or isprime(a+2) ) then                 return a;             end if;         end do:     end if; end proc: # R. J. Mathar, Feb 19 2015 MATHEMATICA Select[ Prime[ Range], PrimeQ[ # - 2] || PrimeQ[ # + 2] &] (* Robert G. Wilson v, Jun 09 2005 *) Union[Flatten[Select[Partition[Prime[Range], 2, 1], #[]-#[] == 2&]]] (* Harvey P. Dale, Aug 19 2015 *) PROG (PARI) isA001097(n) = (isprime(n) && (isprime(n+2) || isprime(n-2))) \\ Michael B. Porter, Oct 29 2009 (PARI) a(n)=if(n==1, return(3)); my(p); forprime(q=3, default(primelimit), if(q-p==2 && (n-=2)<0, return(if(n==-1, q, p))); p=q) \\ Charles R Greathouse IV, Aug 22 2012 (PARI) list(lim)=my(v=List(), p=5); forprime(q=7, lim, if(q-p==2, listput(v, p); listput(v, q)); p=q); if(p+2>lim && isprime(p+2), listput(v, p)); Vec(v) \\ Charles R Greathouse IV, Mar 17 2017 (Haskell) a001097 n = a001097_list !! (n-1) a001097_list = filter ((== 1) . a164292) [1..] -- Reinhard Zumkeller, Feb 03 2014, Nov 27 2011 CROSSREFS Cf. A070076, A001359, A006512, A164292. See A077800 for another version. Sequence in context: A045393 A132143 A239879 * A117243 A179679 A059362 Adjacent sequences:  A001094 A001095 A001096 * A001098 A001099 A001100 KEYWORD nonn,core,nice AUTHOR N. J. A. Sloane, Mar 15 1996 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified December 15 12:13 EST 2019. Contains 329999 sequences. (Running on oeis4.)