OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(3) = 53 is a term because with p1 = 53, p2 = 59, p3 = 61, p4 = 67, we have p1*p2+p3*p4+p1 = 7267, p1*p2+p3*p4+p2 = 7273, p1*p2+p3*p4+p3 = 7275, p1*p2+p3*p4+p4 = 7281, all composite.
MAPLE
p2:=2: p3:= 3: p4:= 5: count:= 0: R:= NULL:
while count < 100 do
p1:= p2; p2:= p3; p3:= p4; p4:= nextprime(p4);
w:= p1*p2+p3*p4;
if not ormap(t -> isprime(t+w), [p1, p2, p3, p4]) then
count:= count+1; R:= R, p1
fi
od:
R;
MATHEMATICA
acQ[{a_, b_, c_, d_}]:=AllTrue[a*b+c*d+{a, b, c, d}, CompositeQ]; Select[ Partition[ Prime[ Range[200]], 4, 1], acQ][[All, 1]] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jul 05 2021 *)
PROG
(PARI) isA340136(p1) = if(!isprime(p1), 0, my(p2=nextprime(1+p1), p3=nextprime(1+p2), p4=nextprime(1+p3), x=((p1*p2)+(p3*p4))); !isprime(x+p1)&&!isprime(x+p2)&&!isprime(x+p3)&&!isprime(x+p4)); \\ Antti Karttunen, Dec 29 2020
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Dec 29 2020
STATUS
approved