Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #15 Dec 14 2019 08:07:38
%S 1,2,7,11,16,32,402,1107,1829,2584,3124,6936
%N Numbers n such that (Product of first n twin prime pair averages [A014574]) - 1 is prime.
%C Some of the larger entries may only correspond to probable primes.
%e a(2) = 2 because the product of the first two terms of A014574 - 1, 4 * 6-1 = 23, is prime.
%t seq = {1}; prod = 4; k = 1; Do[If[AllTrue[6 n + {-1, 1}, PrimeQ], prod *= 6 n; k++; If[PrimeQ[prod - 1], AppendTo[seq, k]]], {n, 1, 5000}]; seq (* _Amiram Eldar_, Dec 14 2019 *)
%o (PARI) {atm(N)=local(t, c); t=1; c=0; forprime(p=2,N,if(isprime(p+2), t*=p+1; c++; if(isprime(t-1), print1(c, ", "))))}
%Y Cf. A014574.
%K nonn,more
%O 1,2
%A _Jason Earls_, Dec 26 2002
%E a(8)-a(12) from _Amiram Eldar_, Dec 14 2019