OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(3) = 37 is a term because 37, 41, 43 are consecutive primes, 37*41*43 = 65231, and 65231 mod (37+41) = 23, 65231 mod (37+43) = 31, and 65321 mod (41+43) = 47 are all primes.
MAPLE
q:= 2: r:= 3:
R:= NULL: count:= 0:
while count < 100 do
p:= q; q:= r; r:= nextprime(r);
if isprime(p*q*r mod (p+q)) and isprime(p*q*r mod (p+r)) and isprime(p*q*r mod (q+r)) then
count:= count+1; R:= R, p;
fi
od:
R;
MATHEMATICA
tcpQ[{a_, b_, c_}]:=Module[{t=a b c}, AllTrue[{Mod[t, a+b], Mod[t, b+c], Mod[t, a+c]}, PrimeQ]]; Select[Partition[Prime[Range[400]], 3, 1], tcpQ][[;; , 1]] (* Harvey P. Dale, Jul 21 2023 *)
PROG
(PARI) isok(p) = if (isprime(p), my(q=nextprime(p+1), r = nextprime(q+1), pqr = p*q*r); isprime(pqr % (p+q)) && isprime(pqr % (p+r)) && isprime(pqr % (q+r))); \\ Michel Marcus, Dec 28 2020
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Dec 27 2020
STATUS
approved