OFFSET
1,3
COMMENTS
The k-th composition in standard order (graded reverse-lexicographic, 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. This gives a bijective correspondence between nonnegative integers and integer compositions.
The first sums of a nonempty sequence (a, b, c, d, ...) are (a+b, b+c, c+d, ...).
LINKS
John Tyler Rascoe, Table of n, a(n) for n = 1..8192
EXAMPLE
For 300 we have the standard composition (3,2,1,3), with first sums (5,3,4), which are distinct, so 300 is in the sequence.
MATHEMATICA
stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n, 2]], 1], 0]]//Reverse;
firsums[c_]:=Table[c[[i]]+c[[i+1]], {i, Length[c]-1}];
Select[Range[0, 100], UnsameQ@@firsums[stc[#]]&]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Nov 23 2025
STATUS
approved
