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 31-39 of 39 results.

A173304 Triangle generated from the array in A173302 (partition numbers starting new rows at n = 1, 3, 7, 15, ...).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 2, 3, 2, 4, 4, 3, 4, 6, 4, 7, 8, 6, 1, 8, 11, 9, 2, 12, 15, 12, 3, 14, 20, 17, 5, 21, 26, 23, 7, 24, 35, 31, 11, 34, 45, 41, 15, 41, 58, 55, 21, 1, 55, 75, 71, 29, 1, 66, 96, 93, 40, 2, 88, 121, 120, 53, 3, 105, 154, 154, 72, 5, 137, 193, 196, 94, 7
Offset: 0

Views

Author

Gary W. Adamson, Feb 15 2010

Keywords

Comments

Row sums = A000041, the partition numbers.

Examples

			The finite difference array starts:
  1, 1, 1, 1, 2, 2, 4, 4, 7,  8, 12, 14, 21, 24, ...; = A002865 (a variant)
        1, 1, 2, 3, 4, 6, 8, 11, 15, 20, 26, 35, ...; = A027336
           1, 1, 2, 3, 4, 6,  9, 12, 17, 23, 31, ...; = A017338
                       1, 1,  2,  3,  5,  7, 11, ...; = A027342
  ...
Last, columns of the array become rows of triangle A173304:
    1;
    1;
    1,   1;
    2,   2,   1;
    2,   3,   2;
    4,   4,   3;
    4,   6,   4,  1;
    7,   8,   6,  1;
    8,  11,   9,  2;
   12,  15,  12,  3;
   14,  20,  17,  5;
   21,  26,  23,  7;
   24,  35,  31, 11;
   34,  45,  41, 15;
   41,  58,  55, 21, 1;
   55,  75,  71, 29, 1;
   66,  96,  93, 40, 2;
   88, 121, 120, 53, 3;
  105, 154, 154, 72, 5;
  137, 193, 196, 94, 7;
  ...
		

Crossrefs

Formula

The generating array is in A173302.
1, 1, 2, 3, 5, 7, 11, 15, 22, 30, 42, 56, 77, 101, 135, 176, ...
1, 1, 2, 3, 5, 7, 11, 15, 22, 30, 42, 56, 77, 101, 135, ...
1, 1, 2, 3, 5, 7, 11, 15, 22, 30, 42, 56, 77, ...
1, 1, 2, 3, 5, 7, 11, 15, 22, ...
1, ...
...
Take finite differences from the bottom, creating a new array in which rows are A002865 (a slight variant), A027336, A027338, A027342, ...; i.e., the numbers of partitions of n that do not contain (1, 2, 4, 8, ...) as a part.

A238495 Number of partitions p of n such that min(p) + (number of parts of p) is not a part of p.

Original entry on oeis.org

1, 2, 3, 4, 7, 9, 14, 19, 27, 36, 51, 66, 90, 118, 156, 201, 264, 336, 434, 550, 700, 880, 1112, 1385, 1733, 2149, 2666, 3283, 4049, 4956, 6072, 7398, 9009, 10922, 13237, 15970, 19261, 23147, 27790, 33260, 39776, 47425, 56497, 67133, 79685, 94371, 111653
Offset: 1

Views

Author

Clark Kimberling, Feb 27 2014

Keywords

Comments

Also the number of integer partitions of n + 1 with median > 1, or with no more 1's than non-1 parts. - Gus Wiseman, Jul 10 2023

Examples

			a(6) = 9 counts all the 11 partitions of 6 except 42 and 411.
From _Gus Wiseman_, Jul 10 2023 (Start)
The a(2) = 1 through a(8) = 14 partitions:
  (2)  (3)   (4)   (5)    (6)     (7)     (8)
       (21)  (22)  (32)   (33)    (43)    (44)
             (31)  (41)   (42)    (52)    (53)
                   (221)  (51)    (61)    (62)
                          (222)   (322)   (71)
                          (321)   (331)   (332)
                          (2211)  (421)   (422)
                                  (2221)  (431)
                                  (3211)  (521)
                                          (2222)
                                          (3221)
                                          (3311)
                                          (4211)
                                          (22211)
