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-5 of 5 results.

A270236 Triangle T(n,p) read by rows: the number of occurrences of p in the restricted growth functions of length n.

Original entry on oeis.org

1, 3, 1, 9, 5, 1, 30, 21, 8, 1, 112, 88, 47, 12, 1, 463, 387, 253, 97, 17, 1, 2095, 1816, 1345, 675, 184, 23, 1, 10279, 9123, 7304, 4418, 1641, 324, 30, 1, 54267, 48971, 41193, 28396, 13276, 3645, 536, 38, 1, 306298, 279855, 243152, 183615, 102244, 36223, 7473, 842, 47, 1
Offset: 1

Views

Author

R. J. Mathar, Mar 13 2016

Keywords

Comments

The RG functions used here are defined by f(1)=1, f(j) <= 1+max_{i
T(n,p) is the number of elements in the p-th subset in all set partitions of [n]. - Joerg Arndt, Mar 14 2016

Examples

			The two restricted growth functions of length 2 are (1,1) and (1,2). The 1 appears 3 times and the 2 once, so T(2,1)=3 and T(2,2)=1.
1;
3,1;
9,5,1;
30,21,8,1;
112,88,47,12,1;
463,387,253,97,17,1;
2095,1816,1345,675,184,23,1;
10279,9123,7304,4418,1641,324,30,1;
54267,48971,41193,28396,13276,3645,536,38,1;
306298,279855,243152,183615,102244,36223,7473,842,47,1;
1838320,1695902,1506521,1211936,770989,334751,90223,14303,1267,57,1;
11677867,10856879,9799547,8237223,5795889,2965654,995191,207186,25820, 1839,68,1;
		

Crossrefs

Cf. A070071 (row sums).
T(2n+1,n+1) gives A270529.

Programs

  • Maple
    b:= proc(n, m) option remember; `if`(n=0, [1, 0], add((p->
          [p[1], p[2]+p[1]*x^j])(b(n-1, max(m, j))), j=1..m+1))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=1..n))(b(n, 0)[2]):
    seq(T(n), n=0..12);  # Alois P. Heinz, Mar 14 2016
  • Mathematica
    b[n_, m_] := b[n, m] = If[n == 0, {1, 0}, Sum[Function[p, {p[[1]], p[[2]] + p[[1]]*x^j}][b[n-1, Max[m, j]]], {j, 1, m+1}]];
    T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 1, n}]][b[n, 0][[2]] ]; Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, Apr 07 2016, after Alois P. Heinz *)

Formula

T(n,n) = 1.
Conjecture: T(n,n-1) = 2+n*(n-1)/2 for n>1.
Conjecture: T(n+1,n-1) = 2+n*(n+1)*(3*n^2-5*n+26)/24 for n>1.
Sum_{k=1..n} k * T(n,k) = A346772(n). - Alois P. Heinz, Aug 03 2021

A070071 a(n) = n*B(n), where B(n) are the Bell numbers, A000110.

Original entry on oeis.org

0, 1, 4, 15, 60, 260, 1218, 6139, 33120, 190323, 1159750, 7464270, 50563164, 359377681, 2672590508, 20744378175, 167682274352, 1408702786668, 12277382510862, 110822101896083, 1034483164707440, 9972266139291771, 99147746245841106, 1015496134666939958
Offset: 0

Author

Karol A. Penson, Apr 19 2002

Keywords

Comments

