|
|
A349057
|
|
Numbers k such that the k-th composition in standard order is not weakly alternating.
|
|
26
|
|
|
37, 46, 52, 53, 69, 75, 78, 92, 93, 101, 104, 105, 107, 110, 116, 117, 133, 137, 139, 142, 150, 151, 156, 157, 165, 174, 180, 181, 184, 185, 186, 187, 190, 197, 200, 201, 203, 206, 208, 209, 210, 211, 214, 215, 220, 221, 229, 232, 233, 235, 238, 244, 245, 261
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
We define a sequence to be weakly alternating if it is alternately weakly increasing and weakly decreasing, starting with either.
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 terms and corresponding compositions begin:
37: (3,2,1)
46: (2,1,1,2)
52: (1,2,3)
53: (1,2,2,1)
69: (4,2,1)
75: (3,2,1,1)
78: (3,1,1,2)
92: (2,1,1,3)
93: (2,1,1,2,1)
101: (1,3,2,1)
104: (1,2,4)
105: (1,2,3,1)
107: (1,2,2,1,1)
110: (1,2,1,1,2)
116: (1,1,2,3)
117: (1,1,2,2,1)
|
|
MATHEMATICA
|
stc[n_]:=Differences[Prepend[Join@@Position[ Reverse[IntegerDigits[n, 2]], 1], 0]]//Reverse;
whkQ[y_]:=And@@Table[If[EvenQ[m], y[[m]]<=y[[m+1]], y[[m]]>=y[[m+1]]], {m, 1, Length[y]-1}];
Select[Range[0, 100], !whkQ[stc[#]]&&!whkQ[-stc[#]]&]
|
|
CROSSREFS
|
The directed cases are counted by A129852 (incr.) and A129853 (decr.).
Partitions of this type are ranked by A349794.
Non-strict partitions of this type are counted by A349796.
Permutations of prime indices of this type are counted by A349797.
A345164 counts alternating permutations of prime indices, weak A349056.
A345165 counts partitions w/o an alternating permutation, ranked by A345171.
A345170 counts partitions w/ an alternating permutation, ranked by A345172.
A349054 counts strict alternating compositions.
Cf. A001700, A096441, A128761, A344615, A344654, A345173, A348613, A349051, A349794, A349795, A349799.
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|