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.

A113275 Lesser of twin primes for which the gap before the following twin primes is a record.

Original entry on oeis.org

3, 5, 17, 41, 71, 311, 347, 659, 2381, 5879, 13397, 18539, 24419, 62297, 187907, 687521, 688451, 850349, 2868959, 4869911, 9923987, 14656517, 17382479, 30752231, 32822369, 96894041, 136283429, 234966929, 248641037, 255949949
Offset: 1

Views

Author

Bernardo Boncompagni, Oct 21 2005

Keywords

Examples

			The smallest twin prime pair is 3, 5, then 5, 7 so a(1) = 3; the following pair is 11, 13 so a(2) = 5 because 11 - 5 = 6 > 5 - 3 = 2; the following pair is 17, 19: since 17 - 11 = 6 = 11 - 5 nothing happens; the following pair is 29, 31 so a(3)= 17 because 29 - 17 = 12 > 11 - 5 = 6.
		

Crossrefs

Record gaps are given in A113274. Cf. A002386.

Programs

  • Mathematica
    NextLowerTwinPrim[n_] := Block[{k = n + 2}, While[ !PrimeQ[k] || !PrimeQ[k + 2], k++ ]; k]; p = 3; r = 0; t = {3}; Do[q = NextLowerTwinPrim[p]; If[q > r + p, AppendTo[t, p]; r = q - p]; p = q, {n, 10^9}] (* Robert G. Wilson v, Oct 22 2005 *)

Formula

a(n) = A036061(n) - 2.
a(n) = A036062(n) - A113274(n).

Extensions

a(22)-a(30) from Robert G. Wilson v, Oct 22 2005
Terms up to a(72) are listed in Kourbatov (2013), terms up to a(75) in Oliveira e Silva's website, added by Max Alekseyev, Nov 06 2015