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

A004676
Primes written in base 2.
86
10, 11, 101, 111, 1011, 1101, 10001, 10011, 10111, 11101, 11111, 100101, 101001, 101011, 101111, 110101, 111011, 111101, 1000011, 1000111, 1001001, 1001111, 1010011, 1011001, 1100001, 1100101, 1100111, 1101011, 1101101, 1110001, 1111111, 10000011, 10001001
OFFSET
1,1
COMMENTS
The only primes of binary weight 2 are the Fermat primes (only five are known: 11, 101, 10001, 100000001, 10000000000000001); the repunits base 2 are the Mersenne primes. - Daniel Forgues, Nov 07 2011
REFERENCES
J.-P. Allouche and J. Shallit, Automatic Sequences, Cambridge Univ. Press, 2003, p. 3.
LINKS
Chris Caldwell, The prime pages, The first 1000 primes.
FORMULA
a(n) = A007088(A000040(n)). - R. J. Mathar, Jun 03 2011
MATHEMATICA
FromDigits /@ IntegerDigits[ Prime[ Range[31]], 2] (* Robert G. Wilson v, Jun 30 2005 *)
PROG
(Haskell)
a004676 = a007088 . a000040 -- Reinhard Zumkeller, Aug 06 2012
(PARI) a(n)=subst(Pol(binary(prime(n))), 'x, 10) \\ Charles R Greathouse IV, Mar 20 2013
CROSSREFS
Cf. A019434 Fermat primes (base 10), A000668 Mersenne primes (base 10).
Sequence in context: A230297 A086084 A206073 * A303593 A124387 A171796
KEYWORD
nonn,easy,base
STATUS
approved