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.

A338567 Primes p such that (q*r) mod p is prime, where q and r are the next primes after p.

Original entry on oeis.org

3, 5, 7, 13, 19, 23, 31, 89, 199
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Nov 02 2020

Keywords

Comments

a(10) > 2*10^10 if it exists. - Michael S. Branicky, Mar 05 2021
From Jason Yuen, Jun 11 2024: (Start)
All terms satisfy (q-p)*(r-p) > p.
Data from A002386 and A005250 show that a(10) > 18361375334787046697 if it exists. (End)
Note that q*r == (q-p)*(r-p) (mod p). As soon as the prime gap grows slow enough, for all large enough p we have (q*r) mod p = (q-p)*(r-p), which is composite, implying finiteness of this sequence. In particular, finiteness would follow from Cramer's conjecture. - Max Alekseyev, Nov 09 2024

Examples

			a(4)=13 is in the sequence because it is prime, the next two primes are 17 and 19, and (17*19) mod 13 = 11, which is prime.
		

Crossrefs

Cf. A338566, A338570. Contained in A338577.

Programs

  • Maple
    R:= NULL: q:= 2: r:= 3:
    count:= 0:
    for i from 1 to 10000 do
      p:= q; q:= r; r:= nextprime(r);
      if isprime(q*r mod p) then count:= count+1; R:= R, p fi
    od:
    R;
  • Python
    from sympy import nextprime, isprime
    def afind(limit):
      p, q, r = 1, 2, 3
      while p < limit:
        p, q, r = q, r, nextprime(r)
        if isprime(q*r % p): print(p, end=", ")
    afind(200) # Michael S. Branicky, Mar 05 2021

A338570 Primes p such that q*r mod p is prime, where q is the prime preceding p and r is the prime following p.

Original entry on oeis.org

11, 13, 19, 29, 31, 37, 47, 53, 59, 67, 73, 83, 89, 109, 127, 131, 151, 163, 173, 179, 211, 239, 251, 263, 269, 283, 307, 337, 359, 373, 383, 421, 433, 443, 449, 467, 479, 499, 503, 523, 541, 547, 569, 593, 599, 607, 653, 659, 677, 757, 787, 797, 829, 853, 877, 907, 919, 947, 967, 971, 977, 1033
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Nov 02 2020

Keywords

Comments

Primes p such that -A049711(p)*A013632(p) mod p is prime.
Includes primes p such that p-8, p-2 and p+4 are also prime. Dickson's conjecture implies that there are infinitely many of these.

Examples

			a(3) = 19 is a member because 19 is prime, the previous and following primes are 17 and 23, and (17*23) mod 19 = 11 is prime.
		

Crossrefs

Programs

  • Maple
    R:= NULL: p:= 0: q:= 2: r:= 3:
    count:= 0:
    while count < 100 do
      p:= q; q:= r; r:= nextprime(r);
      if isprime(p*r mod q) then count:= count+1; R:= R, q;  fi;
    od:
    R;

A338578 Primes p such that (r-p)*(r-q) > r, where q and r are the next two primes.

Original entry on oeis.org

2, 3, 5, 11, 17, 19, 29, 43, 47, 83, 109, 199, 283
Offset: 1

Views

Author

Robert Israel, Nov 03 2020

Keywords

Comments

a(14) > 10^8 if it exists.
As soon as the prime gap grows slow enough, for all large enough p we have (r-p)*(r-q) <= r, implying finiteness of this sequence. In particular, finiteness would follow from Cramer's conjecture. - Max Alekseyev, Nov 09 2024

Examples

			a(5)=17 is a member because it is prime, the next two primes are 19 and 23, and (23-17)*(23-19)=24 > 23.
		

Crossrefs

Contains A338566.

Programs

  • Maple
    p:= 0: q:=2:r:= 3:  R:= NULL:
    while p < 10^4 do
      p:= q: q:= r: r:= nextprime(r);
      if (r-q)*(r-p) > r then R:= R, p; fi
    od:
    R;
Showing 1-3 of 3 results.