Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #12 Jul 11 2014 15:20:29
%S 1,5,1,1,5,7,1,13,2,1,1,7,37,5,1,5,16,68,28,82,17,40,5,5,44,17,2,26,8,
%T 13,25,13,31,35,65,61,28,23,7,35,43,49,64,5,29,29,95,26,4,68,7,29,49,
%U 46,37,14,29,1,166,20,23,47,52,106,2,4,197,14,133,29
%N Smallest k such that (2*k*3^n+1)*2*k*3^n+1 is prime, with k not divisible by 3.
%C Conjectures: the ratio a(n)/n is always <10 and sum(a(n)/n)/N for n=1 to N tends to 1 as N tends to infinity.
%H Pierre CAMI, <a href="/A242133/b242133.txt">Table of n, a(n) for n = 1..4000</a>
%t sk[n_]:=Module[{c=3^n,k=1},While[!PrimeQ[(2*k*c+1)2*k*c+1] || Divisible[ k,3], k++];k]; Array[sk,70] (* _Harvey P. Dale_, Jul 11 2014 *)
%o (PFGW & SCRIPT )
%o SCRIPT
%o DIM n, 0
%o DIM i
%o DIM pp
%o DIMS t
%o OPENFILEOUT myf, a(n).txt
%o LABEL loop1
%o SET n, n+1
%o SET i, 0
%o LABEL loop2
%o SET i, i+1
%o SETS t, %d, %d\,; n; i
%o SET pp, (2*i*3^n+1)*2*i*3^n+1
%o PRP pp, t
%o IF ISPRP THEN GOTO a
%o GOTO loop2
%o LABEL a
%o WRITE myf, t
%o GOTO loop1
%o (PARI) a(n) = {k = 1; while (! isprime((2*k*3^n+1)*2*k*3^n+1) || !(k % 3), k++); k;} \\ _Michel Marcus_, May 05 2014
%Y Cf. A242085, A242131, A242132.
%K nonn
%O 1,2
%A _Pierre CAMI_, May 05 2014