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.

Showing 1-9 of 9 results.

A124943 Table read by rows: number of partitions of n with k as low median.

Original entry on oeis.org

1, 1, 1, 2, 0, 1, 3, 1, 0, 1, 4, 2, 0, 0, 1, 6, 3, 1, 0, 0, 1, 8, 4, 2, 0, 0, 0, 1, 11, 6, 3, 1, 0, 0, 0, 1, 15, 8, 4, 2, 0, 0, 0, 0, 1, 20, 12, 5, 3, 1, 0, 0, 0, 0, 1, 26, 16, 7, 4, 2, 0, 0, 0, 0, 0, 1, 35, 22, 10, 5, 3, 1, 0, 0, 0, 0, 0, 1, 45, 29, 14, 6, 4, 2, 0, 0, 0, 0, 0, 0, 1, 58, 40, 19, 8, 5, 3, 1
Offset: 1

Views

Author

Keywords

Comments

For a multiset with an odd number of elements, the low median is the same as the median. For a multiset with an even number of elements, the low median is the smaller of the two central elements.
Arrange the parts of a partition nonincreasing order. Remove the first part, then the last, then the first remaining part, then the last remaining part, and continue until only a single number, the low median, remains. - Clark Kimberling, May 16 2019

Examples

			For the partition [2,1^2], the sole middle element is 1, so that is the low median. For [3,2,1^2], the two middle elements are 1 and 2; the low median is the smaller, 1.
First 8 rows:
  1
  1   1
  2   0   1
  3   1   0   1
  4   2   0   0   1
  6   3   1   0   0   1
  8   4   2   0   0   0   1
  11  6   3   1   0   0   0   1
From _Gus Wiseman_, Jul 09 2023: (Start)
Row n = 8 counts the following partitions:
  (71)        (62)     (53)   (44)  .  .  .  (8)
  (611)       (521)    (431)
  (5111)      (422)    (332)
  (4211)      (3221)
  (41111)     (2222)
  (3311)      (22211)
  (32111)
  (311111)
  (221111)
  (2111111)
  (11111111)
(End)
		

Crossrefs

Row sums are A000041.
Column k = 1 is A027336, ranks A363488.
The high version of this triangle is A124944.
The rank statistic for this triangle is A363941, high version A363942.
A version for mean instead of median is A363945, rank statistic A363943.
A high version for mean instead of median is A363946, rank stat A363944.
A version for mode instead of median is A363952, high A363953.
A008284 counts partitions by length (or decreasing mean), strict A008289.
A325347 counts partitions with integer median, ranks A359908.
A359893 and A359901 count partitions by median.
A360005(n)/2 returns median of prime indices.

