cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A332672 Number of non-unimodal permutations of a multiset whose multiplicities are the prime indices of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 2, 3, 0, 0, 6, 0, 0, 6, 16, 0, 21, 0, 12, 10, 0, 0, 48, 16, 0, 81, 20, 0, 48, 0, 104, 15, 0, 30, 162, 0, 0, 21, 104, 0, 90, 0, 30, 198, 0, 0, 336, 65, 124, 28, 42, 0, 603, 50, 190, 36, 0, 0, 396, 0, 0, 405, 688, 77, 150, 0, 56, 45, 260, 0
Offset: 1

Views

Author

Gus Wiseman, Feb 23 2020

Keywords

Comments

This multiset is generally not the same as the multiset of prime indices of n. For example, the prime indices of 12 are {1,1,2}, while a multiset whose multiplicities are {1,1,2} is {1,1,2,3}.
A sequence of integers is unimodal if it is the concatenation of a weakly increasing and a weakly decreasing sequence.

Examples

			The a(n) permutations for n = 8, 9, 12, 15, 16:
  213   1212   1213   11212   1324
  312   2112   1312   12112   1423
        2121   2113   12121   2134
               2131   21112   2143
               3112   21121   2314
               3121   21211   2413
                              3124
                              3142
                              3214
                              3241
                              3412
                              4123
                              4132
                              4213
                              4231
                              4312
		

Crossrefs

Positions of zeros are one and A001751.
Support is A264828 without one.
Dominated by A318762.
The complement is counted by A332294.
A less interesting version is A332671.
The opposite version is A332742.
Unimodal compositions are A001523.
Non-unimodal permutations are A059204.
Non-unimodal compositions are A115981.
Non-unimodal normal sequences are A328509.
Heinz numbers of partitions with non-unimodal run-lengths are A332282.
Compositions whose negation is not unimodal are A332669.

Programs

  • Mathematica
    nrmptn[n_]:=Join@@MapIndexed[Table[#2[[1]],{#1}]&,If[n==1,{},Flatten[Cases[FactorInteger[n]//Reverse,{p_,k_}:>Table[PrimePi[p],{k}]]]]];
    unimodQ[q_]:=Or[Length[q]<=1,If[q[[1]]<=q[[2]],unimodQ[Rest[q]],OrderedQ[Reverse[q]]]];
    Table[Length[Select[Permutations[nrmptn[n]],!unimodQ[#]&]],{n,30}]

Formula

a(n) = A332671(A181821(n)).
a(n) + A332294(n) = A318762(n).