login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A208238 Smallest prime greater than n, containing it in binary representation. 4
2, 2, 5, 7, 17, 11, 13, 23, 17, 19, 41, 23, 89, 29, 29, 31, 67, 71, 37, 79, 41, 43, 89, 47, 97, 89, 53, 59, 113, 59, 61, 127, 131, 67, 137, 71, 73, 101, 307, 79, 163, 83, 337, 107, 89, 109, 349, 191, 97, 113, 101, 103, 211, 107, 109, 223, 113, 229, 233, 239 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,1
COMMENTS
a(n) <= A208241(n);
A174332(n) = a(A000040(n)).
LINKS
MATHEMATICA
spgn[n_]:=Module[{idn2=IntegerDigits[n, 2], p=NextPrime[n]}, While[SequenceCount[ IntegerDigits[ p, 2], idn2] == 0, p = NextPrime[p]]; p]; Array[spgn, 60, 0] (* Harvey P. Dale, Dec 23 2023 *)
PROG
(Haskell)
import Data.List (genericIndex, find, isInfixOf)
import Data.Maybe (fromJust)
a208238 = genericIndex a208238_list
a208238_list = f nns $ filter ((== 1) . a010051' . fst) nns where
f mms'@((m, ms):mms) pps'@((p, ps):pps) =
if m == p then f mms' pps else q : f mms pps'
where q = fst $ fromJust $ find ((ms `isInfixOf`) . snd) pps'
nns = zip [0..] a030308_tabf
CROSSREFS
Sequence in context: A047083 A327019 A035085 * A127413 A145344 A034438
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Feb 14 2013
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 22:36 EDT 2024. Contains 371917 sequences. (Running on oeis4.)