|
|
A344619
|
|
The a(n)-th composition in standard order (A066099) has alternating sum 0.
|
|
51
|
|
|
0, 3, 10, 13, 15, 36, 41, 43, 46, 50, 53, 55, 58, 61, 63, 136, 145, 147, 150, 156, 162, 165, 167, 170, 173, 175, 180, 185, 187, 190, 196, 201, 203, 206, 210, 213, 215, 218, 221, 223, 228, 233, 235, 238, 242, 245, 247, 250, 253, 255, 528, 545, 547, 550, 556, 568
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
The alternating sum of a sequence (y_1,...,y_k) is Sum_i (-1)^(i-1) 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 terms together with the corresponding compositions begins:
0: ()
3: (1,1)
10: (2,2)
13: (1,2,1)
15: (1,1,1,1)
36: (3,3)
41: (2,3,1)
43: (2,2,1,1)
46: (2,1,1,2)
50: (1,3,2)
53: (1,2,2,1)
55: (1,2,1,1,1)
58: (1,1,2,2)
61: (1,1,1,2,1)
63: (1,1,1,1,1,1)
136: (4,4)
145: (3,4,1)
147: (3,3,1,1)
150: (3,2,1,2)
156: (3,1,1,3)
|
|
MATHEMATICA
|
ats[y_]:=Sum[(-1)^(i-1)*y[[i]], {i, Length[y]}];
stc[n_]:=Reverse[Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n, 2]], 1], 0]]]
Select[Range[0, 100], ats[stc[#]]==0&]
|
|
CROSSREFS
|
The version for Heinz numbers of partitions is A000290, counted by A000041.
These are the positions of zeros in A344618.
A103919 counts partitions by sum and alternating sum (reverse: A344612).
A116406 counts compositions with alternating sum >= 0.
A124754 gives the alternating sum of standard compositions.
A316524 is the alternating sum of the prime indices of n.
A344604 counts wiggly compositions with twins.
A344610 counts partitions by sum and positive reverse-alternating sum.
A344611 counts partitions of 2n with reverse-alternating sum >= 0.
A344616 gives the alternating sum of reversed prime indices.
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, A006330, A028260, A119899, A239830, A344605, A344607, A344650, A344739.
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|