a(n) is the total number of successions among all partitions of {1,2,...,n+1}; a succession is a pair (i,i+1) of consecutive integers lying in a block. For example, a(3)=15 because {1,2,3,4} has 6 partitions with 1 succession - 1/2/34, 1/23/4, 12/3/4, 14/23, 134/2, 124/3, 3 partitions with 2 successions - 1/234, 123/4, 12/34 and 1 partition with 3 successions - 1234. Thus a(3) = 6*1 + 3*2 + 1*3 = 15. - Augustine O. Munagi, Jul 01 2008
a(n) is the number of occurrences of integers in a list of all partitions of the set {1,...,n}. For example, the list 123, 1/23, 2/13, 3/12, 1/2/3 of all partitions of the set {1,2,3} requires 15 occurrences of integers each belonging to that set. [From Michael Hardy (hardy(AT)math.umn.edu), Nov 08 2008]
The bijection between the two foregoing characterizations is as follows: Fix x in {1,2,...,n} and associate x with the succession (x,x+1) which appears in some partitions of {1,2,...,n+1}. Replace x,x+1 by x and partition the n-set {1,2,...,x,x+2,...,n+1}, giving B(n) partitions. Thus the succession (x,x+1) occurs among partitions of {1,2,...,n+1} exactly B(n) times. - Augustine O. Munagi, Jun 02 2010

Programs

  • Magma
    [n*Bell(n): n in [0..25]]; // Vincenzo Librandi, Mar 15 2014
  • Maple
    with(combinat): a:=n->sum(numbcomb (n,0)*bell(n), j=1..n): seq(a(n), n=0..21); # Zerinvary Lajos, Apr 25 2007
    with(combinat): a:=n->sum(bell(n), j=1..n): seq(a(n), n=0..21); # Zerinvary Lajos, Apr 25 2007
    a:=n->sum(sum(Stirling2(n, k), j=1..n), k=1..n): seq(a(n), n=0..21); # Zerinvary Lajos, Jun 28 2007
  • Mathematica
    a[n_] := n!*Coefficient[Series[x E^(E^x+x-1), {x, 0, n}], x, n]
    Table[Sum[BellB[n, 1], {i, 1, n}], {n, 0, 21}] (* Zerinvary Lajos, Jul 16 2009 *)
    Table[n*BellB[n], {n, 0, 20}] (* Vaclav Kotesovec, Mar 13 2014 *)
  • PARI
    a(n)=local(t); if(n<0,0,t=exp(x+O(x^n)); n!*polcoeff(x*t*exp(t-1),n))
    
  • Sage
    [bell_number(n)*n for n in range(22) ] # Zerinvary Lajos, Mar 14 2009
    

Formula

E.g.f: x*exp(x)*exp(exp(x)-1).
Sum_{k=1..n} n*binomial(n-1, k-1)*Bell(n-k), n >= 2. - Zerinvary Lajos, Nov 22 2006
a(n) ~ n^(n+1) * exp(n/LambertW(n)-1-n) / (sqrt(1+LambertW(n)) * LambertW(n)^n). - Vaclav Kotesovec, Mar 13 2014
a(n) = Sum_{k=1..n} k * A175757(n,k). - Alois P. Heinz, Mar 03 2020
a(n) = Sum_{j=0..n} n * Stirling2(n,j). - Detlef Meya, Apr 11 2024

A038561 Left-hand border of triangle A046937.

Original entry on oeis.org

1, 2, 3, 8, 24, 83, 324, 1400, 6609, 33758, 185136, 1083233, 6726366, 44130128, 304741623, 2207682188, 16729947276, 132281116715, 1088831511000, 9311082630620, 82569723552561, 758057178490082, 7194283782101844, 70481938088367569
Offset: 0

Keywords

Comments

For n>1: a(n) is the number of entries in the last blocks of all set partitions of [n]. a(3) = 8 because the number of entries in the last blocks of all set partitions of [3] (123, 12|3, 13|2, 1|23, 1|2|3) is 3+1+1+2+1 = 8. - Alois P. Heinz, May 08 2017

References

  • H. W. Gould, A linear binomial recurrence and the Bell numbers and polynomials, preprint, 1998

Crossrefs

A040027(n) + B(n), where B(n) = Bell numbers A000110.
Column k=1 of A286416 (for n>1).

