login
A374254
Numbers k such that the k-th composition in standard order is an anti-run and matches the patterns (1,2,1) or (2,1,2).
2
13, 22, 25, 45, 49, 54, 76, 77, 82, 89, 97, 101, 102, 105, 108, 109, 141, 148, 150, 153, 162, 165, 166, 177, 178, 180, 182, 193, 197, 198, 204, 205, 209, 210, 216, 217, 269, 278, 280, 281, 297, 300, 301, 305, 306, 308, 310, 322, 325, 326, 332, 333, 353, 354
OFFSET
1,1
COMMENTS
Such a composition cannot be strict.
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.
FORMULA
Equals A333489 /\ A374253.
EXAMPLE
The terms together with their standard compositions begin:
13: (1,2,1)
22: (2,1,2)
25: (1,3,1)
45: (2,1,2,1)
49: (1,4,1)
54: (1,2,1,2)
76: (3,1,3)
77: (3,1,2,1)
82: (2,3,2)
89: (2,1,3,1)
97: (1,5,1)
101: (1,3,2,1)
102: (1,3,1,2)
105: (1,2,3,1)
108: (1,2,1,3)
109: (1,2,1,2,1)
141: (4,1,2,1)
148: (3,2,3)
150: (3,2,1,2)
153: (3,1,3,1)
MATHEMATICA
stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n, 2]], 1], 0]]//Reverse;
Select[Range[0, 100], Length[Split[stc[#]]] == Length[stc[#]]&&!UnsameQ@@First/@Split[stc[#]]&]
CROSSREFS
Compositions of this type are counted by A285981.
Permutations of prime indices of this type are counted by A335460.
This is the anti-run complement case of A374249, counted by A274174.
This is the anti-run case of A374253, counted by A335548.
A003242 counts anti-run compositions, ranks A333489.
A011782 counts compositions.
A025047 counts wiggly compositions, ranks A345167.
A066099 lists compositions in standard order.
A124767 counts runs in standard compositions, anti-runs A333381.
A233564 ranks strict compositions, counted by A032020.
A333755 counts compositions by number of runs.
A335454 counts patterns matched by standard compositions.
A335456 counts patterns matched by compositions.
A335462 counts (1,2,1)- and (2,1,2)-matching permutations of prime indices.
A335465 counts minimal patterns avoided by a standard composition.
- A335470 counts (1,2,1)-matching compositions, ranks A335466.
- A335471 counts (1,2,1)-avoiding compositions, ranks A335467.
- A335472 counts (2,1,2)-matching compositions, ranks A335468.
- A335473 counts (2,1,2)-avoiding compositions, ranks A335469.
A373948 encodes run-compression using compositions in standard order.
A373949 counts compositions by run-compressed sum, opposite A373951.
A373953 gives run-compressed sum of standard compositions, excess A373954.
Sequence in context: A375408 A374253 A351291 * A336263 A059408 A164455
KEYWORD
nonn
AUTHOR
Gus Wiseman, Jul 14 2024
STATUS
approved