login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A332743 Number of non-unimodal compositions of n covering an initial interval of positive integers. 11
0, 0, 0, 0, 0, 1, 5, 14, 35, 83, 193, 417, 890, 1847, 3809, 7805, 15833, 32028, 64513, 129671, 260155, 521775, 1044982, 2092692, 4188168, 8381434, 16767650, 33544423, 67098683, 134213022, 268443023, 536912014, 1073846768, 2147720476, 4295440133, 8590833907 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,7
COMMENTS
A sequence of integers is unimodal if it is the concatenation of a weakly increasing and a weakly decreasing sequence.
A composition of n is a finite sequence of positive integers summing to n.
LINKS
FORMULA
For n > 0, a(n) = A107429(n) - A227038(n).
EXAMPLE
The a(5) = 1 through a(7) = 14 compositions:
(212) (213) (1213)
(312) (1312)
(1212) (2113)
(2112) (2122)
(2121) (2131)
(2212)
(3112)
(3121)
(11212)
(12112)
(12121)
(21112)
(21121)
(21211)
MATHEMATICA
normQ[m_]:=m=={}||Union[m]==Range[Max[m]];
unimodQ[q_]:=Or[Length[q]<=1, If[q[[1]]<=q[[2]], unimodQ[Rest[q]], OrderedQ[Reverse[q]]]];
Table[Length[Select[Join@@Permutations/@IntegerPartitions[n], normQ[#]&&!unimodQ[#]&]], {n, 0, 10}]
CROSSREFS
Not requiring non-unimodality gives A107429.
Not requiring the covering condition gives A115981.
The complement is counted by A227038.
A version for partitions is A332579, with complement A332577.
Unimodal compositions are A001523.
Non-unimodal permutations are A059204.
Non-unimodal normal sequences are A328509.
Numbers whose unsorted prime signature is not unimodal are A332282.
Sequence in context: A027974 A027983 A142585 * A234097 A211562 A261055
KEYWORD
nonn
AUTHOR
Gus Wiseman, Mar 02 2020
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 05:56 EDT 2024. Contains 371964 sequences. (Running on oeis4.)