Programs

  • Mathematica
    Map[BinCounts[#, {1, #[[1]] + 1, 1}] &[Map[#[[Floor[(Length[#] + 2)/2]]] &, IntegerPartitions[#]]] &, Range[13]]  (* Peter J. C. Moses, May 14 2019 *)

A124944 Table, number of partitions of n with k as high median.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 3, 1, 1, 1, 1, 4, 3, 1, 1, 1, 1, 6, 4, 1, 1, 1, 1, 1, 8, 6, 3, 1, 1, 1, 1, 1, 11, 8, 5, 1, 1, 1, 1, 1, 1, 15, 11, 7, 3, 1, 1, 1, 1, 1, 1, 20, 15, 9, 5, 1, 1, 1, 1, 1, 1, 1, 26, 21, 12, 8, 3, 1, 1, 1, 1, 1, 1, 1, 35, 27, 16, 10, 5, 1, 1, 1, 1, 1, 1, 1, 1, 45, 37, 21, 13, 8, 3
Offset: 1

Views

Author

Keywords

Comments

For a multiset with an odd number of elements, the high median is the same as the median. For a multiset with an even number of elements, the high median is the larger of the two central elements.
This table may be read as an upper right triangle with n >= 1 as column index and k >= 1 as row index. - Peter Munn, Jul 16 2017
Arrange the parts of a partition nonincreasing order. Remove the last part, then the first, then the last remaining part, then the first remaining part, and continue until only a single number, the high median, remains. - Clark Kimberling, May 14 2019

Examples

			For the partition [2,1^2], the sole middle element is 1, so that is the high median. For [3,2,1^2], the two middle elements are 1 and 2; the high median is the larger, 2.
From _Gus Wiseman_, Jul 12 2023: (Start)
Triangle begins:
   1
   1  1
   1  1  1
   2  1  1  1
   3  1  1  1  1
   4  3  1  1  1  1
   6  4  1  1  1  1  1
   8  6  3  1  1  1  1  1
  11  8  5  1  1  1  1  1  1
  15 11  7  3  1  1  1  1  1  1
  20 15  9  5  1  1  1  1  1  1  1
  26 21 12  8  3  1  1  1  1  1  1  1
  35 27 16 10  5  1  1  1  1  1  1  1  1
  45 37 21 13  8  3  1  1  1  1  1  1  1  1
  58 48 29 16 11  5  1  1  1  1  1  1  1  1  1
Row n = 8 counts the following partitions:
  (611)       (521)    (431)   (44)  (53)  (62)  (71)  (8)
  (5111)      (422)    (332)
  (41111)     (4211)   (3311)
  (32111)     (3221)
  (311111)    (2222)
  (221111)    (22211)
  (2111111)
  (11111111)
(End)
		

Crossrefs

Row sums are A000041.
Column k = 1 is A027336(n-1), ranks A364056.
Column k = 1 in the low version is A027336, ranks A363488.
The low version of this triangle is A124943.
The rank statistic for this triangle is A363942, low version A363941.
A version for mean instead of median is A363946, low A363945.
A version for mode instead of median is A363953, low A363952.
A008284 counts partitions by length, maximum, or decreasing mean.
A026794 counts partitions by minimum, strict A026821.
A325347 counts partitions with integer median, ranks A359908.
A359893 and A359901 count partitions by median.
A360005(n)/2 returns median of prime indices.

Programs

  • Mathematica
    Map[BinCounts[#, {1, #[[1]] + 1, 1}] &[Map[#[[Floor[(Length[#] + 1)/2]]] &, IntegerPartitions[#]]] &, Range[13]]  (* Peter J. C. Moses, May 14 2019 *)

A363946 Triangle read by rows where T(n,k) is the number of integer partitions of n with high mean k.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 3, 0, 1, 0, 1, 3, 2, 0, 1, 0, 1, 6, 3, 0, 0, 1, 0, 1, 6, 4, 3, 0, 0, 1, 0, 1, 11, 5, 4, 0, 0, 0, 1, 0, 1, 11, 13, 0, 4, 0, 0, 0, 1, 0, 1, 18, 9, 8, 5, 0, 0, 0, 0, 1, 0, 1, 18, 21, 10, 0, 5, 0, 0, 0, 0, 1
Offset: 0

Views

Author

Gus Wiseman, Jun 30 2023

Keywords

Comments

Extending the terminology of A124944, the "high mean" of a multiset is obtained by taking the mean and rounding up.

Examples

			Triangle begins:
  1
  0  1
  0  1  1
  0  1  1  1
  0  1  3  0  1
  0  1  3  2  0  1
  0  1  6  3  0  0  1
  0  1  6  4  3  0  0  1
  0  1 11  5  4  0  0  0  1
  0  1 11 13  0  4  0  0  0  1
  0  1 18  9  8  5  0  0  0  0  1
  0  1 18 21 10  0  5  0  0  0  0  1
  0  1 29 28 12  0  6  0  0  0  0  0  1
  0  1 29 32 18 14  0  6  0  0  0  0  0  1
  0  1 44 43 23 16  0  7  0  0  0  0  0  0  1
  0  1 44 77 27 19  0  0  7  0  0  0  0  0  0  1
Row n = 7 counts the following partitions:
  .  (1111111)  (4111)    (511)  (61)  .  .  (7)
                (3211)    (421)  (52)
                (31111)   (331)  (43)
                (2221)    (322)
                (22111)
                (211111)
		

Crossrefs

Row sums are A000041.
Column k = 2 is A026905 redoubled, ranks A363950.
For median instead of mean we have triangle A124944, low A124943.
For mode instead of mean we have rank stat A363486, high A363487.
For median instead of mean we have rank statistic A363942, low A363941.
The rank statistic for this triangle is A363944.
The version for low mean is A363945, rank statistic A363943.
For mode instead of mean we have triangle A363953, low A363952.
A008284 counts partitions by length, A058398 by mean.
A051293 counts subsets with integer mean, median A000975.
A067538 counts partitions with integer mean, strict A102627, ranks A316413.
A349156 counts partitions with non-integer mean, ranks A348551.

Programs

  • Mathematica
    meanup[y_]:=If[Length[y]==0,0,Ceiling[Mean[y]]];
    Table[Length[Select[IntegerPartitions[n],meanup[#]==k&]],{n,0,15},{k,0,n}]

A363945 Triangle read by rows where T(n,k) is the number of integer partitions of n with low mean k.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 2, 0, 1, 0, 2, 2, 0, 1, 0, 4, 2, 0, 0, 1, 0, 4, 3, 3, 0, 0, 1, 0, 7, 4, 3, 0, 0, 0, 1, 0, 7, 10, 0, 4, 0, 0, 0, 1, 0, 12, 6, 7, 4, 0, 0, 0, 0, 1, 0, 12, 16, 8, 0, 5, 0, 0, 0, 0, 1, 0, 19, 21, 10, 0, 5, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Jun 30 2023

Keywords

Comments

Extending the terminology of A124943, the "low mean" of a multiset is its mean rounded down.

Examples

			Triangle begins:
  1
  0  1
  0  1  1
  0  2  0  1
  0  2  2  0  1
  0  4  2  0  0  1
  0  4  3  3  0  0  1
  0  7  4  3  0  0  0  1
  0  7 10  0  4  0  0  0  1
  0 12  6  7  4  0  0  0  0  1
  0 12 16  8  0  5  0  0  0  0  1
  0 19 21 10  0  5  0  0  0  0  0  1
  0 19 24 15 12  0  6  0  0  0  0  0  1
  0 30 32 18 14  0  6  0  0  0  0  0  0  1
  0 30 58 23 16  0  0  7  0  0  0  0  0  0  1
  0 45 47 57  0 19  0  7  0  0  0  0  0  0  0  1
Row k = 8 counts the following partitions:
  .  (41111)     (611)   .  (71)  .  .  .  (8)
     (32111)     (521)      (62)
     (311111)    (5111)     (53)
     (22211)     (431)      (44)
     (221111)    (422)
     (2111111)   (4211)
     (11111111)  (332)
                 (3311)
                 (3221)
                 (2222)
		

Crossrefs

Row sums are A000041.
Column k = 1 is A025065, ranks A363949.
For median instead of mean we have triangle A124943, high A124944.
Column k = 2 is A363745.
For median instead of mean we have rank statistic A363941, high A363942.
The rank statistic for this triangle is A363943.
The high version is A363946, rank statistic A363944.
For mode instead of mean we have A363952, rank statistic A363486.
For high mode instead of mean we have A363953, rank statistic A363487.
A008284 counts partitions by length, A058398 by mean.
A051293 counts subsets with integer mean, median A000975.
A067538 counts partitions with integer mean, strict A102627, ranks A316413.
A349156 counts partitions with non-integer mean, ranks A348551.

Programs

  • Mathematica
    meandown[y_]:=If[Length[y]==0,0,Floor[Mean[y]]];
    Table[Length[Select[IntegerPartitions[n],meandown[#]==k&]],{n,0,15},{k,0,n}]

A363953 Number of integer partitions of n with high mode k.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 2, 1, 1, 1, 0, 3, 1, 1, 1, 1, 0, 4, 2, 2, 1, 1, 1, 0, 7, 2, 1, 2, 1, 1, 1, 0, 9, 4, 2, 2, 2, 1, 1, 1, 0, 13, 6, 2, 2, 2, 2, 1, 1, 1, 0, 18, 7, 4, 3, 3, 2, 2, 1, 1, 1, 0, 26, 10, 5, 2, 3, 3, 2, 2, 1, 1, 1
Offset: 0

Views

Author

Gus Wiseman, Jul 07 2023

Keywords

Comments

A mode in a multiset is an element that appears at least as many times as each of the others. For example, the modes in {a,a,b,b,b,c,d,d,d} are {b,d}.
Extending the terminology of A124944, the "high mode" in a multiset is the greatest mode.

Examples

			Triangle begins:
  1
  0  1
  0  1  1
  0  1  1  1
  0  2  1  1  1
  0  3  1  1  1  1
  0  4  2  2  1  1  1
  0  7  2  1  2  1  1  1
  0  9  4  2  2  2  1  1  1
  0 13  6  2  2  2  2  1  1  1
  0 18  7  4  3  3  2  2  1  1  1
  0 26 10  5  2  3  3  2  2  1  1  1
  0 32 15  8  4  4  4  3  2  2  1  1  1
  0 47 19  9  5  3  4  4  3  2  2  1  1  1
  0 60 26 13  7  5  5  5  4  3  2  2  1  1  1
  0 79 34 18 10  6  5  5  5  4  3  2  2  1  1  1
Row n = 9 counts the following partitions:
  .  (711)        (522)     (333)   (441)  (54)   (63)   (72)  (81)  (9)
     (6111)       (4221)    (3321)  (432)  (531)  (621)
     (5211)       (3222)
     (51111)      (32211)
     (4311)       (22221)
     (42111)      (222111)
     (411111)
     (33111)
     (321111)
     (3111111)
     (2211111)
     (21111111)
     (111111111)
		

Crossrefs

Row sums are A000041.
For median: A124944 (low A124943), rank statistic A363942 (low A363941).
Column k = 1 is A241131 (partitions w/ high mode 1), ranks A360013, A360015.
The rank statistic for this triangle is A363487, low A363486.
For mean: A363946 (low A363945), rank statistic A363944 (low A363943).
The low version is A363952.
A008284 counts partitions by length, A058398 by mean.
A362612 counts partitions (max part) = (unique mode), ranks A362616.
A362614 counts partitions by number of modes, rank statistic A362611.
A362615 counts partitions by number of co-modes, rank statistic A362613.

Programs

  • Mathematica
    modes[ms_]:=Select[Union[ms],Count[ms,#]>=Max@@Length/@Split[ms]&];
    Table[Length[Select[IntegerPartitions[n], If[Length[#]==0,0,Last[modes[#]]]==k&]],{n,0,15},{k,0,n}]

A364191 Low co-mode in the multiset of prime indices of n.

Original entry on oeis.org

0, 1, 2, 1, 3, 1, 4, 1, 2, 1, 5, 2, 6, 1, 2, 1, 7, 1, 8, 3, 2, 1, 9, 2, 3, 1, 2, 4, 10, 1, 11, 1, 2, 1, 3, 1, 12, 1, 2, 3, 13, 1, 14, 5, 3, 1, 15, 2, 4, 1, 2, 6, 16, 1, 3, 4, 2, 1, 17, 2, 18, 1, 4, 1, 3, 1, 19, 7, 2, 1, 20, 2, 21, 1, 2, 8, 4, 1, 22, 3, 2, 1
Offset: 1

Views

Author

Gus Wiseman, Jul 16 2023

Keywords

Comments

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.
We define a co-mode in a multiset to be an element that appears at most as many times as each of the others. For example, the co-modes in {a,a,b,b,b,c,c} are {a,c}.
Extending the terminology of A124943, the "low co-mode" in a multiset is the least co-mode.

Examples

			The prime indices of 2100 are {1,1,2,3,3,4}, with co-modes {2,4}, so a(2100) = 2.
		

Crossrefs

For prime factors instead of indices we have A067695, high A359612.
For mode instead of co-mode we have A363486, high A363487, triangle A363952.
For median instead of co-mode we have A363941, high A363942.
Positions of 1's are A364158, counted by A364159.
The high version is A364192 = positions of 1's in A364061.
A112798 lists prime indices, length A001222, sum A056239.
A362611 counts modes in prime indices, triangle A362614.
A362613 counts co-modes in prime indices, triangle A362615.
Ranking and counting partitions:
- A356862 = unique mode, counted by A362608
- A359178 = unique co-mode, counted by A362610
- A362605 = multiple modes, counted by A362607
- A362606 = multiple co-modes, counted by A362609

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    comodes[ms_]:=Select[Union[ms],Count[ms,#]<=Min@@Length/@Split[ms]&];
    Table[If[n==1,0,Min[comodes[prix[n]]]],{n,30}]

Formula

a(n) = A000720(A067695(n)).
A067695(n) = A000040(a(n)).

A364192 High (i.e., greatest) co-mode in the multiset of prime indices of n.

Original entry on oeis.org

0, 1, 2, 1, 3, 2, 4, 1, 2, 3, 5, 2, 6, 4, 3, 1, 7, 1, 8, 3, 4, 5, 9, 2, 3, 6, 2, 4, 10, 3, 11, 1, 5, 7, 4, 2, 12, 8, 6, 3, 13, 4, 14, 5, 3, 9, 15, 2, 4, 1, 7, 6, 16, 1, 5, 4, 8, 10, 17, 3, 18, 11, 4, 1, 6, 5, 19, 7, 9, 4, 20, 2, 21, 12, 2, 8, 5, 6, 22, 3, 2
Offset: 1

Views

Author

Gus Wiseman, Jul 16 2023

Keywords

Comments

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.
We define a co-mode in a multiset to be an element that appears at most as many times as each of the others. For example, the co-modes in {a,a,b,b,b,c,c} are {a,c}.
Extending the terminology of A124943, the "high co-mode" in a multiset is the greatest co-mode.

Examples

			The prime indices of 2100 are {1,1,2,3,3,4}, with co-modes {2,4}, so a(2100) = 4.
		

Crossrefs

For prime factors instead of indices we have A359612, low A067695.
For mode instead of co-mode we have A363487 (triangle A363953), low A363486 (triangle A363952).
The version for median instead of co-mode is A363942, low A363941.
Positions of 1's are A364061, counted by A364062.
The low version is A364191, 1's at A364158 (counted by A364159).
A112798 lists prime indices, length A001222, sum A056239.
A362611 counts modes in prime indices, triangle A362614.
A362613 counts co-modes in prime indices, triangle A362615.
Ranking and counting partitions:
- A356862 = unique mode, counted by A362608
- A359178 = unique co-mode, counted by A362610
- A362605 = multiple modes, counted by A362607
- A362606 = multiple co-modes, counted by A362609

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    comodes[ms_]:=Select[Union[ms],Count[ms,#]<=Min@@Length/@Split[ms]&];
    Table[If[n==1,0,Max[comodes[prix[n]]]],{n,30}]

Formula

a(n) = A000720(A359612(n)).
A359612(n) = A000040(a(n)).

A364193 Number of integer partitions of n where the least part is the unique mode.

Original entry on oeis.org

0, 1, 2, 2, 4, 4, 7, 9, 13, 17, 24, 32, 43, 58, 75, 97, 130, 167, 212, 274, 346, 438, 556, 695, 865, 1082, 1342, 1655, 2041, 2511, 3067, 3756, 4568, 5548, 6728, 8130, 9799, 11810, 14170, 16980, 20305, 24251, 28876, 34366, 40781, 48342, 57206, 67597, 79703
Offset: 0

Views

Author

Gus Wiseman, Jul 16 2023

Keywords

Comments

A mode in a multiset is an element that appears at least as many times as each of the others. For example, the modes in {a,a,b,b,b,c,d,d,d} are {b,d}.

Examples

			The a(1) = 1 through a(8) = 13 partitions:
  (1)  (2)   (3)    (4)     (5)      (6)       (7)        (8)
       (11)  (111)  (22)    (311)    (33)      (322)      (44)
                    (211)   (2111)   (222)     (511)      (422)
                    (1111)  (11111)  (411)     (3211)     (611)
                                     (3111)    (4111)     (2222)
                                     (21111)   (22111)    (4211)
                                     (111111)  (31111)    (5111)
                                               (211111)   (32111)
                                               (1111111)  (41111)
                                                          (221111)
                                                          (311111)
                                                          (2111111)
                                                          (11111111)
		

Crossrefs

For greatest part and multiple modes we have A171979.
Allowing multiple modes gives A240303.
For greatest instead of least part we have A362612, ranks A362616.
For mean instead of least part we have A363723.
These partitions have ranks A364160.
A000041 counts integer partitions.
A362611 counts modes in prime factorization, A362613 co-modes.
A362614 counts partitions by number of modes, co-modes A362615.
A363486 gives least mode in prime indices, A363487 greatest.
A363952 counts partitions by low mode, A363953 high.
Ranking and counting partitions:
- A356862 = unique mode, counted by A362608
- A359178 = unique co-mode, counted by A362610
- A362605 = multiple modes, counted by A362607
- A362606 = multiple co-modes, counted by A362609

Programs

  • Mathematica
    Table[If[n==0,0,Length[Select[IntegerPartitions[n], Last[Length/@Split[#]]>Max@@Most[Length/@Split[#]]&]]],{n,0,30}]

A364060 Triangle read by rows where T(n,k) is the number of integer partitions of n with rounded mean k.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 2, 2, 0, 1, 0, 2, 4, 0, 0, 1, 0, 2, 5, 3, 0, 0, 1, 0, 4, 7, 0, 3, 0, 0, 1, 0, 4, 8, 5, 4, 0, 0, 0, 1, 0, 4, 14, 7, 4, 0, 0, 0, 0, 1, 0, 7, 21, 8, 0, 5, 0, 0, 0, 0, 1, 0, 7, 22, 11, 10, 0, 5, 0, 0, 0, 0, 1
Offset: 0

Views

Author

Gus Wiseman, Jul 07 2023

Keywords

Comments

We use the "rounding half to even" rule, see link.

Examples

			Triangle begins:
  1
  0  1
  0  1  1
  0  1  1  1
  0  2  2  0  1
  0  2  4  0  0  1
  0  2  5  3  0  0  1
  0  4  7  0  3  0  0  1
  0  4  8  5  4  0  0  0  1
  0  4 14  7  4  0  0  0  0  1
  0  7 21  8  0  5  0  0  0  0  1
  0  7 22 11 10  0  5  0  0  0  0  1
  0  7 36 15 12  0  6  0  0  0  0  0  1
  0 12 32 36 14  0  6  0  0  0  0  0  0  1
  0 12 53 23 23 16  0  7  0  0  0  0  0  0  1
  0 12 80 30 27 19  0  0  7  0  0  0  0  0  0  1
Row n = 7 counts the following partitions:
  .  (31111)    (511)   .  (61)  .  .  (7)
     (22111)    (421)      (52)
     (211111)   (4111)     (43)
     (1111111)  (331)
                (322)
                (3211)
                (2221)
		

Crossrefs

Row sums are A000041.
The rank statistic for this triangle is A363489.
The version for low mean is A363945, rank statistic A363943.
The version for high mean is A363946, rank statistic A363944.
Column k = 1 is A363947 (A026905 tripled).
A008284 counts partitions by length, A058398 by mean.
A026905 redoubled counts partitions with high mean 2, ranks A363950.
A051293 counts subsets with integer mean, median A000975.
A067538 counts partitions with integer mean, strict A102627, ranks A316413.
More triangles: A124943, A124944, A363952, A363953.

Programs

  • Mathematica
    Table[If[n==k==0,1,Length[Select[IntegerPartitions[n], Round[Mean[#]]==k&]]],{n,0,15},{k,0,n}]
Showing 1-9 of 9 results.