OFFSET
1,8
COMMENTS
a(5k+4) = 0, since (5k+4)*6^n+1 is always divisible by 5, but there are infinitely many numbers not in the form 5k+4 such that a(n) = 0. For example, a(174308) = 0 since 174308*6^n+1 is always divisible by 7, 13, 31, 37, or 97 (See A123159). Conjecture: if n is not in the form 5k+4 and n < 174308, then a(n) > 0.
However, according to the Barnes link no primes n*6^k+1 are known for n = 1296, 7776 and 46656, so these may be counterexamples. - Robert Israel, Mar 17 2015
LINKS
Eric Chen, Table of n, a(n) for n = 1..1000
Gary Barnes, Sierpinski conjectures and proofs
MAPLE
N:= 1000: # to get a(1) to a(N), using k up to 10000
a[1]:= 1:
for n from 2 to N do
if n mod 5 = 4 then a[n]:= 0
else
for k from 1 to 10000 do
if isprime(n*6^k+1) then
a[n]:= k;
break
fi
od
fi
od:
L:= [seq(a[n], n=1..N)]; # Robert Israel, Mar 17 2015
MATHEMATICA
(* m <= 10000 is sufficient up to n = 1000 *)
a[n_] := For[k = 1, k <= 10000, k++, If[PrimeQ[n*6^k + 1], Return[k]]] /. Null -> 0; Table[a[n], {n, 1, 120}]
PROG
(PARI) a(n) = if(n%5==4, 0, for(k = 1, 10000, if(ispseudoprime(n*6^k+1), return(k))))
CROSSREFS
KEYWORD
nonn
AUTHOR
Eric Chen, Mar 11 2015
STATUS
approved