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.

A341322 Primes p such that (p*r) == q (mod p+r) where q and r are the next primes after p.

This page as a plain text file.
%I A341322 #9 Feb 09 2021 02:46:40
%S A341322 2,5,7,19
%N A341322 Primes p such that (p*r) == q (mod p+r) where q and r are the next primes after p.
%C A341322 No other terms < 10^9.
%C A341322 If x = (p+r)/2 and d = (r-p)/2, p*r = x^2 - d^2 == -d^2 (mod x), while x-d < q < x+d.  We can't have q = x-d^2, so it must be that q >= 2 x - d^2, and thus d^2 >= 2x-q > x-d.  Cramér's conjecture implies d^2 = o(x), so that implies the sequence is finite.
%H A341322 Wikipedia, <a href="https://en.wikipedia.org/wiki/Cram%C3%A9r%27s_conjecture">Cramér's conjecture</a>
%e A341322 For n=1: a(1) = p = 2, q = 3, r = 5, (2*5) mod (2+5) = 10 mod 7 = 3.
%e A341322 For n=2: a(2) = p = 5, q = 7, r = 11, (5*11) mod (5+11) = 55 mod 16 = 7.
%e A341322 For n=3: a(3) = p = 7, q = 11, r = 13, (7*13) mod (7+13) = 91 mod 20 = 11.
%e A341322 For n=4: a(4) = p = 19, q = 23, r = 29, (19*29) mod (19+29) = 551 mod 48 = 23.
%p A341322 N:= 10^6: # for terms <= N
%p A341322 p:= 1: q:= 2: r:= 3: R:= NULL:
%p A341322 while p < N do
%p A341322   p:= q; q:= r; r:= nextprime(r);
%p A341322 if p*r mod (p+r) = q then R:=R,p fi;
%p A341322 od:
%p A341322 R;
%K A341322 nonn,fini,bref
%O A341322 1,1
%A A341322 _J. M. Bergot_ and _Robert Israel_, Feb 08 2021