|
|
A344618
|
|
Reverse-alternating sums of standard compositions (A066099). Alternating sums of the compositions ranked by A228351.
|
|
53
|
|
|
0, 1, 2, 0, 3, -1, 1, 1, 4, -2, 0, 2, 2, 0, 2, 0, 5, -3, -1, 3, 1, 1, 3, -1, 3, -1, 1, 1, 3, -1, 1, 1, 6, -4, -2, 4, 0, 2, 4, -2, 2, 0, 2, 0, 4, -2, 0, 2, 4, -2, 0, 2, 2, 0, 2, 0, 4, -2, 0, 2, 2, 0, 2, 0, 7, -5, -3, 5, -1, 3, 5, -3, 1, 1, 3, -1, 5, -3, -1, 3
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
The reverse-alternating sum of a sequence (y_1,...,y_k) is Sum_i (-1)^(k-i) y_i.
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.
|
|
LINKS
|
|
|
EXAMPLE
|
The sequence of nonnegative integers together with the corresponding standard compositions and their reverse-alternating sums begins:
0: () -> 0 15: (1111) -> 0 30: (1112) -> 1
1: (1) -> 1 16: (5) -> 5 31: (11111) -> 1
2: (2) -> 2 17: (41) -> -3 32: (6) -> 6
3: (11) -> 0 18: (32) -> -1 33: (51) -> -4
4: (3) -> 3 19: (311) -> 3 34: (42) -> -2
5: (21) -> -1 20: (23) -> 1 35: (411) -> 4
6: (12) -> 1 21: (221) -> 1 36: (33) -> 0
7: (111) -> 1 22: (212) -> 3 37: (321) -> 2
8: (4) -> 4 23: (2111) -> -1 38: (312) -> 4
9: (31) -> -2 24: (14) -> 3 39: (3111) -> -2
10: (22) -> 0 25: (131) -> -1 40: (24) -> 2
11: (211) -> 2 26: (122) -> 1 41: (231) -> 0
12: (13) -> 2 27: (1211) -> 1 42: (222) -> 2
13: (121) -> 0 28: (113) -> 3 43: (2211) -> 0
14: (112) -> 2 29: (1121) -> -1 44: (213) -> 4
Triangle begins (row lengths A011782):
0
1
2 0
3 -1 1 1
4 -2 0 2 2 0 2 0
5 -3 -1 3 1 1 3 -1 3 -1 1 1 3 -1 1 1
|
|
MATHEMATICA
|
sats[y_]:=Sum[(-1)^(i-Length[y])*y[[i]], {i, Length[y]}];
stc[n_]:=Reverse[Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n, 2]], 1], 0]]]
Table[sats[stc[n]], {n, 0, 100}]
|
|
CROSSREFS
|
Up to sign, same as the reverse version A124754.
The version for Heinz numbers of partitions is A344616.
A000041 counts partitions of 2n with alternating sum 0, ranked by A000290.
A103919 counts partitions by sum and alternating sum (reverse: A344612).
A316524 is the alternating sum of the prime indices of n (reverse: A344616).
A116406 counts compositions with alternating sum >= 0.
A344610 counts partitions by sum and positive reverse-alternating sum.
A344611 counts partitions of 2n with reverse-alternating sum >= 0.
All of the following pertain to compositions in standard order:
- Converting to reversed ranking gives A059893.
- Strict compositions are ranked by A233564.
- Constant compositions are ranked by A272919.
- Anti-run compositions are ranked by A333489.
Cf. A000070, A000097, A003242, A028260, A119899, A239830, A344605, A344607, A344608, A344650, A344739.
|
|
KEYWORD
|
sign,tabf
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|