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-2 of 2 results.

A268799 Record (maximal) gaps between primes of the form 4k + 3.

Original entry on oeis.org

4, 8, 12, 20, 24, 36, 40, 56, 60, 64, 68, 112, 120, 132, 144, 156, 168, 176, 184, 200, 240, 256, 272, 280, 296, 356, 396, 444, 452, 480, 532, 616, 620, 672, 692, 708, 840, 864, 896, 916, 1004
Offset: 1

Views

Author

Alexei Kourbatov, Feb 13 2016

Keywords

Comments

Dirichlet's theorem on arithmetic progressions and GRH suggest that average gaps between primes of the form 4k + 3 below x are about phi(4)*log(x). This sequence shows that the record gap ending at p grows almost as fast as phi(4)*log^2(p). Here phi(n) is A000010, Euler's totient function; phi(4)=2.
Conjecture: a(n) < phi(4)*log^2(A268801(n)) almost always.
Conjecture: a(n) < phi(4)*n^2 for all n>2. - Alexei Kourbatov, Aug 12 2017

Examples

			The first two primes of the form 4k+3 are 3 and 7, so a(1)=7-3=4. The next prime of this form is 11; the gap 11-7 is not a record so no term is added to the sequence. The next prime of this form is 19; the gap 19-11=8 is a new record, so a(2)=8.
		

Crossrefs

Corresponding primes: A268800 (lower ends), A268801 (upper ends).

Programs

  • Mathematica
    re = 0; s = 3; Reap[For[p = 7, p < 10^8, p = NextPrime[p], If[Mod[p, 4] != 3, Continue[]]; g = p - s; If[g > re, re = g; Print[g]; Sow[g]]; s = p]][[2, 1]] (* Jean-François Alcover, Dec 12 2018, from PARI *)
  • PARI
    re=0; s=3; forprime(p=7, 1e8, if(p%4!=3, next); g=p-s; if(g>re, re=g; print1(g", ")); s=p)

A268801 Primes 4k + 3 at the end of the maximal gaps in A268799.

Original entry on oeis.org

7, 19, 43, 103, 307, 419, 1367, 2647, 7411, 7823, 11239, 11699, 31511, 47051, 148063, 288179, 360779, 425779, 507347, 666403, 1414943, 2199143, 3358423, 9287939, 11512843, 11648887, 24315443, 42454267, 145555231, 161720627, 184008203, 766669427
Offset: 1

Views

Author

Alexei Kourbatov, Feb 13 2016

Keywords

Comments

Subsequence of A002145.
A268799 lists the corresponding record gap sizes. See more comments there.

Examples

			The first two primes of the form 4k+3 are 3 and 7, so a(1)=7. The next prime of this form is 11; the gap 11-7 is not a record so no term is added to the sequence. The next prime of this form is 19; the gap 19-11=8 is a new record so a(2)=19.
		

Crossrefs

Programs

  • PARI
    re=0; s=3; forprime(p=7, 1e8, if(p%4!=3, next); g=p-s; if(g>re, re=g; print1(p", ")); s=p)
Showing 1-2 of 2 results.