A383668 Numbers whose binary representation has a positive number of 0s, all with even runlength.
4, 9, 12, 16, 19, 25, 28, 33, 36, 39, 48, 51, 57, 60, 64, 67, 73, 76, 79, 97, 100, 103, 112, 115, 121, 124, 129, 132, 135, 144, 147, 153, 156, 159, 192, 195, 201, 204, 207, 225, 228, 231, 240, 243, 249, 252, 256, 259, 265, 268, 271, 289, 292, 295, 304, 307
Offset: 1
Examples
The binary representation 19 is 10011, so 19 is in the sequence.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
with(priqueue): R:= NULL: count:= 0: q:= 1: initialize(pq); insert([-1],pq); while count < 100 do t:= op(extract(pq)); if t = -q then q:= 2*q+1 else R:= R,-t; count:= count+1; fi; insert([2*t-1],pq); insert([4*t],pq); od: R; # Robert Israel, Jun 16 2025
-
Mathematica
Map[#[[1]] &, Cases[Map[{#, # =!= {} && Apply[And, EvenQ[StringLength[#]]] &[StringCases[IntegerString[#, 2], "0" ..]]} &, Range[1000]], {, True}]] (* _Peter J. C. Moses, Apr 23 2025 *)
Comments