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.

Previous Showing 11-20 of 45 results. Next

A336106 Number of integer partitions of n whose greatest part is at most one more than the sum of the other parts.

Original entry on oeis.org

1, 1, 1, 2, 3, 5, 7, 11, 15, 23, 30, 44, 58, 82, 105, 146, 186, 252, 318, 423, 530, 695, 863, 1116, 1380, 1763, 2164, 2738, 3345, 4192, 5096, 6334, 7665, 9459, 11395, 13968, 16765, 20425, 24418, 29588, 35251, 42496, 50460, 60547, 71669, 85628
Offset: 0

Views

Author

Gus Wiseman, Jul 09 2020

Keywords

Comments

Also the number of separable strong multisets of length n covering an initial interval of positive integers. A multiset is separable if it has a permutation that is an anti-run, meaning there are no adjacent equal parts.

Examples

			The a(1) = 1 through a(8) = 15 partitions:
  (1)  (11)  (21)   (22)    (32)     (33)      (43)       (44)
             (111)  (211)   (221)    (222)     (322)      (332)
                    (1111)  (311)    (321)     (331)      (422)
                            (2111)   (2211)    (421)      (431)
                            (11111)  (3111)    (2221)     (2222)
                                     (21111)   (3211)     (3221)
                                     (111111)  (4111)     (3311)
                                               (22111)    (4211)
                                               (31111)    (22211)
                                               (211111)   (32111)
                                               (1111111)  (41111)
                                                          (221111)
                                                          (311111)
                                                          (2111111)
                                                          (11111111)
		

Crossrefs

The inseparable version is A025065.
The Heinz numbers of these partitions are A335127.
The non-strong version is A336103.
Sequences covering an initial interval are A000670.
Anti-run compositions are A003242.
Anti-run patterns are A005649.
Separable partitions are A325534.
Inseparable partitions are A325535.
Separable factorizations are A335434.
Heinz numbers of separable partitions are A335433.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],2*Max@@#<=1+n&]],{n,0,15}]

A333487 Number of inseparable factorizations of n into factors > 1.

Original entry on oeis.org

0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Gus Wiseman, Jul 01 2020

Keywords

Comments

A multiset is separable if it has a permutation that is an anti-run, meaning there are no adjacent equal parts.

Examples

			The a(n) factorizations for n = 4, 16, 96, 144, 64, 192:
  2*2  4*4      2*2*2*12     12*12        8*8          3*4*4*4
       2*2*2*2  2*2*2*2*6    2*2*2*18     4*4*4        2*2*2*24
                2*2*2*2*2*3  2*2*2*2*9    2*2*2*8      2*2*2*2*12
                             2*2*2*2*3*3  2*2*2*2*4    2*2*2*2*2*6
                                          2*2*2*2*2*2  2*2*2*2*3*4
                                                       2*2*2*2*2*2*3
		

Crossrefs

The version for partitions is A325535.
The version for multisets with prescribed multiplicities is A335126.
The separable version is A335434.
Anti-run compositions are A003242.
Anti-runs are ranked by A333489.
Separable partitions are ranked by A335433.
Inseparable partitions are ranked by A335448.
Anti-run permutations of prime indices are A335452.
Patterns contiguously matched by compositions are A335457.

