login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


Reverse-alternating sums of standard compositions (A066099). Alternating sums of the compositions ranked by A228351.
53

%I #9 Jun 08 2021 07:26:39

%S 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,

%T 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,

%U 2,0,7,-5,-3,5,-1,3,5,-3,1,1,3,-1,5,-3,-1,3

%N Reverse-alternating sums of standard compositions (A066099). Alternating sums of the compositions ranked by A228351.

%C Up to sign, same as A124754.

%C The reverse-alternating sum of a sequence (y_1,...,y_k) is Sum_i (-1)^(k-i) y_i.

%C 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.

%e The sequence of nonnegative integers together with the corresponding standard compositions and their reverse-alternating sums begins:

%e 0: () -> 0 15: (1111) -> 0 30: (1112) -> 1

%e 1: (1) -> 1 16: (5) -> 5 31: (11111) -> 1

%e 2: (2) -> 2 17: (41) -> -3 32: (6) -> 6

%e 3: (11) -> 0 18: (32) -> -1 33: (51) -> -4

%e 4: (3) -> 3 19: (311) -> 3 34: (42) -> -2

%e 5: (21) -> -1 20: (23) -> 1 35: (411) -> 4

%e 6: (12) -> 1 21: (221) -> 1 36: (33) -> 0

%e 7: (111) -> 1 22: (212) -> 3 37: (321) -> 2

%e 8: (4) -> 4 23: (2111) -> -1 38: (312) -> 4

%e 9: (31) -> -2 24: (14) -> 3 39: (3111) -> -2

%e 10: (22) -> 0 25: (131) -> -1 40: (24) -> 2

%e 11: (211) -> 2 26: (122) -> 1 41: (231) -> 0

%e 12: (13) -> 2 27: (1211) -> 1 42: (222) -> 2

%e 13: (121) -> 0 28: (113) -> 3 43: (2211) -> 0

%e 14: (112) -> 2 29: (1121) -> -1 44: (213) -> 4

%e Triangle begins (row lengths A011782):

%e 0

%e 1

%e 2 0

%e 3 -1 1 1

%e 4 -2 0 2 2 0 2 0

%e 5 -3 -1 3 1 1 3 -1 3 -1 1 1 3 -1 1 1

%t sats[y_]:=Sum[(-1)^(i-Length[y])*y[[i]],{i,Length[y]}];

%t stc[n_]:=Reverse[Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]]

%t Table[sats[stc[n]],{n,0,100}]

%Y Up to sign, same as the reverse version A124754.

%Y The version for Heinz numbers of partitions is A344616.

%Y Positions of zeros are A344619.

%Y A000041 counts partitions of 2n with alternating sum 0, ranked by A000290.

%Y A103919 counts partitions by sum and alternating sum (reverse: A344612).

%Y A316524 is the alternating sum of the prime indices of n (reverse: A344616).

%Y A116406 counts compositions with alternating sum >= 0.

%Y A344610 counts partitions by sum and positive reverse-alternating sum.

%Y A344611 counts partitions of 2n with reverse-alternating sum >= 0.

%Y All of the following pertain to compositions in standard order:

%Y - The length is A000120.

%Y - Converting to reversed ranking gives A059893.

%Y - The rows are A066099.

%Y - The sum is A070939.

%Y - The runs are counted by A124767.

%Y - The reversed version is A228351.

%Y - Strict compositions are ranked by A233564.

%Y - Constant compositions are ranked by A272919.

%Y - The Heinz number is A333219.

%Y - Anti-run compositions are ranked by A333489.

%Y Cf. A000070, A000097, A003242, A028260, A119899, A239830, A344605, A344607, A344608, A344650, A344739.

%K sign,tabf

%O 0,3

%A _Gus Wiseman_, Jun 03 2021

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 20 22:16 EDT 2024. Contains 376078 sequences. (Running on oeis4.)