Twin prime
A twin prime is a prime number that is either 2 less or 2 more than another prime number—for example, either member of the twin prime pair (17, 19) or (41, 43). In other words, a twin prime is a prime that has a prime gap of two. Sometimes the term twin prime is used for a pair of twin primes; an alternative name for this is prime twin or prime pair.
Twin primes become increasingly rare as one examines larger ranges, in keeping with the general tendency of gaps between adjacent primes to become larger as the numbers themselves get larger. However, it is unknown whether there are infinitely many twin primes (the socalled twin prime conjecture) or if there is a largest pair. The breakthrough^{[1]} work of Yitang Zhang in 2013, as well as work by James Maynard, Terence Tao and others, has made substantial progress towards proving that there are infinitely many twin primes, but at present this remains unsolved.^{[2]}
Unsolved problem in mathematics: Are there infinitely many twin primes? (more unsolved problems in mathematics)

Properties
Usually the pair (2, 3) is not considered to be a pair of twin primes.^{[3]} Since 2 is the only even prime, this pair is the only pair of prime numbers that differ by one; thus twin primes are as closely spaced as possible for any other two primes.
The first several twin prime pairs are
 (3, 5), (5, 7), (11, 13), (17, 19), (29, 31), (41, 43), (59, 61), (71, 73), (101, 103), (107, 109), (137, 139), ... OEIS: A077800.
Five is the only prime that belongs to two pairs, as every twin prime pair greater than (3, 5) is of the form [math]\displaystyle{ (6n1, 6n+1) }[/math] for some natural number n; that is, the number between the two primes is a multiple of 6.^{[4]} As a result, the sum of any pair of twin primes (other than 3 and 5) is divisible by 12.
Brun's theorem
In 1915, Viggo Brun showed that the sum of reciprocals of the twin primes was convergent.^{[5]} This famous result, called Brun's theorem, was the first use of the Brun sieve and helped initiate the development of modern sieve theory. The modern version of Brun's argument can be used to show that the number of twin primes less than N does not exceed
 [math]\displaystyle{ \frac{CN}{(\log N)^2} }[/math]
for some absolute constant C > 0.^{[6]} In fact, it is bounded above by [math]\displaystyle{ \frac{8 C_2 N}{(\log N)^2} \left[ 1 + \operatorname{\mathcal O}\left(\frac{\log \log N}{\log N} \right) \right], }[/math] where [math]\displaystyle{ C_2 }[/math] is the twin prime constant (slightly less than 2/3), given below.^{[7]}
Twin prime conjecture
The question of whether there exist infinitely many twin primes has been one of the great open questions in number theory for many years. This is the content of the twin prime conjecture, which states that there are infinitely many primes p such that p + 2 is also prime. In 1849, de Polignac made the more general conjecture that for every natural number k, there are infinitely many primes p such that p + 2k is also prime.^{[8]} The case k = 1 of de Polignac's conjecture is the twin prime conjecture.
A stronger form of the twin prime conjecture, the Hardy–Littlewood conjecture (see below), postulates a distribution law for twin primes akin to the prime number theorem.
On 17 April 2013, Yitang Zhang announced a proof that for some integer N that is less than 70 million, there are infinitely many pairs of primes that differ by N.^{[9]} Zhang's paper was accepted in early May 2013.^{[10]} Terence Tao subsequently proposed a Polymath Project collaborative effort to optimize Zhang's bound.^{[11]}
As of 14 April 2014, one year after Zhang's announcement, the bound has been reduced to 246.^{[12]} These improved bounds were discovered using a different approach that was simpler than Zhang's and was discovered independently by James Maynard and Terence Tao. This second approach also gave bounds for the smallest f (m) needed to guarantee that infinitely many intervals of width f (m) contain at least m primes. Moreover (see also the next section) assuming the Elliott–Halberstam conjecture and its generalized form, the Polymath Project wiki states that the bound is 12 and 6, respectively.^{[12]}
A strengthening of Goldbach’s conjecture, if proved, would also prove there is an infinite number of twin primes, as would the existence of Siegel zeroes.
Other theorems weaker than the twin prime conjecture
In 1940, Paul Erdős showed that there is a constant c < 1 and infinitely many primes p such that p′ − p < c ln p where p′ denotes the next prime after p. What this means is that we can find infinitely many intervals that contain two primes (p, p′) as long as we let these intervals grow slowly in size as we move to bigger and bigger primes. Here, "grow slowly" means that the length of these intervals can grow logarithmically. This result was successively improved; in 1986 Helmut Maier showed that a constant c < 0.25 can be used. In 2004 Daniel Goldston and Cem Yıldırım showed that the constant could be improved further to c = 0.085786... . In 2005, Goldston, Pintz, and Yıldırım established that c can be chosen to be arbitrarily small,^{[13]}^{[14]} i.e.
 [math]\displaystyle{ \liminf_{n\to\infty} \left( \frac{ p_{n+1}  p_n }{\log p_n} \right) = 0 ~. }[/math]
