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.

Showing 1-9 of 9 results.

A082884 a(n) = smallest prime p for which (r-p)/log(p) < 1/n, where r is the next prime after p.

Original entry on oeis.org

11, 59, 419, 2999, 22037, 162821, 1202627, 8886329, 65660051, 485165279, 3584913989, 26489122349, 195729610331, 1446257064389, 10686474581831, 78962960185097, 583461742527491, 4311231547116551, 31855931757115889
Offset: 1

Views

Author

Labos Elemer, Apr 17 2003

Keywords

Comments

Remark: the quotient can be larger than 1/n at much larger primes, many times. So p does not set record in "standard" sense, only sinks first below 1/n, i.e. smaller than any previous values, but not necessarily smaller than the following ones. See also illustration.

Examples

			a(1)=p(5)=11 and (13-11)/log(11) = 0.8340... < 1/1.
		

Crossrefs

Programs

  • Mathematica
    {eq=1, k=1}; Do[s=(Prime[n+1]-Prime[n])/Log[Prime[n]]//N; If[s<1/k, k=k+1; Print[{k, n, Prime[n], s}]; eq=s], {n, 1, 100000000}]

Formula

a(n)=min{prime(j): A001223(j)/log(prime(j)) < 1/n}, where prime(j)=A000040(j) is the j-th prime.

Extensions

a(11)-a(19) from Donovan Johnson, Sep 09 2008

A082891 Smallest prime p such that q = (r-p)/log(p) > n, where r is the next prime after p.

Original entry on oeis.org

2, 7, 1129, 1327, 19609, 31397, 155921, 370261, 1357201, 2010733, 20831323, 20831323, 191912783, 436273009, 3842610773, 10726904659, 25056082087, 25056082087, 25056082087, 1346294310749, 1408695493609, 2614941710599, 13829048559701, 19581334192423, 19581334192423
Offset: 1

Views

Author

Labos Elemer, Apr 17 2003

Keywords

Comments

Is lim superior(q(n)) = +infinity? See A082892.

Examples

			For n = 11 and 12: k = 1319945: p(k+1) = 20831533, p(k) = 20831323, d = p(k+1) - p(k) = 210, log(20831321) = 16.852..., q = 210/16.852... = 12.4615... > 12 and also > 11 for the first time, so a(11) = a(12) = 20831323.
		

Crossrefs

Programs

  • Mathematica
    Do[s=(Prime[n+1]-Prime[n])/Log[Prime[n]]//N; If[s>11, Print[{n, Prime[n], Prime[n+1], s, Log[Prime[n]]//N}]], {n, 1000000, 100000000}]
  • PARI
    lista(pmax) = {my(n = 1, prv = 2, d, m); print1(2, ", "); forprime(p=3, pmax, d = p-prv; m = floor(d/log(prv)); if(m > n, for(k = 1, m-n, print1(prv, ", ")); n = m); prv=p);} \\ Amiram Eldar, Nov 04 2024

Formula

a(n)= Min{p(x); (p(x+1)-p(x))/log(p(x)) > n}.

Extensions

a(10) corrected and a(13)-a(25) added by Amiram Eldar, Nov 04 2024

A082886 floor((prime(n+1)-prime(n))/log(prime(n))).

Original entry on oeis.org

1, 1, 1, 2, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 2, 0, 1, 0, 2, 0, 1, 1, 0, 1, 1, 0, 1, 0, 0, 0, 2, 2, 0, 0, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 0, 1, 2, 0, 0, 0, 2, 1, 1, 0, 0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 1, 0, 0, 1, 0, 2, 0, 1, 0, 0, 0, 0
Offset: 1

Views

Author

Labos Elemer, Apr 17 2003

Keywords

Comments

a(n) is unbounded by a theorem of Westzynthius. - Charles R Greathouse IV, Sep 04 2015

Examples

			a(217) = floor((1361-1327)/log(1327)) = floor(4.72834...) = 4.
		

Crossrefs

Programs

  • Mathematica
    Table[Floor[(Prime[n+1]-Prime[n])/Log[Prime[n]]//N], {n, 1, 220}]
  • PARI
    a(n,p=prime(n))=(nextprime(p+1)-p)\log(p) \\ Charles R Greathouse IV, Sep 04 2015

Formula

a(n)=floor((prime(n+1)-prime(n))/log(prime(n))).
a(n)=Floor(A001223(n)/log(A000040(n))).
Infinitely often a(n) >> log log n log log log log n/log log log n, see Ford-Green-Konyagin-Maynard-Tao. - Charles R Greathouse IV, Sep 04 2015

A082888 Primes p such that (r-p)/log(p) > 3, where r is the next prime after p.

Original entry on oeis.org

1129, 1327, 1669, 2179, 2477, 2971, 3137, 3271, 4297, 4831, 5119, 5351, 5531, 5591, 5749, 5953, 6491, 6917, 7253, 7759, 7963, 8389, 8467, 8893, 8971, 9551, 9973, 10009, 10399, 10531, 10799, 10909, 11743, 12163, 12853, 13063, 13187, 13933
Offset: 1

Views

Author

Labos Elemer, Apr 17 2003

Keywords

Examples

			If p = 1327 then r = 1361 and (r-p)/log(p) = 34/log(1327) = 4.72834..., so 1327 is in the sequence.
		

Crossrefs

Programs

  • Mathematica
    Do[s=(Prime[n+1]-Prime[n])/Log[Prime[n]]//N; If[s>3, Print[Prime[n]]], {n, 1, 2000}]
    Transpose[Select[Partition[Prime[Range[2000]],2,1],(Last[#]-First[#])/ Log[ First[ #]]>3&]][[1]] (* Harvey P. Dale, Apr 20 2013 *)

Formula

prime(j) such that (prime(j+1)-prime(j))/log(prime(j)) > 3.

A082889 Primes p such that (r-p)/log(p) > 4, where r is the next prime after p.

Original entry on oeis.org

1327, 15683, 16141, 19333, 19609, 20809, 25471, 28229, 31397, 31907, 34061, 34981, 35617, 35677, 36389, 37907, 40289, 40639, 43331, 43801, 44293, 45893, 48679, 58831, 59281, 60539, 69263, 73189, 74959, 79699, 81463, 82073, 85933, 86629
Offset: 1

Views

Author

Labos Elemer, Apr 17 2003

Keywords

Examples

			If p = 1327 then r = 1361 and (r-p)/log(p) = 34/log(1327) = 4.72834..., so 1327 is in the sequence.
		

Crossrefs

Programs

  • Mathematica
    Do[s=(Prime[n+1]-Prime[n])/Log[Prime[n]]//N; If[s>4, Print[Prime[n]]], {n, 1, 2000}]
    Transpose[Select[Partition[Prime[Range[10000]],2,1],(#[[2]]-#[[1]])/ Log[ #[[1]]]>4&]][[1]] (* Harvey P. Dale, Dec 10 2014 *)

Formula

prime(j) such that (prime(j+1)-prime(j))/log(prime(j)) > 4.

A082890 Primes p such that (r-p)/log(p) > 5, where r is the next prime after p.

Original entry on oeis.org

19609, 25471, 31397, 34061, 35617, 40289, 40639, 43331, 44293, 58831, 79699, 85933, 89689, 102701, 107377, 110359, 124367, 134513, 142993, 149629, 155921, 156157, 162143, 173359, 175141, 186481, 188029, 190409, 203461, 212701, 218287
Offset: 1

Views

Author

Labos Elemer, Apr 17 2003

Keywords

Examples

			If p = 492113 then r = 492227 and (r-p)/log(p) = 114/log(492113) = 8.69799..., so 492113 is in the sequence.
		

Crossrefs

Programs

  • Mathematica
    Do[s=(Prime[n+1]-Prime[n])/Log[Prime[n]]//N; If[s>5, Print[Prime[n]]], {n, 1, 50000}]
    seq[len_] := Module[{p = 2, s = {}, c = 0}, While[c < len, q = NextPrime[p]; If[q - p > 5*Log[p], AppendTo[s, p]; c++]; p = q]; s]; seq[31] (* Amiram Eldar, Nov 04 2024 *)

Formula

prime(j) such that (prime(j+1)-prime(j))/log(prime(j)) > 5.

A288908 Primes p whose distance from next prime and from previous prime is greater than log(p).

Original entry on oeis.org

5, 7, 23, 37, 47, 53, 89, 157, 173, 211, 251, 257, 263, 293, 331, 337, 359, 367, 373, 389, 409, 479, 631, 691, 701, 709, 719, 787, 797, 839, 919, 929, 1163, 1171, 1201, 1249, 1259, 1381, 1399, 1409, 1471, 1511, 1523, 1531, 1637, 1709, 1733, 1801, 1811, 1823
Offset: 1

Views

Author

Giuseppe Coppoletta, Jun 19 2017

Keywords

Comments

Primes preceded and followed by larger-than-average prime gaps (see link), then included in A082885.

Examples

			n = 5 is a term because 3 + log(5) < 5 < 7 - log(5).
n = 11 is not a term because 13 - 11 < log(11) = 2.39...
		

Crossrefs

Programs

  • Magma
    f:=func;  [p:p in PrimesInInterval(3,2000)|f(p)]; // Marius A. Burtea, Dec 19 2019
  • Mathematica
    Select[Prime@ Range[2, 300], Min@ Abs[# - NextPrime[#, {-1,1}]] > Log[#] &] (* Giovanni Resta, Jun 19 2017 *)
  • Sage
    [n for n in prime_range(3,2000) if next_prime(n)-n>log(n) and n-previous_prime(n)>log(n)]
    

Formula

A151799(a(n)) + log(a(n)) < a(n) < A151800(a(n)) - log(a(n)).

A211073 Primes p followed by a gap of at least 1/2 * log(p)^2.

Original entry on oeis.org

2, 3, 5, 7, 13, 23, 31, 113, 1327, 19609, 25471, 31397, 34061, 43331, 44293, 155921, 188029, 212701, 265621, 338033, 360653, 370261, 396733, 404851, 492113, 544279, 576791, 604073, 838249, 860143, 1098847, 1139993, 1313467, 1349533, 1357201, 1388483, 1444309
Offset: 1

Views

Author

Keywords

Comments

Primes followed by unusually long prime gaps.
The Cramér model suggests that there are about 2*sqrt(x/log^2 x) elements up to x. - Charles R Greathouse IV, Mar 18 2016

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[10^4]], NextPrime[#] - # > (Log[#]^2)/2 &] (* Alonso del Arte, Jun 02 2013 *)
  • PARI
    G=1; p=2; forprime(q=3, 1e7, if(q-p>=G && q-p>log(p)^2/2, G=ceil(log(p)^2/2); print1(p", ")); p=q)

Formula

Primes p such that all integers in (p, p + 0.5 * log(p)^2) are composite.

A211075 Primes p followed by prime gap of length log(p/log(p)^2)^2.

Original entry on oeis.org

3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 103, 109, 113, 127, 131, 139, 151, 157, 163, 167, 173, 181, 193, 199, 211, 233, 241, 251, 257, 263, 271, 283, 293, 317, 331, 337, 353, 359, 367, 373, 383, 389, 401, 409
Offset: 1

Views

Author

Keywords

Comments

Primes followed by unusually long prime gaps.

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[200]], NextPrime[#] - # > Log[#/Log[#]^2]^2 &] (* Alonso del Arte, Jun 02 2013 *)
  • PARI
    G=1;p=3;forprime(q=5,1e7,if(q-p>=G,G=log(p/log(p)^2)^2; if(q-p>=G, print1(p", ")));p=q)
Showing 1-9 of 9 results.