OFFSET
1,7
COMMENTS
A Lyndon composition of n is a finite sequence of positive integers summing to n that is lexicographically strictly less than all of its cyclic rotations.
EXAMPLE
The a(6) = 1 through a(8) = 11 compositions:
(132) (142) (143)
(1132) (152)
(1213) (1142)
(11212) (1214)
(1232)
(1322)
(11132)
(11213)
(11312)
(12122)
(111212)
MATHEMATICA
neckQ[q_]:=Array[OrderedQ[{q, RotateRight[q, #]}]&, Length[q]-1, 1, And];
aperQ[q_]:=Array[RotateRight[q, #1]&, Length[q], 1, UnsameQ];
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n], !OrderedQ[#]&&neckQ[#]&&aperQ[#]&]], {n, 10}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Nov 10 2019
STATUS
approved