OFFSET
1,1
EXAMPLE
a(3) = 243701 because p = 247301, q = p+2 = 247303, r = p+6 = 243707, s = p+8 = 243709, (2*p+q)/5 = 146221 and (r+2*s)/5^3 = 5849 are primes, and p is the least prime that works.
MAPLE
f:= proc(n) local t, p, m;
m:= 5^n;
t:= 3;
do
t:= nextprime(t);
if t*m mod 3 <> 1 then next fi;
p:= (t*m-22)/3;
if isprime(p) and isprime(p+2) and isprime(p+6) and isprime(p+8) and isprime((3*p+2)/5) then return p fi;
od;
end proc;
map(f, [$1..20]);
MATHEMATICA
a[n_] := a[n] = Module[{t = 3, p, m = 5^n}, While[True, t = NextPrime[t]; If[Mod[t*m, 3] != 1, Continue[]]; p = (t*m - 22)/3; If[AllTrue[{p, p+2, p+6, p+8, (3p+2)/5}, PrimeQ], Return[p]]]];
Table[Print[n, " ", a[n]]; a[n], {n, 1, 19}] (* Jean-François Alcover, Jan 31 2023, after Maple program *)
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Nov 02 2022
STATUS
approved