OFFSET
0,4
COMMENTS
A composition of n is a finite sequence of positive integers with sum n.
EXAMPLE
The a(1) = 1 through a(6) = 14 compositions:
(1) (2) (3) (4) (5) (6)
(1,2) (1,3) (1,4) (1,5)
(2,1) (3,1) (2,3) (2,4)
(1,1,2) (3,2) (4,2)
(1,2,1) (4,1) (5,1)
(2,1,1) (1,1,3) (1,1,4)
(1,2,2) (1,2,3)
(1,3,1) (1,3,2)
(2,1,2) (1,4,1)
(2,2,1) (2,1,3)
(3,1,1) (2,3,1)
(3,1,2)
(3,2,1)
(4,1,1)
MATHEMATICA
normQ[m_]:=Or[m=={}, Union[m]==Range[Max[m]]];
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n], normQ[Length/@Split[Sort[#]]]&]], {n, 20}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Nov 20 2019
EXTENSIONS
a(0), a(21)-a(37) from Alois P. Heinz, Nov 21 2019
STATUS
approved