OFFSET
1,1
MATHEMATICA
(* This script is not convenient for more than 10 terms *) A061712[n_] := A061712[ n] = Module[{m, s, k, p}, For[m=0, True, m++, s = {1, Sequence @@ #, 1} & /@ Permutations[Join[Table[1, {n-2}], Table[0, {m}]]] // Sort; For[k=1, k <= Length[ s], k++, p = FromDigits[s[[k]], 2]; If[PrimeQ[p], Return[p]]]]]; A061712[1] = 2; Reap[Do[If[A061712[n+1] < A061712[n], Print[n]; Sow[n]], {n, 1, 250}]][[2, 1]] (* Jean-François Alcover, Mar 16 2015 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Shevelev and Peter J. C. Moses, Oct 25 2012
STATUS
approved