6 is in the sequence because 2*6!!! + 1 = 2*18 + 1 = 37 is prime.
MAPLE
A:= n -> mul(k, k = select(k -> k mod 3 = n mod 3, [$1 .. n])): for p from 0 to 200 do:if type(2*A(p)+1, prime)=true then printf(`%d, `, p):else fi:od:
Select[Range[0, 5000], PrimeQ[2*Times@@Range[#, 1, -3]+1]&] (* The program generates the first 24 terms of the sequence. *) (* Harvey P. Dale, Nov 26 2025 *)
PROG
(PARI) is(n)=ispseudoprime(2*prod(i=0, (n-2)\3, n-3*i)+1) \\ Charles R Greathouse IV, Oct 09 2012