Programs

  • Haskell
    a038561 = head . a046937_row  -- Reinhard Zumkeller, Jan 06 2014
  • Maple
    A038561List := proc(m) local A, P, n; A := [1,2]; P := [1];
    for n from 1 to m - 2 do P := ListTools:-PartialSums([A[-1], op(P)]);
    A := [op(A), P[-1]] od; A end: A038561List(24); # Peter Luschny, Mar 24 2022
  • Mathematica
    a[0, 0] = 1; a[1, 0] = 2; a[n_, 0] := a[n-1, n-1]; a[n_, k_] := a[n, k] = a[n, k-1] + a[n-1, k-1]; a[n_] := a[n, 0]; Table[a[n], {n, 0, 23}] (* Jean-François Alcover, Jun 06 2013 *)

Formula

G.f. A(x) satisfies: A(x) = 1 + x * (1 + A(x/(1 - x)) / (1 - x)). - Ilya Gutkovskiy, Jun 30 2020

A286232 Sum T(n,k) of the entries in the k-th last blocks of all set partitions of [n]; triangle T(n,k), n>=1, 1<=k<=n, read by rows.

Original entry on oeis.org

1, 5, 1, 19, 10, 1, 75, 57, 17, 1, 323, 285, 145, 26, 1, 1512, 1421, 975, 317, 37, 1, 7630, 7395, 5999, 2865, 616, 50, 1, 41245, 40726, 36183, 22411, 7315, 1094, 65, 1, 237573, 237759, 221689, 163488, 72581, 16630, 1812, 82, 1, 1451359, 1468162, 1405001, 1160764, 649723, 206249, 34425, 2840, 101, 1
Offset: 1

Author

Alois P. Heinz, May 04 2017

Keywords

Examples

			T(3,2) = 10 because the sum of the entries in the second last blocks of all set partitions of [3] (123, 12|3, 13|2, 1|23, 1|2|3) is 0+3+4+1+2 = 10.
Triangle T(n,k) begins:
      1;
      5,     1;
     19,    10,     1;
     75,    57,    17,     1;
    323,   285,   145,    26,    1;
   1512,  1421,   975,   317,   37,    1;
   7630,  7395,  5999,  2865,  616,   50,  1;
  41245, 40726, 36183, 22411, 7315, 1094, 65, 1;
  ...
		

Crossrefs

Column k=1 gives A285424.
Main diagonal and first lower diagonal give: A000012, A002522.
Row sums give A000110(n) * A000217(n) = A105488(n+3).

Programs

  • Mathematica
    app[P_, n_] := Module[{P0}, Table[P0 = Append[P, {}]; AppendTo[P0[[i]], n]; If[Last[P0] == {}, Most[P0], P0], {i, 1, Length[P]+1}]];
    setPartitions[n_] := setPartitions[n] = If[n == 1, {{{1}}}, Flatten[app[#, n]& /@ setPartitions[n-1], 1]];
    T[n_, k_] := Select[setPartitions[n], Length[#] >= k&][[All, -k]] // Flatten // Total;
    Table[T[n, k], {n, 1, 10}, {k, 1, n}] // Flatten (* Jean-François Alcover, Aug 21 2021 *)

A286433 Number of entries in the second last blocks of all set partitions of [n].

Original entry on oeis.org

1, 6, 25, 98, 399, 1746, 8271, 42284, 231939, 1357128, 8427181, 55288860, 381798629, 2765917074, 20960284277, 165729739590, 1364153612299, 11665484410094, 103448316470723, 949739632313480, 9013431476894623, 88304011710168668, 891917738589610553
Offset: 2

Author

Alois P. Heinz, May 09 2017

Keywords

Examples

			a(3) = 6 because the number of entries in the second last blocks of all set partitions of [3] (123, 12|3, 13|2, 1|23, 1|2|3) is 0+2+2+1+1 = 6.
		

Crossrefs

Column k=2 of A286416.
Showing 1-5 of 5 results.