On the other hand, this result does not rule out that there may not be infinitely many intervals that contain two primes if we only allow the intervals to grow in size as, for example, c ln ln p .
By assuming the Elliott–Halberstam conjecture or a slightly weaker version, they were able to show that there are infinitely many n such that at least two of n, n + 2, n + 6, n + 8, n + 12, n + 18, or n + 20 are prime. Under a stronger hypothesis they showed that for infinitely many n, at least two of n, n + 2, n + 4, and n + 6 are prime.
The result of Yitang Zhang,
 [math]\displaystyle{ \liminf_{n\to\infty} (p_{n+1}  p_n) \lt N ~ \mathrm{ with } ~ N=7 \times 10^7, }[/math]
is a major improvement on the Goldston–Graham–Pintz–Yıldırım result. The Polymath Project optimization of Zhang's bound and the work of Maynard have reduced the bound: the limit inferior is at most 246.^{[15]}^{[16]}
Conjectures
First Hardy–Littlewood conjecture
The first Hardy–Littlewood conjecture (named after G. H. Hardy and John Littlewood) is a generalization of the twin prime conjecture. It is concerned with the distribution of prime constellations, including twin primes, in analogy to the prime number theorem. Let [math]\displaystyle{ \pi_2(x) }[/math] denote the number of primes p ≤ x such that p + 2 is also prime. Define the twin prime constant C_{2} as^{[17]} [math]\displaystyle{ C_2 = \prod_{\textstyle{p \; \mathrm{prime,}\atop p \ge 3}} \left(1  \frac{1}{(p1)^2} \right) \approx 0.66016 18158 46869 57392 78121 10014 \ldots . }[/math] (Here the product extends over all prime numbers p ≥ 3.) Then a special case of the first HardyLittlewood conjecture is that [math]\displaystyle{ \pi_2(x) \sim 2 C_2 \frac{x}{(\ln x)^2} \sim 2 C_2 \int_2^x {\mathrm{d} t \over (\ln t)^2} }[/math] in the sense that the quotient of the two expressions tends to 1 as x approaches infinity.^{[6]} (The second ~ is not part of the conjecture and is proven by integration by parts.)
The conjecture can be justified (but not proven) by assuming that [math]\displaystyle{ \tfrac{1}{\ln t} }[/math] describes the density function of the prime distribution. This assumption, which is suggested by the prime number theorem, implies the twin prime conjecture, as shown in the formula for [math]\displaystyle{ \pi_2(x) }[/math] above.
The fully general first Hardy–Littlewood conjecture on prime ktuples (not given here) implies that the second Hardy–Littlewood conjecture is false.
This conjecture has been extended by Dickson's conjecture.
Polignac's conjecture
Polignac's conjecture from 1849 states that for every positive even integer k, there are infinitely many consecutive prime pairs p and p′ such that p′ − p = k (i.e. there are infinitely many prime gaps of size k). The case k = 2 is the twin prime conjecture. The conjecture has not yet been proven or disproven for any specific value of k, but Zhang's result proves that it is true for at least one (currently unknown) value of k. Indeed, if such a k did not exist, then for any positive even natural number N there are at most finitely many n such that [math]\displaystyle{ p_{n+1}  p_n = m }[/math] for all m < N and so for n large enough we have [math]\displaystyle{ p_{n+1}  p_n \gt N, }[/math] which would contradict Zhang's result.^{[8]}
Large twin primes
Beginning in 2007, two distributed computing projects, Twin Prime Search and PrimeGrid, have produced several recordlargest twin primes. (As of August 2022), the current largest twin prime pair known is 2996863034895 × 2^{1290000} ± 1 ,^{[18]} with 388,342 decimal digits. It was discovered in September 2016.^{[19]}
There are 808,675,888,577,436 twin prime pairs below 10^{18}.^{[20]}^{[21]}
An empirical analysis of all prime pairs up to 4.35 × 10^{15} shows that if the number of such pairs less than x is f (x) ·x /(log x)^{2} then f (x) is about 1.7 for small x and decreases towards about 1.3 as x tends to infinity. The limiting value of f (x) is conjectured to equal twice the twin prime constant (OEIS: A114907) (not to be confused with Brun's constant), according to the Hardy–Littlewood conjecture.
Other elementary properties
Every third odd number is divisible by 3, and therefore no three successive odd numbers can be prime unless one of them is 3. Five is therefore the only prime that is part of two twin prime pairs. The lower member of a pair is by definition a Chen prime.
It has been proven^{[22]} that the pair (m, m + 2) is a twin prime if and only if
 [math]\displaystyle{ 4((m1)! + 1) \equiv m \pmod {m(m+2)}. }[/math]
If m − 4 or m + 6 is also prime then the three primes are called a prime triplet.
For a twin prime pair of the form (6n − 1, 6n + 1) for some natural number n > 1, n must end in the digit 0, 2, 3, 5, 7, or 8 (OEIS: A002822).
Isolated prime
An isolated prime (also known as single prime or nontwin prime) is a prime number p such that neither p − 2 nor p + 2 is prime. In other words, p is not part of a twin prime pair. For example, 23 is an isolated prime, since 21 and 25 are both composite.
The first few isolated primes are
It follows from Brun's theorem that almost all primes are isolated in the sense that the ratio of the number of isolated primes less than a given threshold n and the number of all primes less than n tends to 1 as n tends to infinity.
See also
References
 ↑ Thomas, Kelly Devine (Summer 2014). "Yitang Zhang's spectacular mathematical journey". The Institute Letter (Princeton, NJ: Institute for Advanced Study). https://www.ias.edu/ideas/2014/zhangbreakthrough.
 ↑ Tao, Terry, Ph.D. (presenter) (7 October 2014). Small and large gaps between the primes (video lecture). UCLA Department of Mathematics – via YouTube.
 ↑ "The first 100,000 twin primes (only first member of pair)" (plain text). U.T. Martin. https://primes.utm.edu/lists/small/100ktwins.txt.
 ↑ Caldwell, Chris K.. "Are all primes (past 2 and 3) of the forms 6n+1 and 6n−1?". U.T. Martin. https://primes.utm.edu/notes/faq/six.html.
 ↑ "Über das Goldbachsche Gesetz und die Anzahl der Primzahlpaare". Archiv for Mathematik og Naturvidenskab 34 (8): 3–19. 1915. ISSN 03654524.
 ↑ ^{6.0} ^{6.1} Bateman, Paul T.; Diamond, Harold G. (2004). Analytic Number Theory. World Scientific. pp. 313 and 334–335. ISBN 9812560807.
 ↑ Halberstam, Heini; Richert, HansEgon (2010). Sieve Methods. Dover Publications. p. 117.
 ↑ ^{8.0} ^{8.1} de Polignac, A. (1849). "Recherches nouvelles sur les nombres premiers". Comptes rendus 29: 397–401. https://babel.hathitrust.org/cgi/pt?id=mdp.39015035450967&view=1up&seq=411. "[From p. 400] "1^{er} Théorème. Tout nombre pair est égal à la différence de deux nombres premiers consécutifs d'une infinité de manières ..." (1st Theorem. Every even number is equal to the difference of two consecutive prime numbers in an infinite number of ways ...)".
 ↑ McKee, Maggie (14 May 2013). "First proof that infinitely many prime numbers come in pairs". Nature. doi:10.1038/nature.2013.12989. ISSN 00280836. http://www.nature.com/news/firstproofthatinfinitelymanyprimenumberscomeinpairs1.12989.
 ↑ "Bounded gaps between primes". Annals of Mathematics 179 (3): 1121–1174. 2014. doi:10.4007/annals.2014.179.3.7.
 ↑ "Polymath proposal: Bounded gaps between primes". 4 June 2013. http://polymathprojects.org/2013/06/04/polymathproposalboundedgapsbetweenprimes/.
 ↑ ^{12.0} ^{12.1} "Bounded gaps between primes". http://michaelnielsen.org/polymath1/index.php?title=Bounded_gaps_between_primes.
 ↑ "Small gaps between primes exist". Japan Academy. Proceedings. Series A. Mathematical Sciences 82 (4): 61–65. 2006. doi:10.3792/pjaa.82.61. http://projecteuclid.org/getRecord?id=euclid.pja/1146576181.
 ↑ "Small gaps between primes or almost primes". Transactions of the American Mathematical Society 361 (10): 5285–5330. 2009. doi:10.1090/S0002994709047886.
 ↑ Maynard, James (2015). "Small gaps between primes". Annals of Mathematics. Second Series 181 (1): 383–413. doi:10.4007/annals.2015.181.1.7.
 ↑ Polymath, D.H.J. (2014). "Variants of the Selberg sieve, and bounded intervals containing many primes". Research in the Mathematical Sciences 1: artc. 12, 83. doi:10.1186/s4068701400127.
 ↑ Sloane, N. J. A., ed. "Sequence A005597 (Decimal expansion of the twin prime constant)". OEIS Foundation. https://oeis.org/A005597. Retrieved 20191101.
 ↑ Caldwell, Chris K.. " 2996863034895 × 2^{1290000} − 1 ". UT Martin. http://primes.utm.edu/primes/page.php?id=122213.
 ↑ "World record twin primes found!". 20 September 2016. http://www.primegrid.com/forum_thread.php?id=7021.
 ↑ Sloane, N. J. A., ed. "Sequence A007508 (Number of twin prime pairs below 10^{n})". OEIS Foundation. https://oeis.org/A007508. Retrieved 20191101.
 ↑ Oliveira e Silva, Tomás (7 April 2008). "Tables of values of π(x) and of π_{2}(x)". Aveiro University. http://www.ieeta.pt/~tos/primes.html.
 ↑ P.A. Clement (1949). "Congruences for sets of primes". American Mathematical Monthly 56: 23–25. doi:10.2307/2305816.
Further reading
 Sloane, Neil; Plouffe, Simon (1995). The Encyclopedia of Integer Sequences. San Diego, CA: Academic Press. ISBN 0125586302.
External links
 Hazewinkel, Michiel, ed. (2001), "Twins", Encyclopedia of Mathematics, Springer Science+Business Media B.V. / Kluwer Academic Publishers, ISBN 9781556080104, https://www.encyclopediaofmath.org/index.php?title=p/t094470
 Top20 Twin Primes at Chris Caldwell's Prime Pages
 Xavier Gourdon, Pascal Sebah: Introduction to Twin Primes and Brun's Constant
 "Official press release" of 58711digit twin prime record
 Weisstein, Eric W.. "Twin Primes". http://mathworld.wolfram.com/TwinPrimes.html.
 The 20 000 first twin primes
 Polymath: Bounded gaps between primes
 Sudden Progress on Prime Number Problem Has Mathematicians Buzzing
Original source: https://en.wikipedia.org/wiki/Twin prime.
Read more 