OFFSET
1,1
COMMENTS
The sequence A168161 is a subsequence of the primes in this sequence.
EXAMPLE
There is no prime <= 1 and 2 has only nonzero binary digit, therefore these numbers are not in the sequence.
However, a(1)=3 has two binary digits, so the total number of these equal 3.
Then, 4 is larger than this, but the prime p=5 again adds 2 nonzero binary digits adding to a total of 5=a(2).
Then 6 is larger than this, but the prime p=7 adds 3 more nonzero bits for a total of 8, such that a(3)=7 and a(4)=8 don't exceed this.
PROG
(PARI) s=0; for(n=1, 9999, isprime(n) && s+=norml2(binary(n)); n<=s & print1(n", "))
CROSSREFS
KEYWORD
fini,full,nonn,base
AUTHOR
M. F. Hasler, Nov 22 2009
STATUS
approved