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

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)).

A330426 Primes P where the distance to the nearest prime is greater than 2*log(P).

Original entry on oeis.org

211, 2179, 2503, 3967, 4177, 7369, 7393, 11027, 11657, 14107, 16033, 16787, 18013, 18617, 18637, 18839, 19661, 21247, 23719, 24281, 29101, 32749, 33247, 33679, 33997, 37747, 38501, 40063, 40387, 42533, 42611, 44417, 46957, 51109, 51383, 53479, 54217, 55291, 55763
Offset: 1

Views

Author

Steven M. Altschuld, Dec 14 2019

Keywords

Comments

The author suggests that these numbers be called Double Frogger Primes because two times the distance as the average distance to the nearest neighbor (the log) has to be hopped.

Examples

			P = 211 is a term because 199 + 2*log(211) < 211 < 223 - 2*log(211).
P = 199 is not a term because 197 + 2*log(199) > 199.
		

Crossrefs

Cf. A288908 (with 1*log(P)), A330427 (with 3*log(P)), A330428.

Programs

  • Magma
    f:=func;  [p:p in PrimesUpTo(56000)|f(p)];// Marius A. Burtea, Dec 18 2019
  • Maple
    q:= 3: state:= false: count:= 0: Res:= NULL:
    while count < 100 do
      p:= nextprime(q);
      newstate:= is(p-q > 2*log(q));
      if state and newstate then
        count:= count+1; Res:= Res, q;
      fi;
      q:= p; state:= newstate;
    od:
    Res; # Robert Israel, Dec 18 2019
  • Mathematica
    lst={};Do[a=Prime[n];If[Min[Abs[a-NextPrime[a,{-1,1}]]]>2*Log[a],AppendTo[lst,a]],{n,1,10000}];lst (* Metin Sariyar, Dec 15 2019 *)
    (* Second program: *)
    Select[Prime@ Range[10^4], Min@ Abs[# - NextPrime[#, {-1, 1}]] > 2 Log[#] &] (* Michael De Vlieger, Dec 15 2019 *)

Extensions

More terms from Metin Sariyar, Dec 15 2019

A330428 Smallest prime p such that both nearest primes up and down are farther away than n*log(p).

Original entry on oeis.org

5, 211, 38501, 413353, 10938023, 142414669, 163710121, 8835528511, 31587561361, 343834606051, 1480975873513, 26923643849953
Offset: 1

Views

Author

Steven M. Altschuld, Dec 14 2019

Keywords

Comments

For these numbers, the name "Lowest Frogger Primes" LFP(n) is suggested because (frog) jumps with a length greater than n times the local average are required to bridge the gaps (logs).

Crossrefs

Cf. A288908 (with 1*log(P)), A330426 (with 2*log(P)), A330427 (with 3*log(P)).

Programs

  • PARI
    {my(npp=2,np=3,n=1);forprime(p=5,10^9,my(d=log(p)*n);if(np-npp>d&&p-np>d,print(np,", ");n++);npp=np;np=p)} \\ Hugo Pfoertner, Dec 14 2019

Extensions

a(5)-a(9) from Hugo Pfoertner, Dec 14 2019
a(10) from Hugo Pfoertner, Dec 16 2019
a(11)-a(12) from Giovanni Resta, Dec 19 2019
Showing 1-3 of 3 results.