OFFSET
1,3
COMMENTS
A composition of n is a finite sequence of positive integers summing to n. The k-th composition in standard order (row k of A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again.
EXAMPLE
The sequence of positive terms together with the corresponding compositions begins:
1: (1) 128: (8) 656: (2,3,5)
2: (2) 144: (3,5) 768: (1,9)
4: (3) 160: (2,6) 784: (1,4,5)
6: (1,2) 192: (1,7) 800: (1,3,6)
8: (4) 200: (1,3,4) 832: (1,2,7)
12: (1,3) 208: (1,2,5) 840: (1,2,3,4)
16: (5) 256: (9) 1024: (11)
20: (2,3) 272: (4,5) 1056: (5,6)
24: (1,4) 288: (3,6) 1088: (4,7)
32: (6) 320: (2,7) 1152: (3,8)
40: (2,4) 328: (2,3,4) 1280: (2,9)
48: (1,5) 384: (1,8) 1296: (2,4,5)
52: (1,2,3) 400: (1,3,5) 1312: (2,3,6)
64: (7) 416: (1,2,6) 1536: (1,10)
72: (3,4) 512: (10) 1568: (1,4,6)
80: (2,5) 544: (4,6) 1600: (1,3,7)
96: (1,6) 576: (3,7) 1664: (1,2,8)
104: (1,2,4) 640: (2,8) 1680: (1,2,3,5)
MATHEMATICA
stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n, 2]], 1], 0]]//Reverse;
Select[Range[0, 1000], Less@@stc[#]&]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Mar 20 2020
STATUS
approved