|
|
A333224
|
|
Number of distinct positive consecutive subsequence-sums of the k-th composition in standard order.
|
|
40
|
|
|
0, 1, 1, 2, 1, 3, 3, 3, 1, 3, 2, 4, 3, 4, 4, 4, 1, 3, 3, 5, 3, 5, 4, 5, 3, 4, 5, 5, 5, 5, 5, 5, 1, 3, 3, 5, 2, 5, 5, 6, 3, 6, 3, 6, 5, 6, 5, 6, 3, 4, 6, 6, 5, 6, 6, 6, 5, 6, 6, 6, 6, 6, 6, 6, 1, 3, 3, 5, 3, 6, 6, 7, 3, 5, 5, 7, 4, 6, 6, 7, 3, 6, 4, 7, 5, 7, 6
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,4
|
|
COMMENTS
|
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.
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
The composition (4,3,1,2) has positive subsequence-sums 1, 2, 3, 4, 6, 7, 8, 10, so a(550) = 8.
|
|
MATHEMATICA
|
stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n, 2]], 1], 0]]//Reverse;
Table[Length[Union[ReplaceList[stc[n], {___, s__, ___}:>Plus[s]]]], {n, 0, 100}]
|
|
CROSSREFS
|
Compositions where every subinterval has a different sum are counted by A169942 and A325677 and ranked by A333222. The case of partitions is counted by A325768 and ranked by A325779.
Positive subset-sums of partitions are counted by A276024 and A299701.
Knapsack compositions are counted by A325676 and A325687 and ranked by A333223. The case of partitions is counted by A325769 and ranked by A325778, for which the number of distinct consecutive subsequences is given by A325770.
Allowing empty subsequences gives A333257.
Cf. A000120, A003022, A029931, A048793, A066099, A070939, A103295, A124767, A143823, A295235, A325680, A333217.
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|