Programs

  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Table[Length[Select[facs[n],Select[Permutations[#],!MatchQ[#,{_,x_,x_,_}]&]=={}&]],{n,100}]

Formula

a(n) + A335434(n) = A001055(n).

A349050 Number of multisets of size n that have no alternating permutations and cover an initial interval of positive integers.

Original entry on oeis.org

0, 0, 1, 1, 3, 4, 8, 12, 20, 32, 48, 80, 112, 192, 256, 448, 576, 1024, 1280, 2304, 2816, 5120, 6144, 11264, 13312, 24576, 28672, 53248, 61440, 114688, 131072, 245760, 278528, 524288, 589824, 1114112, 1245184, 2359296, 2621440, 4980736, 5505024
Offset: 0

Views

Author

Gus Wiseman, Dec 12 2021

Keywords

Comments

A sequence is alternating if it is alternately strictly increasing and strictly decreasing, starting with either. For example, the partition (3,2,2,2,1) has no alternating permutations, even though it does have the anti-run permutations (2,3,2,1,2) and (2,1,2,3,2). Alternating permutations of multisets are a generalization of alternating or up-down permutations of {1..n}.

Examples

			The multiset {1,2,2,2,2,3,3} has no alternating permutations, even though it does have the three anti-run permutations (2,1,2,3,2,3,2), (2,3,2,1,2,3,2), (2,3,2,3,2,1,2), so is counted under a(7).
The a(2) = 1 through a(7) = 12 multisets:
  {11}  {111}  {1111}  {11111}  {111111}  {1111111}
               {1112}  {11112}  {111112}  {1111112}
               {1222}  {12222}  {111122}  {1111122}
                       {12223}  {111123}  {1111123}
                                {112222}  {1122222}
                                {122222}  {1122223}
                                {122223}  {1222222}
                                {123333}  {1222223}
                                          {1222233}
                                          {1222234}
                                          {1233333}
                                          {1233334}
As compositions:
  (2)  (3)  (4)    (5)      (6)      (7)
            (1,3)  (1,4)    (1,5)    (1,6)
            (3,1)  (4,1)    (2,4)    (2,5)
                   (1,3,1)  (4,2)    (5,2)
                            (5,1)    (6,1)
                            (1,1,4)  (1,1,5)
                            (1,4,1)  (1,4,2)
                            (4,1,1)  (1,5,1)
                                     (2,4,1)
                                     (5,1,1)
                                     (1,1,4,1)
                                     (1,4,1,1)
		

Crossrefs

The case of weakly decreasing multiplicities is A025065.
The inseparable case is A336102.
A separable instead of alternating version is A336103.
The version for partitions is A345165.
The version for factorizations is A348380, complement A348379.
The complement (still covering an initial interval) is counted by A349055.
A000670 counts sequences covering an initial interval, anti-run A005649.
A001250 counts alternating permutations, complement A348615.
A003242 counts Carlitz (anti-run) compositions, ranked by A333489.
A025047 = alternating compositions, ranked by A345167, also A025048/A025049.
A049774 counts permutations avoiding the consecutive pattern (1,2,3).
A325534 counts separable partitions, ranked by A335433.
A325535 counts inseparable partitions, ranked by A335448.
A345170 counts partitions w/ an alternating permutation, ranked by A345172.
A344654 counts partitions w/o an alternating permutation, ranked by A344653.

Programs

  • Mathematica
    allnorm[n_]:=If[n<=0,{{}},Function[s,Array[Count[s,y_/;y<=#]+1&,n]]/@Subsets[Range[n-1]+1]];
    wigQ[y_]:=Or[Length[y]==0,Length[Split[y]]== Length[y]&&Length[Split[Sign[Differences[y]]]]==Length[y]-1];
    Table[Length[Select[allnorm[n],Select[Permutations[#],wigQ]=={}&]],{n,0,7}]
  • PARI
    a(n) = if(n==0, 0, if(n%2==0, (n+2)*2^(n/2-3), (n-1)*2^((n-1)/2-2))) \\ Andrew Howroyd, Jan 13 2024

Formula

a(n) = A011782(n) - A349055(n).
a(n) = (n+2)*2^(n/2-3) for even n > 0; a(n) = (n-1)*2^((n-5)/2) for odd n. - Andrew Howroyd, Jan 13 2024

Extensions

Terms a(10) and beyond from Andrew Howroyd, Jan 13 2024

A349055 Number of multisets of size n that have an alternating permutation and cover an initial interval of positive integers.

Original entry on oeis.org

1, 1, 1, 3, 5, 12, 24, 52, 108, 224, 464, 944, 1936, 3904, 7936, 15936, 32192, 64512, 129792, 259840, 521472, 1043456, 2091008, 4183040, 8375296, 16752640, 33525760, 67055616, 134156288, 268320768, 536739840, 1073496064, 2147205120, 4294443008, 8589344768
Offset: 0

Views

Author

Gus Wiseman, Dec 12 2021

Keywords

Comments

A sequence is alternating if it is alternately strictly increasing and strictly decreasing, starting with either. For example, the partition (3,2,2,2,1) has no alternating permutations, even though it does have the anti-run permutations (2,3,2,1,2) and (2,1,2,3,2). Alternating permutations of multisets are a generalization of alternating or up-down permutations of {1..n}.
The multisets that have an alternating permutation are those which have no part with multiplicity greater than floor(n/2) except for odd n when either the smallest or largest part can have multiplicity ceiling(n/2). - Andrew Howroyd, Jan 13 2024

Examples

			The multiset {1,2,2,3} has alternating permutations (2,1,3,2), (2,3,1,2), so is counted under a(4).
The a(1) = 1 through a(5) = 12 multisets:
  {1}  {1,2}  {1,1,2}  {1,1,2,2}  {1,1,1,2,2}
              {1,2,2}  {1,1,2,3}  {1,1,1,2,3}
              {1,2,3}  {1,2,2,3}  {1,1,2,2,2}
                       {1,2,3,3}  {1,1,2,2,3}
                       {1,2,3,4}  {1,1,2,3,3}
                                  {1,1,2,3,4}
                                  {1,2,2,3,3}
                                  {1,2,2,3,4}
                                  {1,2,3,3,3}
                                  {1,2,3,3,4}
                                  {1,2,3,4,4}
                                  {1,2,3,4,5}
As compositions:
  (1)  (1,1)  (1,2)    (2,2)      (2,3)
              (2,1)    (1,1,2)    (3,2)
              (1,1,1)  (1,2,1)    (1,1,3)
                       (2,1,1)    (1,2,2)
                       (1,1,1,1)  (2,1,2)
                                  (2,2,1)
                                  (3,1,1)
                                  (1,1,1,2)
                                  (1,1,2,1)
                                  (1,2,1,1)
                                  (2,1,1,1)
                                  (1,1,1,1,1)
		

Crossrefs

The strong inseparable case is A025065.
A separable instead of alternating version is A336103, complement A336102.
The case of weakly decreasing multiplicities is A336106.
The version for non-twin partitions is A344654, ranked by A344653.
The complement for non-twin partitions is A344740, ranked by A344742.
The complement for partitions is A345165, ranked by A345171.
The version for partitions is A345170, ranked by A345172.
The version for factorizations is A348379, complement A348380.
The complement (still covering an initial interval) is counted by A349050.
A000670 counts sequences covering an initial interval, anti-run A005649.
A001250 counts alternating permutations, complement A348615.
A003242 counts Carlitz (anti-run) compositions, ranked by A333489.
A025047 = alternating compositions, ranked by A345167, also A025048/A025049.
A049774 counts permutations avoiding the consecutive pattern (1,2,3).
A325534 counts separable partitions, ranked by A335433.
A325535 counts inseparable partitions, ranked by A335448.

Programs

  • Mathematica
    allnorm[n_]:=If[n<=0,{{}},Function[s, Array[Count[s,y_/;y<=#]+1&,n]]/@Subsets[Range[n-1]+1]];
    wigQ[y_]:=Or[Length[y]==0, Length[Split[y]]==Length[y]&&Length[Split[Sign[Differences[y]]]]==Length[y]-1];
    Table[Length[Select[allnorm[n], Select[Permutations[#],wigQ]!={}&]],{n,0,7}]
  • PARI
    a(n) = if(n==0, 1, 2^(n-1) - if(n%2==0, (n+2)*2^(n/2-3), (n-1)*2^((n-5)/2))) \\ Andrew Howroyd, Jan 13 2024

Formula

a(n) = A011782(n) - A349050(n).
a(n) = 2^(n-1) - (n+2)*2^(n/2-3) for even n > 0; a(n) = 2^(n-1) - (n-1)*2^((n-5)/2) for odd n. - Andrew Howroyd, Jan 13 2024

Extensions

Terms a(10) and beyond from Andrew Howroyd, Jan 13 2024

A386583 Triangle read by rows where T(n,k) is the number of length k integer partitions of n having a permutation without any adjacent equal parts (separable).

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 1, 2, 2, 0, 0, 0, 1, 2, 2, 1, 0, 0, 0, 1, 3, 4, 1, 1, 0, 0, 0, 1, 3, 5, 3, 2, 0, 0, 0, 0, 1, 4, 6, 4, 3, 1, 0, 0, 0, 0, 1, 4, 8, 6, 5, 1, 1, 0, 0, 0, 0, 1, 5, 10, 8, 8, 3, 2, 0, 0, 0, 0, 0, 1, 5, 11, 12, 11, 5, 3, 1, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Aug 03 2025

Keywords

Comments

A multiset is separable iff it has a permutation that is an anti-run, meaning there are no adjacent equal parts.
Separable partitions (A325534) are different from partitions of separable type (A386585).
Are the rows all unimodal?
Some rows are not unimodal: T(200, k=26..30) = 149371873744, 153304102463, 152360653274, 152412869411, 147228477998. - Alois P. Heinz, Aug 04 2025

Examples

			Row n = 9 counts the following partitions:
  (9)  (5,4)  (4,3,2)  (3,3,2,1)  (3,2,2,1,1)  (2,2,2,1,1,1)
       (6,3)  (4,4,1)  (4,2,2,1)  (3,3,1,1,1)
       (7,2)  (5,2,2)  (4,3,1,1)  (4,2,1,1,1)
       (8,1)  (5,3,1)  (5,2,1,1)
              (6,2,1)
              (7,1,1)
Triangle begins:
  1
  0  1
  0  1  0
  0  1  1  0
  0  1  1  1  0
  0  1  2  2  0  0
  0  1  2  2  1  0  0
  0  1  3  4  1  1  0  0
  0  1  3  5  3  2  0  0  0
  0  1  4  6  4  3  1  0  0  0
  0  1  4  8  6  5  1  1  0  0  0
  0  1  5 10  8  8  3  2  0  0  0  0
  0  1  5 11 12 11  5  3  1  0  0  0  0
  0  1  6 14 14 15  8  6  1  1  0  0  0  0
  0  1  6 16 19 20 11  9  3  2  0  0  0  0  0
  0  1  7 18 23 27 17 14  5  3  1  0  0  0  0  0
  0  1  7 21 29 34 23 20  9  6  1  1  0  0  0  0  0
  0  1  8 24 34 43 32 28 13 10  3  2  0  0  0  0  0  0
  0  1  8 26 42 53 42 38 20 15  5  3  1  0  0  0  0  0  0
  0  1  9 30 48 66 55 52 28 23  9  6  1  1  0  0  0  0  0  0
  0  1  9 33 58 80 70 68 41 33 14 10  3  2  0  0  0  0  0  0  0
  ...
		

Crossrefs

Separable case of A008284.
Row sums are A325534, ranked by A335433.
For inseparable instead separable we have A386584, sums A325535, ranks A335448.
For separable type instead of separable we have A386585, sums A336106, ranks A335127.
For inseparable type instead of separable we have A386586, sums A025065, ranks A335126.
A003242 and A335452 count anti-runs, ranks A333489, patterns A005649.
A124762 gives inseparability of standard compositions, separability A333382.
A239455 counts Look-and-Say partitions, ranks A351294.
A336103 counts normal separable multisets, inseparable A336102.
A351293 counts non-Look-and-Say partitions, ranks A351295.
A386633 counts separable set partitions, row sums of A386635.
A386634 counts inseparable set partitions, row sums of A386636.

Programs

  • Mathematica
    sepQ[y_]:=Select[Permutations[y],Length[Split[#]]==Length[y]&]!={};
    Table[Length[Select[IntegerPartitions[n,{k}],sepQ]],{n,0,15},{k,0,n}]

A386584 Triangle read by rows where T(n,k) is the number of length k>=0 integer partitions of n having no permutation without any adjacent equal parts (inseparable).

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 2, 1, 1, 1, 0, 0, 1, 0, 2, 1, 2, 1, 1, 0, 0, 0, 1, 2, 2, 2, 2, 1, 1, 0, 0, 1, 0, 3, 2, 4, 2, 2, 1, 1, 0, 0, 0, 0, 3, 2, 4, 3, 3, 2, 1, 1
Offset: 0

Views

Author

Gus Wiseman, Aug 05 2025

Keywords

Comments

A multiset is inseparable iff it has no anti-run permutations, where an anti-run is a sequence without any adjacent equal parts. Inseparable partitions (A325535) are different from partitions of inseparable type (A386586).

Examples

			Row n = 10 counts the following partitions:
  . . 55 . 7111 61111 511111 4111111 31111111 211111111 1111111111
           4222 22222 421111 3211111 22111111
           3331       331111
                      222211
Triangle begins:
  0
  0  0
  0  0  1
  0  0  0  1
  0  0  1  0  1
  0  0  0  0  1  1
  0  0  1  1  1  1  1
  0  0  0  0  2  1  1  1
  0  0  1  0  2  1  2  1  1
  0  0  0  1  2  2  2  2  1  1
  0  0  1  0  3  2  4  2  2  1  1
  0  0  0  0  3  2  4  3  3  2  1  1
  0  0  1  1  3  2  6  4  4  3  2  1  1
  0  0  0  0  4  3  6  5  6  4  3  2  1  1
  0  0  1  0  4  3  9  6  8  5  5  3  2  1  1
  0  0  0  1  4  3  9  7 10  8  6  5  3  2  1  1
  0  0  1  0  5  3 12  8 13  9 10  6  5  3  2  1  1
  0  0  0  0  5  4 12 10 16 12 12  9  7  5  3  2  1  1
  0  0  1  1  5  4 16 11 20 15 17 12 10  7  5  3  2  1  1
  0  0  0  0  6  4 16 13 24 18 21 16 14 10  7  5  3  2  1  1
  0  0  1  0  6  4 20 14 29 21 28 20 19 13 11  7  5  3  2  1  1
		

Crossrefs

Inseparable case of A008284 or A072233.
Row sums are A325535, ranked by A335448.
For separable instead of inseparable we have A386583, sums A325534, ranks A335433.
For separable type we have A386585, sums A336106, ranks A335127.
For inseparable type we have A386586, sums A025065, ranks A335126.
A003242 and A335452 count anti-runs, ranks A333489, patterns A005649.
A124762 gives inseparability of standard compositions, separability A333382.
A336103 counts normal separable multisets, inseparable A336102.
A386633 counts separable set partitions, row sums of A386635.
A386634 counts inseparable set partitions, row sums of A386636.

Programs

  • Mathematica
    insepQ[y_]:=Select[Permutations[y],Length[Split[#]]==Length[y]&]=={};
    Table[Length[Select[IntegerPartitions[n,{k}],insepQ]],{n,0,15},{k,0,n}]

Formula

T(n,k) = A072233(n,k) - A386583(n,k).

A386585 Triangle read by rows where T(n,k) is the number of integer partitions y of n into k = 0..n parts such that any multiset whose multiplicities are the parts of y is separable.

Original entry on oeis.org

1, 0, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 1, 2, 1, 1, 0, 0, 1, 2, 2, 1, 1, 0, 0, 1, 3, 3, 2, 1, 1, 0, 0, 1, 3, 4, 3, 2, 1, 1, 0, 0, 1, 5, 5, 5, 3, 2, 1, 1, 0, 0, 1, 4, 7, 6, 5, 3, 2, 1, 1
Offset: 0

Views

Author

Gus Wiseman, Aug 02 2025

Keywords

Comments

We say that such partitions are of separable type.
A multiset is separable iff it has a permutation without any adjacent equal parts.

Examples

			Row n = 8 counts the following partitions:
  .  .  44  431  4211  41111  311111  2111111  11111111
            422  3311  32111  221111
            332  3221  22211
                 2222
with the following separable multisets:
  . . 11112222 11112223 11112234 11112345 11123456 11234567 12345678
               11112233 11122234 11122345 11223456
               11122233 11122334 11223345
                        11223344
Triangle begins:
  1
  0  1
  0  0  1
  0  0  1  1
  0  0  1  1  1
  0  0  1  2  1  1
  0  0  1  2  2  1  1
  0  0  1  3  3  2  1  1
  0  0  1  3  4  3  2  1  1
  0  0  1  5  5  5  3  2  1  1
  0  0  1  4  7  6  5  3  2  1  1
		

Crossrefs

This is the separable type case of A072233 or A008284.
Row sums are A336106, ranks A335127.
For separable instead of separable type we have A386583, inseparable A386584.
For inseparable instead of separable we have A386586, sums A025065, ranks A335126.
A003242 and A335452 count anti-runs, ranks A333489, patterns A005649.
A239455 counts Look-and-Say partitions, ranks A351294.
A279790 counts disjoint families on strongly normal multisets.
A325534 counts separable multisets, ranks A335433.
A325535 counts inseparable multisets, ranks A335448.
A336103 counts normal separable multisets, inseparable A336102.
A351293 counts non-Look-and-Say partitions, ranks A351295.
A386633 counts separable set partitions, row sums of A386635.
A386634 counts inseparable set partitions, row sums of A386636.

Programs

  • Mathematica
    sepQ[y_]:=Select[Permutations[y],Length[Split[#]]==Length[y]&]!={};
    mst[y_]:=Join@@Table[ConstantArray[k,y[[k]]],{k,Length[y]}];
    Table[Length[Select[IntegerPartitions[n,{k}],sepQ[mst[#]]&]],{n,0,5},{k,0,n}]

Formula

a(n) = A072233(n) - A386586(n).

A386586 Triangle read by rows where T(n,k) is the number of integer partitions y of n into k parts such that any multiset whose multiplicities are the parts of y is inseparable.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 1, 3, 2, 1, 0, 0, 0, 0, 0, 1, 3, 2, 1, 0, 0, 0, 0, 0, 0, 1, 4, 4, 2, 1, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Aug 05 2025

Keywords

Comments

We say that such partitions are of inseparable type. This is different from inseparable partitions (see A386584). A multiset is separable iff it has a permutation without any adjacent equal parts.

Examples

			The partition y = (7,2,1) is the multiplicities of the multiset {1,1,1,1,1,1,1,2,2,3}, which is inseparable, so y is counted under T(10,3).
Row n = 10 counts the following partitions (A = 10):
  .  A  91  811  7111  61111  .  .  .  .  .
        82  721  6211
        73  631
        64  622
Triangle begins:
  0
  0 0
  0 1 0
  0 1 0 0
  0 1 1 0 0
  0 1 1 0 0 0
  0 1 2 1 0 0 0
  0 1 2 1 0 0 0 0
  0 1 3 2 1 0 0 0 0
  0 1 3 2 1 0 0 0 0 0
  0 1 4 4 2 1 0 0 0 0 0
		

Crossrefs

This is the inseparable type case of A008284 or A072233.
Row sums shifted left once are A025065 (ranks A335126), separable version A336106 (ranks A335127).
For separable instead of inseparable type we have A386583.
For integer partitions instead of normal multisets we have A386584.
For separable type instead of inseparable type we have A386585.
A003242 and A335452 count anti-runs, ranks A333489, patterns A005649.
A239455 counts Look-and-Say partitions, ranks A351294.
A325534 counts separable multisets, ranks A335433.
A325535 counts inseparable multisets, ranks A335448.
A336103 counts normal separable multisets, inseparable A336102.
A351293 counts non-Look-and-Say partitions, ranks A351295.

Programs

  • Mathematica
    insepQ[y_]:=Select[Permutations[y],Length[Split[#]]==Length[y]&]=={};
    ptm[y_]:=Join@@Table[ConstantArray[k,y[[k]]],{k,Length[y]}];
    Table[Length[Select[IntegerPartitions[n,{k}],insepQ[ptm[#]]&]],{n,0,5},{k,0,n}]

Formula

a(n) = A072233(n) - A386585(n).

A131044 Triangle T(n,k) read by rows: T(n,k) is the number of compositions of n into k parts such that at least two adjacent parts are equal.

Original entry on oeis.org

1, 1, 1, 1, 0, 1, 1, 1, 2, 1, 1, 0, 4, 4, 1, 1, 1, 3, 8, 5, 1, 1, 0, 6, 14, 14, 6, 1, 1, 1, 6, 21, 32, 21, 7, 1, 1, 0, 7, 32, 55, 54, 28, 8, 1, 1, 1, 8, 38, 96, 116, 83, 36, 9, 1, 1, 0, 10, 54, 142, 222, 206, 120, 45, 10, 1, 1, 1, 9, 65, 211, 386, 438, 328, 165, 55, 11, 1
Offset: 1

Views

Author

Joerg Arndt, Jan 06 2011

Keywords

Comments

Condition is void for compositions into 1 part (there is one such composition).
Triangle = Pascal's triangle (A007318) - A106351, except for first column.

Examples

			T(5,3) = 4 because among the 6 compositions of 5 into 3 parts there are 4 with one part repeated, marked by (*) between the parts:
[ 3 1*1 ], [ 2*2 1 ], [ 1 3 1 ], [ 2 1 2 ], [ 1 2*2 ], [ 1*1 3 ].
Triangle begins:
  1;
  1, 1;
  1, 0, 1;
  1, 1, 2,  1;
  1, 0, 4,  4,  1;
  1, 1, 3,  8,  5,  1;
  1, 0, 6, 14, 14,  6, 1;
  1, 1, 6, 21, 32, 21, 7, 1;
  ...
		

Crossrefs

Cf. A106351 (no two adjacent parts are equal).

Programs

  • Maple
    b:= proc(n, h, t) option remember;
          if n `if`(k=1, 1, binomial(n-1, k-1) -b(n, -1, k)):
    seq(seq(T(n, k), k=1..n), n=1..12); # Alois P. Heinz, Feb 13 2013
  • Mathematica
    b[n_, h_, t_] := b[n, h, t] = Which[nJean-François Alcover, Feb 18 2015, after Alois P. Heinz *)
  • Sage
    def A131044_r(n,k):
        allowed = lambda x: len(x) <= 1 or 0 in differences(x)
        return len([c for c in Compositions(n,length=k) if allowed(c)])
    # [D. S. McNeil, Jan 06 2011]

A335407 Number of anti-run permutations of the prime indices of n!.

Original entry on oeis.org

1, 1, 1, 2, 0, 2, 3, 54, 0, 30, 105, 6090, 1512, 133056, 816480, 127209600, 0, 10090080, 562161600, 69864795000, 49989139200, 29593652088000, 382147120555200, 41810689605484800, 4359985823793600, 3025062801079038720, 49052072750637116160, 25835971971637227375360
Offset: 0

Views

Author

Gus Wiseman, Jul 01 2020

Keywords

Comments

An anti-run is a sequence with no adjacent equal parts.
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
Conjecture: Only vanishes at n = 4 and n = 8.
a(16) = 0. Proof: 16! = 2^15 * m where bigomega(m) = A001222(m) = 13. We can't separate 15 1's with 13 other numbers. - David A. Corneth, Jul 04 2020

Examples

			The a(0) = 1 through a(6) = 3 anti-run permutations:
  ()  ()  (1)  (1,2)  .  (1,2,1,3,1)  (1,2,1,2,1,3,1)
               (2,1)     (1,3,1,2,1)  (1,2,1,3,1,2,1)
                                      (1,3,1,2,1,2,1)
		

Crossrefs

The version for Mersenne numbers is A335432.
Anti-run compositions are A003242.
Anti-run patterns are counted by A005649.
Permutations of prime indices are A008480.
Anti-runs are ranked by A333489.
Separable partitions are ranked by A335433.
Inseparable partitions are ranked by A335448.
Anti-run permutations of prime indices are A335452.
Strict permutations of prime indices are A335489.

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    Table[Length[Select[Permutations[primeMS[n!]],!MatchQ[#,{_,x_,x_,_}]&]],{n,0,10}]
  • PARI
    \\ See A335452 for count.
    a(n)={count(factor(n!)[,2])} \\ Andrew Howroyd, Feb 03 2021

Formula

a(n) = A335452(A000142(n)). - Andrew Howroyd, Feb 03 2021

Extensions

Terms a(14) and beyond from Andrew Howroyd, Feb 03 2021
Previous Showing 11-20 of 45 results. Next