OFFSET
1,1
COMMENTS
The only common values for q*r mod p and q*r mod s that are not multiples of 12 appear to be 1 for p=2 and 2 for p=3.
If we have prime gaps q-p=2, r-q=6*n-2, s-r=2, then q*r == 12*n (mod p) and q*r == 12*n (mod s), so (if p > 12*n) this is a candidate for a(n). Dickson's conjecture implies there are infinitely many such p. Thus a(n) should always exist.
It appears that in all cases if p = a(n) and q,r,s are the next three primes, q-p = s-r and n = (q-p)*(r-p)/12.
LINKS
Robert Israel, Table of n, a(n) for n = 1..106
EXAMPLE
For p=1931 we have q,r,s = 1933, 1949, 1951, and 1933*1949 mod 1931 = 1933*1949 mod 1951 = 36 = 12*3. This is the first time that value appears, so a(3) = 1931.
MAPLE
q:= 2: r:= 3: s:= 5:
for i from 1 to 10^6 do
p:= q; q:= r; r:= s: s:= nextprime(s);
v:= q*r mod p; w:= q*r mod s;
if v = w and v mod 12 = 0 and not assigned(R[v/12]) then
R[v/12]:= p;
fi
od:
for nn from 1 while assigned(R[nn]) do od:
seq(R[i], i=1..nn-1);
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Nov 03 2020
STATUS
approved
