%I #9 Jul 29 2015 14:48:09
%S 1,2,3,4,5,6,7,8,9,10,12,13,14,15,16,17,18,20,24,25,26,28,29,30,31,32,
%T 33,34,36,40,48,49,50,52,56,57,58,60,61,62,63,64
%N Best explained by example: in the binary representation, start with 10000, then add 1 and push the 1 to the left: 10001, 10010, 10100, 11000, then add another one, 11001, 11010, 11100, etc: 11101, 11110, 11111. Then proceed with the next length of numbers: 100000, etc.
%C Numbers of the form (2^k - 1)*2^l + 2^m, where k >= 0, l > m >= 0. - _Ivan Neretin_, Jul 26 2015
%H Ivan Neretin, <a href="/A171987/b171987.txt">Table of n, a(n) for n = 1..5489</a>
%t Nest[If[EvenQ[l = #[[-1]]], Join[#, l + 2^(Range[IntegerExponent[l, 2]] - 1)], Append[#, l + 1]] &, {1}, 21] (* _Ivan Neretin_, Jul 26 2015 *)
%K nonn,base
%O 1,2
%A Stefan Maubach (s.maubach(AT)science.ru.nl), Jan 21 2010
|