(End)
		

Crossrefs

Cf. A096373.
For mean instead of median we have A000065, ranks A057716.
The complement is counted by A027336, ranks A364056.
Rows sums of A359893 if we remove the first column.
These partitions have ranks A364058.
A000041 counts integer partitions.
A008284 counts partitions by length, A058398 by mean.
A025065 counts partitions with low mean 1, ranks A363949.
A124943 counts partitions by low median, high A124944.
A241131 counts partitions with low mode 1, ranks A360015.

Programs

  • Mathematica
    Table[Count[IntegerPartitions[n], p_ /; ! MemberQ[p, Length[p] + Min[p]]], {n, 50}]
    Table[Length[Select[IntegerPartitions[n+1],Median[#]>1&]],{n,30}] (* Gus Wiseman, Jul 10 2023 *)

Formula

From Gus Wiseman, Jul 11 2023: (Start)
a(n>2) = A000041(n) - A096373(n-2).
a(n>1) = A000041(n-2) + A002865(n+1).
a(n) = A000041(n+1) - A027336(n).
(End)

Extensions

Formula corrected by Gus Wiseman, Jul 11 2023

A354909 Number of integer compositions of n that are not the run-sums of any other composition.

Original entry on oeis.org

0, 0, 1, 1, 3, 7, 16, 33, 74, 155, 329, 688, 1439, 2975, 6154, 12654, 25964, 53091, 108369, 220643, 448520
Offset: 0

Views

Author

Gus Wiseman, Jun 19 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).

Examples

			The a(0) = 0 through a(6) = 16 compositions:
  .  .  (11)  (111)  (112)   (113)    (114)
                     (211)   (311)    (411)
                     (1111)  (1112)   (1113)
                             (1121)   (1122)
                             (1211)   (1131)
                             (2111)   (1221)
                             (11111)  (1311)
                                      (2112)
                                      (2211)
                                      (3111)
                                      (11112)
                                      (11121)
                                      (11211)
                                      (12111)
                                      (21111)
                                      (111111)
		

Crossrefs

The version for binary words is A000918, complement A000126.
These compositions are ranked by A354904 = positions of zeros in A354578.
The complement is counted by A354910, ranked by A354912.
A003242 counts anti-run compositions, ranked by A333489.
A238279 and A333755 count compositions by number of runs.
A353851 counts compositions with all equal run-sums, ranked by A353848.
A353853-A353859 pertain to composition run-sum trajectory.
A353932 lists run-sums of standard compositions, rows ranked by A353847.

Programs

  • Mathematica
    Table[Length[Complement[Join@@Permutations/@IntegerPartitions[n], Total/@Split[#]&/@Join@@Permutations/@IntegerPartitions[n]]],{n,0,15}]

A354910 Number of compositions of n that are the run-sums of some other composition.

Original entry on oeis.org

1, 1, 1, 3, 5, 9, 16, 31, 54, 101, 183, 336, 609, 1121, 2038, 3730, 6804, 12445, 22703, 41501, 75768
Offset: 0

Views

Author

Gus Wiseman, Jun 20 2022

Keywords

Comments

Every sequence can be uniquely split into a sequence of non-overlapping runs. For example, the runs of (2,2,1,1,1,3,2,2) are ((2,2),(1,1,1),(3),(2,2)), with sums (4,3,3,4).

Examples

			The a(0) = 0 through a(6) = 16 compositions:
  ()  (1)  (2)  (3)   (4)    (5)    (6)
                (12)  (13)   (14)   (15)
                (21)  (22)   (23)   (24)
                      (31)   (32)   (33)
                      (121)  (41)   (42)
                             (122)  (51)
                             (131)  (123)
                             (212)  (132)
                             (221)  (141)
                                    (213)
                                    (222)
                                    (231)
                                    (312)
                                    (321)
                                    (1212)
                                    (2121)
		

Crossrefs

The version for binary words is A000126, complement A000918
The complement is counted by A354909, ranked by A354904.
These compositions are ranked by A354912 = nonzeros of A354578.
A003242 counts anti-run compositions, ranked by A333489.
A238279 and A333755 count compositions by number of runs.
A353851 counts compositions with all equal run-sums, ranked by A353848.
A353853-A353859 pertain to composition run-sum trajectory.
A353932 lists run-sums of standard compositions, rows ranked by A353847.

Programs

  • Mathematica
    Table[Length[Union[Total/@Split[#]&/@ Join@@Permutations/@IntegerPartitions[n]]],{n,0,15}]

A116599 Triangle read by rows: T(n,k) is the number of partitions of n having exactly k parts equal to 2 (n>=0, 0<=k<=floor(n/2)).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 3, 1, 1, 4, 2, 1, 6, 3, 1, 1, 8, 4, 2, 1, 11, 6, 3, 1, 1, 15, 8, 4, 2, 1, 20, 11, 6, 3, 1, 1, 26, 15, 8, 4, 2, 1, 35, 20, 11, 6, 3, 1, 1, 45, 26, 15, 8, 4, 2, 1, 58, 35, 20, 11, 6, 3, 1, 1, 75, 45, 26, 15, 8, 4, 2, 1, 96, 58, 35, 20, 11, 6, 3, 1, 1, 121, 75, 45, 26, 15, 8, 4, 2, 1
Offset: 0

Views

Author

Emeric Deutsch, Feb 18 2006

Keywords

Comments

Row n has 1 + floor(n/2) terms.
Row sums are the partition numbers (A000041).

Examples

			T(6,1)=3 because we have [4,2], [3,2,1] and [2,1,1,1,1].
Triangle starts:
1;
1;
1,1;
2,1;
3,1,1;
4,2,1;
6,3,1,1;
8,4,2,1;
		

Crossrefs

Programs

  • Maple
    with(combinat): T:=proc(n,k) if k=floor(n/2) then 1 elif k<=(n-2)/2 then numbpart(n-2*k)-numbpart(n-2*k-2) fi end: for n from 0 to 18 do seq(T(n,k),k=0..n) od; # yields sequence in triangular form
  • Mathematica
    nn = 20; p = Product[1/(1 - x^i), {i, 3, nn}]; f[list_] := Select[list, # > 0 &]; Map[f, CoefficientList[Series[p /(1 - x)/(1 - y x^2), {x, 0, nn}], {x, y}]] // Flatten  (* Geoffrey Critzer, Jan 22 2012 *)

Formula

T(n,0) = A027336(n), Sum_{k=0..floor(n/2)} k*T(n,k) = A024786(n).
Column k has g.f.: x^(2*k)/[(1-x)*Product_{j>=0} ((1-x^j))] (k=0,1,2,...).
G.f.: 1/[(1-x)*(1-t*x^2)*Product_{j>=3}( (1-x^j) )].
T(n,k) = p(n-2*k) - p(n-2*k-2) for k<=(n-2)/2;
T(n, floor(n/2))=1 (follows at once from the g.f.).

Extensions

Keyword tabl changed to tabf by Michel Marcus, Apr 09 2013

A121081 Number of partitions of n into parts with at most one 1 and at most one 2.

Original entry on oeis.org

1, 1, 2, 2, 3, 5, 6, 8, 11, 14, 18, 24, 30, 38, 49, 61, 76, 96, 118, 146, 181, 221, 270, 331, 401, 486, 589, 709, 852, 1025, 1225, 1463, 1746, 2075, 2463, 2922, 3453, 4077, 4808, 5656, 6644, 7798, 9130, 10678, 12475, 14547, 16942, 19714, 22898, 26570, 30798
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 11 2006

Keywords

Comments

a(n) is also the number of partitions of n with no part equal to 2 or 4. [From Shanzhen Gao, Oct 28 2010]

Examples

			a(8)=#{8,7+1,6+2,5+3,5+2+1,4+4,4+3+1,3+3+2}=8;
a(9)=#{9,8+1,7+2,6+3,6+2+1,5+4,5+3+1,4+4+1,4+3+2,3+3+3,3+3+2+1}=11.
		

Crossrefs

Cf. A027336.

Formula

a(n) = A121659(n) + A008483(n-3) for n>2. - Reinhard Zumkeller, Aug 14 2006
G.f.: (1+x)*(1+x^2)/Product_{k>=3} (1-x^k). - Vladeta Jovovic, Aug 13 2006
a(n) = A000041(n)-A000041(n-2)-A000041(n-4)+A000041(n-6), n>5. - Vladeta Jovovic, Aug 13 2006
Given by p(n)-p(n-2)-p(n-4)+p(n-6) where p(n)=A000041(n). - Shanzhen Gao, Oct 28 2010
a(n) ~ exp(Pi*sqrt(2*n/3)) * Pi^2 / (3^(3/2) * n^2). - Vaclav Kotesovec, Jun 02 2018

A300185 Irregular triangle read by rows: T(n, {j,k}) is the number of partitions of n that have exactly j parts equal to k; 1 <= j <= n, 1 <= k <= n.

Original entry on oeis.org

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

Views

Author

J. Stauduhar, Feb 27 2018

Keywords

Comments

Row sums = A027293.
If superfluous zeros are removed from the right side of each row, the row lengths = 1,2,1,3,1,1,4,2,... = A010766.
Sum of each N X N block of rows = 1,2,4,7,12,19,... = A000070.
The sum of the partitions of n that are over-counted in each block of N x N rows = A000070(n) - A000041(n) = A058884(n), n >= 1.
Concatenation of first row from each N X N block = A116598.
As noted by Joerg Arndt in A116598, the first row from each N X N block in reverse converges to A002865. Two sequences emerge from alternating second rows in reverse: for 2n, converges to even-indexed terms in A027336, and for 2n+1, converges to odd-indexed terms in A027336.
Counting the rows in each N X N block where columns j=2 > 0 and j=3 through j=n are all zeros produces A008615(n), n > 0.

Examples

			      \ j  1 2 3 4 5
     k
n
1:   1     1
2:   1     0 1
     2     1 0
3:   1     1 0 1
     2     1 0 0
     3     1 0 0
4:   1     1 1 0 1
     2     1 1 0 0
     3     1 0 0 0
     4     1 0 0 0
5:   1     2 1 1 0 1
     2     2 1 0 0 0
     3     2 0 0 0 0
     4     1 0 0 0 0
     5     1 0 0 0 0
.
.
.
		

Crossrefs

Programs

  • Mathematica
    Array[With[{s = IntegerPartitions[#]}, Table[Count[Map[Count[#, k] &, s], j], {k, #}, {j, #}]] &, 7] // Flatten (* Michael De Vlieger, Feb 28 2018 *)
  • Python
    # See Stauduhar link.

A364058 Heinz numbers of integer partitions with median > 1. Numbers whose multiset of prime factors has median > 2.

Original entry on oeis.org

3, 5, 6, 7, 9, 10, 11, 13, 14, 15, 17, 18, 19, 21, 22, 23, 25, 26, 27, 29, 30, 31, 33, 34, 35, 36, 37, 38, 39, 41, 42, 43, 45, 46, 47, 49, 50, 51, 53, 54, 55, 57, 58, 59, 60, 61, 62, 63, 65, 66, 67, 69, 70, 71, 73, 74, 75, 77, 78, 79, 81, 82, 83, 84, 85, 86
Offset: 1

Views

Author

Gus Wiseman, Jul 14 2023

Keywords

Comments

The Heinz number of a partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). This gives a bijective correspondence between positive integers and integer partitions.
The median of a multiset is either the middle part (for odd length), or the average of the two middle parts (for even length).

Examples

			The terms together with their prime indices begin:
     3: {2}        23: {9}          42: {1,2,4}
     5: {3}        25: {3,3}        43: {14}
     6: {1,2}      26: {1,6}        45: {2,2,3}
     7: {4}        27: {2,2,2}      46: {1,9}
     9: {2,2}      29: {10}         47: {15}
    10: {1,3}      30: {1,2,3}      49: {4,4}
    11: {5}        31: {11}         50: {1,3,3}
    13: {6}        33: {2,5}        51: {2,7}
    14: {1,4}      34: {1,7}        53: {16}
    15: {2,3}      35: {3,4}        54: {1,2,2,2}
    17: {7}        36: {1,1,2,2}    55: {3,5}
    18: {1,2,2}    37: {12}         57: {2,8}
    19: {8}        38: {1,8}        58: {1,10}
    21: {2,4}      39: {2,6}        59: {17}
    22: {1,5}      41: {13}         60: {1,1,2,3}
		

Crossrefs

For mean instead of median we have A057716, counted by A000065.
These partitions are counted by A238495.
The complement is A364056, counted by A027336, low version A363488.
A000975 counts subsets with integer median, A051293 for mean.
A124943 counts partitions by low median, high version A124944.
A360005 gives twice the median of prime indices, A360459 for prime factors.
A359893 and A359901 count partitions by median.

Programs

  • Mathematica
    prifacs[n_]:=If[n==1,{},Flatten[ConstantArray@@@FactorInteger[n]]];
    Select[Range[100],Median[prifacs[#]]>2&]

Formula

A360005(a(n)) > 1.
A360459(a(n)) > 2.

A367108 Triangle read by rows where T(n,k) is the number of integer partitions of n with a unique submultiset summing to k.

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 3, 2, 2, 3, 5, 3, 2, 3, 5, 7, 5, 4, 4, 5, 7, 11, 7, 6, 3, 6, 7, 11, 15, 11, 8, 7, 7, 8, 11, 15, 22, 15, 12, 10, 4, 10, 12, 15, 22, 30, 22, 16, 14, 12, 12, 14, 16, 22, 30, 42, 30, 22, 17, 17, 6, 17, 17, 22, 30, 42, 56, 42, 30, 25, 23, 20, 20, 23, 25, 30, 42, 56
Offset: 1

Views

Author

Gus Wiseman, Nov 18 2023

Keywords

Examples

			Triangle begins:
   1
   1   1
   2   1   2
   3   2   2   3
   5   3   2   3   5
   7   5   4   4   5   7
  11   7   6   3   6   7  11
  15  11   8   7   7   8  11  15
  22  15  12  10   4  10  12  15  22
  30  22  16  14  12  12  14  16  22  30
  42  30  22  17  17   6  17  17  22  30  42
  56  42  30  25  23  20  20  23  25  30  42  56
  77  56  40  31  30  27   7  27  30  31  40  56  77
Row n = 5 counts the following partitions:
  (5)      (41)     (32)     (32)     (41)     (5)
  (41)     (311)    (311)    (311)    (311)    (41)
  (32)     (221)    (221)    (221)    (221)    (32)
  (311)    (2111)   (11111)  (11111)  (2111)   (311)
  (221)    (11111)                    (11111)  (221)
  (2111)                                       (2111)
  (11111)                                      (11111)
Row n = 6 counts the following partitions:
  (6)       (51)      (42)      (33)      (42)      (51)      (6)
  (51)      (411)     (411)     (2211)    (411)     (411)     (51)
  (42)      (321)     (321)     (111111)  (321)     (321)     (42)
  (411)     (3111)    (3111)              (3111)    (3111)    (411)
  (33)      (2211)    (222)               (222)     (2211)    (33)
  (321)     (21111)   (111111)            (111111)  (21111)   (321)
  (3111)    (111111)                                (111111)  (3111)
  (222)                                                       (222)
  (2211)                                                      (2211)
  (21111)                                                     (21111)
  (111111)                                                    (111111)
		

Crossrefs

Columns k = 0 and k = n are A000041(n).
Column k = 1 and k = n-1 are A000041(n-1).
Column k = 2 appears to be 2*A027336(n).
The version for non-subset-sums is A046663, strict A365663.
Diagonal n = 2k is A108917, complement A366754.
Row sums are A304796, non-unique version A304792.
The non-unique version is A365543.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n], Count[Total/@Union[Subsets[#]], k]==1&]], {n,0,10}, {k,0,n}]

Formula

A367094(n,1) = A108917(n).
Previous Showing 31-39 of 39 results.