|
|
A255568
|
|
Numbers in whose binary representation there are six 1-bits more than there are nonleading 0-bits.
|
|
2
|
|
|
63, 191, 223, 239, 247, 251, 253, 254, 639, 703, 735, 751, 759, 763, 765, 766, 831, 863, 879, 887, 891, 893, 894, 927, 943, 951, 955, 957, 958, 975, 983, 987, 989, 990, 999, 1003, 1005, 1006, 1011, 1013, 1014, 1017, 1018, 1020, 2303, 2431, 2495, 2527, 2543, 2551, 2555
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
Numbers in whose binary representation (A007088) the number of 1-bits = 6 + number of (nonleading) 0 bits.
|
|
LINKS
|
|
|
EXAMPLE
|
63 ("111111" in binary) is included because there are 0 zero-bits and six 1-bits.
191 ("10111111" in binary) is included because there is 1 zero-bit and seven 1-bits, thus there are six 1-bits more than the number of 0-bits.
|
|
PROG
|
(Perl) use ntheory ":all"; my $bits = 0; for (1..1000) { my $o = hammingweight($_); $bits++ if ($_ & ($_-1))==0; say if $o == 6+$bits-$o; } # Dana Jacobsen, Dec 16 2015
(PARI) for(b=3, 6, for(n=2^(2*b-1), 4^b-1, if(hammingweight(n)==3+b, print1(n", ")))) \\ Charles R Greathouse IV, Dec 16 2015
(PARI) listBBitMembers(b)=if(b%2, return([])); my(u=List()); forvec(v=vector(3+b/2, i, [0, b-1]), listput(u, sum(i=1, #v, 2^v[i])), 2); Vec(u) \\ Charles R Greathouse IV, Dec 16 2015
|
|
CROSSREFS
|
The intersection of A030130 and A023689 is a finite subsequence of this sequence.
|
|
KEYWORD
|
nonn,base,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|