login

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”).

A105437
Smallest prime that remains prime when a string of n 1's is prepended to it.
1
2, 3, 3, 7, 3, 83, 31, 7, 3, 29, 3, 53, 23, 439, 23, 53, 31, 71, 31, 79, 89, 233, 7, 3, 227, 487, 281, 31, 7, 227, 47, 439, 29, 47, 349, 491, 43, 31, 23, 7, 919, 701, 229, 283, 281, 59, 223, 2693, 53, 67, 239, 2011, 2113, 467, 41, 601, 587, 311, 337, 2879, 59, 619, 71
OFFSET
0,1
EXAMPLE
a(3)=7 because it is the first prime before 31,59,61,71,73,97,... all remaining prime when 111 is prepended to each of them.
MATHEMATICA
f[n_] := Block[{k = 1, t = Table[1, {n}]}, While[id = IntegerDigits[ Prime[k]]; id[[1]] == 1 || !PrimeQ[ FromDigits[ Join[t, id]]], k++ ]; Prime[k]]; Table[ f[n], {n, 0, 62}] (* Robert G. Wilson v, Apr 09 2005 *)
CROSSREFS
Sequence in context: A023646 A056225 A343390 * A323952 A168140 A333699
KEYWORD
nonn,base
AUTHOR
Lekraj Beedassy, Apr 08 2005
EXTENSIONS
More terms from Robert G. Wilson v, Apr 09 2005
STATUS
approved