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

A131689 Triangle of numbers T(n,k) = k!*Stirling2(n,k) = A000142(k)*A048993(n,k) read by rows, T(n, k) for 0 <= k <= n.

Original entry on oeis.org

1, 0, 1, 0, 1, 2, 0, 1, 6, 6, 0, 1, 14, 36, 24, 0, 1, 30, 150, 240, 120, 0, 1, 62, 540, 1560, 1800, 720, 0, 1, 126, 1806, 8400, 16800, 15120, 5040, 0, 1, 254, 5796, 40824, 126000, 191520, 141120, 40320, 0, 1, 510, 18150, 186480, 834120, 1905120, 2328480, 1451520, 362880
Offset: 0

Views

Author

Philippe Deléham, Sep 14 2007

Keywords

Comments

Triangle T(n,k), 0 <= k <= n, read by rows given by [0,1,0,2,0,3,0,4,0,5,0,6,0,7,0,...] DELTA [1,1,2,2,3,3,4,4,5,5,6,6,...] where DELTA is the operator defined in A084938; another version of A019538.
See also A019538: version with n > 0 and k > 0. - Philippe Deléham, Nov 03 2008
From Peter Bala, Jul 21 2014: (Start)
T(n,k) gives the number of (k-1)-dimensional faces in the interior of the first barycentric subdivision of the standard (n-1)-dimensional simplex. For example, the barycentric subdivision of the 1-simplex is o--o--o, with 1 interior vertex and 2 interior edges, giving T(2,1) = 1 and T(2,2) = 2.
This triangle is used when calculating the face vectors of the barycentric subdivision of a simplicial complex. Let S be an n-dimensional simplicial complex and write f_k for the number of k-dimensional faces of S, with the usual convention that f_(-1) = 1, so that F := (f_(-1), f_0, f_1,...,f_n) is the f-vector of S. If M(n) denotes the square matrix formed from the first n+1 rows and n+1 columns of the present triangle, then the vector F*M(n) is the f-vector of the first barycentric subdivision of the simplicial complex S (Brenti and Welker, Lemma 2.1). For example, the rows of Pascal's triangle A007318 (but with row and column indexing starting at -1) are the f-vectors for the standard n-simplexes. It follows that A007318*A131689, which equals A028246, is the array of f-vectors of the first barycentric subdivision of standard n-simplexes. (End)
This triangle T(n, k) appears in the o.g.f. G(n, x) = Sum_{m>=0} S(n, m)*x^m with S(n, m) = Sum_{j=0..m} j^n for n >= 1 as G(n, x) = Sum_{k=1..n} (x^k/(1 - x)^(k+2))*T(n, k). See also the Eulerian triangle A008292 with a Mar 31 2017 comment for a rewritten form. For the e.g.f. see A028246 with a Mar 13 2017 comment. - Wolfdieter Lang, Mar 31 2017
T(n,k) = the number of alignments of length k of n strings each of length 1. See Slowinski. An example is given below. Cf. A122193 (alignments of strings of length 2) and A299041 (alignments of strings of length 3). - Peter Bala, Feb 04 2018
The row polynomials R(n,x) are the Fubini polynomials. - Emanuele Munarini, Dec 05 2020
From Gus Wiseman, Feb 18 2022: (Start)
Also the number of patterns of length n with k distinct parts (or with maximum part k), where we define a pattern to be a finite sequence covering an initial interval of positive integers. For example, row n = 3 counts the following patterns:
(1,1,1) (1,2,2) (1,2,3)
(2,1,2) (1,3,2)
(2,2,1) (2,1,3)
(1,1,2) (2,3,1)
(1,2,1) (3,1,2)
(2,1,1) (3,2,1)
(End)
Regard A048994 as a lower-triangular matrix and divide each term A048994(n,k) by n!, then this is the matrix inverse. Because Sum_{k=0..n} (A048994(n,k) * x^n / n!) = A007318(x,n), Sum_{k=0..n} (A131689(n,k) * A007318(x,k)) = x^n. - Natalia L. Skirrow, Mar 23 2023
T(n,k) is the number of ordered partitions of [n] into k blocks. - Alois P. Heinz, Feb 21 2025

Examples

			The triangle T(n,k) begins:
  n\k 0 1    2     3      4       5        6        7        8        9      10 ...
  0:  1
  1:  0 1
  2:  0 1    2
  3:  0 1    6     6
  4:  0 1   14    36     24
  5:  0 1   30   150    240     120
  6:  0 1   62   540   1560    1800      720
  7:  0 1  126  1806   8400   16800    15120     5040
  8:  0 1  254  5796  40824  126000   191520   141120    40320
  9:  0 1  510 18150 186480  834120  1905120  2328480  1451520   362880
  10: 0 1 1022 55980 818520 5103000 16435440 29635200 30240000 16329600 3628800
  ... reformatted and extended. - _Wolfdieter Lang_, Mar 31 2017
From _Peter Bala_, Feb 04 2018: (Start)
T(4,2) = 14 alignments of length 2 of 4 strings of length 1. Examples include
  (i) A -    (ii) A -    (iii) A -
      B -         B -          - B
      C -         - C          - C
      - D         - D          - D
There are C(4,1) = 4 alignments of type (i) with a single gap character - in column 1, C(4,2) = 6 alignments of type (ii) with two gap characters in column 1 and C(4,3) = 4 alignments of type (iii) with three gap characters in column 1, giving a total of 4 + 6 + 4 = 14 alignments. (End)
		

Crossrefs

Case m=1 of the polynomials defined in A278073.
Cf. A000142 (diagonal), A000670 (row sums), A000012 (alternating row sums), A210029 (central terms).
Cf. A008292, A028246 (o.g.f. and e.g.f. of sums of powers).
A version for partitions is A116608, or by maximum A008284.
A version for compositions is A235998, or by maximum A048004.
Classes of patterns:
- A000142 = strict
- A005649 = anti-run, complement A069321
- A019536 = necklace
- A032011 = distinct multiplicities
- A060223 = Lyndon
- A226316 = (1,2,3)-avoiding, weakly A052709, complement A335515
- A296975 = aperiodic
- A345194 = alternating, up/down A350354, complement A350252
- A349058 = weakly alternating
- A351200 = distinct runs
- A351292 = distinct run-lengths

Programs

  • Julia
    function T(n, k)
        if k < 0 || k > n return 0 end
        if n == 0 && k == 0 return 1 end
        k*(T(n-1, k-1) + T(n-1, k))
    end
    for n in 0:7
        println([T(n, k) for k in 0:n])
    end
    # Peter Luschny, Mar 26 2020
    
  • Maple
    A131689 := (n,k) -> Stirling2(n,k)*k!: # Peter Luschny, Sep 17 2011
    # Alternatively:
    A131689_row := proc(n) 1/(1-t*(exp(x)-1)); expand(series(%,x,n+1)); n!*coeff(%,x,n); PolynomialTools:-CoefficientList(%,t) end:
    for n from 0 to 9 do A131689_row(n) od; # Peter Luschny, Jan 23 2017
  • Mathematica
    t[n_, k_] := k!*StirlingS2[n, k]; Table[t[n, k], {n, 0, 9}, {k, 0, n}] // Flatten (* Jean-François Alcover, Feb 25 2014 *)
    T[n_, k_] := If[n <= 0 || k <= 0, Boole[n == 0 && k == 0], Sum[(-1)^(i + k) Binomial[k, i] i^(n + k), {i, 0, k}]]; (* Michael Somos, Jul 08 2018 *)
  • PARI
    {T(n, k) = if( n<0, 0, sum(i=0, k, (-1)^(k + i) * binomial(k, i) * i^n))};
    /* Michael Somos, Jul 08 2018 */
    
  • SageMath
    @cached_function
    def F(n): # Fubini polynomial
        R. = PolynomialRing(ZZ)
        if n == 0: return R(1)
        return R(sum(binomial(n, k)*F(n - k)*x for k in (1..n)))
    for n in (0..9): print(F(n).list()) # Peter Luschny, May 21 2021

Formula

T(n,k) = k*(T(n-1,k-1) + T(n-1,k)) with T(0,0)=1. Sum_{k=0..n} T(n,k)*x^k = (-1)^n*A000629(n), A033999(n), A000007(n), A000670(n), A004123(n+1), A032033(n), A094417(n), A094418(n), A094419(n) for x = -2, -1, 0, 1, 2, 3, 4, 5, 6 respectively. [corrected by Philippe Deléham, Feb 11 2013]
Sum_{k=0..n} T(n,k)*x^(n-k) = A000012(n), A000142(n), A000670(n), A122704(n) for x=-1, 0, 1, 2 respectively. - Philippe Deléham, Oct 09 2007
Sum_{k=0..n} (-1)^k*T(n,k)/(k+1) = Bernoulli numbers A027641(n)/A027642(n). - Peter Luschny, Sep 17 2011
G.f.: F(x,t) = 1 + x*t + (x+x^2)*t^2/2! + (x+6*x^2+6*x^3)*t^3/3! + ... = Sum_{n>=0} R(n,x)*t^n/n!.
The row polynomials R(n,x) satisfy the recursion R(n+1,x) = (x+x^2)*R'(n,x) + x*R(n,x) where ' indicates differentiation with respect to x. - Philippe Deléham, Feb 11 2013
T(n,k) = [t^k] (n! [x^n] (1/(1-t*(exp(x)-1)))). - Peter Luschny, Jan 23 2017
The n-th row polynomial has the form x o x o ... o x (n factors), where o denotes the black diamond multiplication operator of Dukes and White. See also Bala, Example E8. - Peter Bala, Jan 08 2018

A281478 Central coefficients of Joffe's central differences of zero (assuming offset 0 and T(n,k) extended to 0 <= k <= n in A241171).

Original entry on oeis.org

1, 1, 126, 126720, 494053560, 5283068427000, 126301275727704000, 5896518025761483120000, 488276203972584492344880000, 66735969985432035804226510800000, 14236685931434801591697761172512160000, 4533351707244550464920840944132383960960000, 2077486542875366717627638783543223150778585600000
Offset: 0

Views

Author

Peter Luschny, Jan 22 2017

Keywords

Comments

Also the central coefficients of the polynomials defined in A278073 for m = 2.

Crossrefs

Cf. Central coefficients: A088218 (m=0), A210029 (m=1), A281478 (m=2), A281479 (m=3), A281480 (m=4). Related triangles: A097805 (m=0), A131689 (m=1), A241171 (m=2), A278073 (m=3), A278074 (m=4).

Programs

  • Maple
    # Function P defined in A278073.
    A281479 := n -> coeff(P(2, 2*n), x, n): seq(A281479(n), n=0..9);

A281479 Central coefficients of the polynomials defined in A278073.

Original entry on oeis.org

1, 1, 1364, 42771456, 10298900437056, 11287986820196486400, 41397337338743872194508800, 414528538783792919989135797964800, 9808376038359632185170127842947907993600, 492228239722024416239987973400425228541016064000
Offset: 0

Views

Author

Peter Luschny, Jan 22 2017

Keywords

Crossrefs

Central coefficients: A088218 (m=0), A210029 (m=1), A281478 (m=2), A281479 (m=3), A281480 (m=4). Related triangles: A097805 (m=0), A131689 (m=1), A241171 (m=2), A278073 (m=3), A278074 (m=4).

Programs

A281480 Central coefficients of the polynomials defined in A278074.

Original entry on oeis.org

1, 1, 16510, 17651304000, 286988816206755000, 35284812773848049161035000, 21735699944364325706210750640600000, 51125456932397825107093888817556205542000000, 378603085421985456745667562645258531056443927230000000, 7641597761030055776217194099395682779700673105680593973250000000
Offset: 0

Views

Author

Peter Luschny, Jan 22 2017

Keywords

Crossrefs

Central coefficients: A088218 (m=0), A210029 (m=1), A281478 (m=2), A281479 (m=3), A281480 (m=4). Related triangles: A097805 (m=0), A131689 (m=1), A241171 (m=2), A278073 (m=3), A278074 (m=4).

Programs

A258399 Number of 4n-length strings of balanced parentheses of exactly n different types that are introduced in ascending order.

Original entry on oeis.org

1, 2, 98, 11880, 2432430, 714249900, 275335499824, 131928199603200, 75727786603836510, 50713478000403718500, 38843740303576863755100, 33508462196084294380001040, 32157574295254903735909896240, 33990046387543889224733323929120
Offset: 0

Views

Author

Alois P. Heinz, May 28 2015

Keywords

Examples

			a(0) = 1: the empty string.
a(1) = 2: ()(), (()).
a(2) = A000108(4) * (2^3-1) = 14*7 = 98.
		

Crossrefs

Programs

  • Maple
    ctln:= proc(n) option remember; binomial(2*n, n)/(n+1) end:
    A:= proc(n, k) option remember; k^n*ctln(n) end:
    a:= n-> add(A(2*n, n-i)*(-1)^i/((n-i)!*i!), i=0..n):
    seq(a(n), n=0..15);
  • Mathematica
    A[n_, k_] := A[n, k] = k^n CatalanNumber[n];
    a[n_] := If[n==0, 1, Sum[A[2n, n-i] (-1)^i/((n-i)! i!), {i, 0, n}]];
    a /@ Range[0, 15] (* Jean-François Alcover, Jan 01 2021, after Alois P. Heinz *)

Formula

a(n) = A253180(2n,n).
a(n) ~ c * d^n * n! / n^(5/2), where d = A256254 = -64/(LambertW(-2*exp(-2))*(2 + LambertW(-2*exp(-2)))) = 98.8248737517356857317..., c = 1/(2^(5/2) * Pi^(3/2) * sqrt(1 + LambertW(-2*exp(-2)))) = 0.0412044746356859529237459292541572856326... . - Vaclav Kotesovec, Jun 01 2015, updated Sep 27 2023
a(n) = A210029(n) * (4*n)! / (n! * (2*n)! * (2*n + 1)!), for n>0. - Vaclav Kotesovec, Sep 27 2023

A220282 E.g.f.: 1/(1-x) = Sum_{n>=0} a(n) * exp(-n^2*x) * x^n/n!.

Original entry on oeis.org

1, 1, 4, 51, 1480, 79765, 7010496, 920281831, 169526669824, 41844075277545, 13357347571244800, 5362349333225289691, 2646862288162043664384, 1576780272924188221429501, 1116120717235502072828661760, 926421799655193830945493519375, 891516461371835173578650979598336
Offset: 0

Views

Author

Paul D. Hanna, Dec 11 2012

Keywords

Comments

Compare to the identity: 1/(1-x) = Sum_{n>=0} n^n * exp(-n*x) * x^n/n!.
Compare to the o.g.f. of A007820:
Sum_{n>=0} S2(2*n,n)*x^n = Sum_{n>=0} (n^2)^n * exp(-n^2*x) * x^n/n!.

Examples

			E.g.f.: 1/(1-x) = 1 + 1*exp(-x)*x + 4*exp(-2^2*x)*x^2/2! + 51*exp(-3^2*x)*x^3/3! + 1480*exp(-4^2*x)*x^4/4! + 79765*exp(-5^2*x)*x^5/5! + 7010496*exp(-6^2*x)*x^6/6!+...
		

Crossrefs

Programs

  • PARI
    {a(n)=n!*polcoeff(1/(1-x+x*O(x^n))-sum(k=0,n-1,a(k)*x^k/k!*exp(-k^2*x+x*O(x^n))), n)}
    for(n=0,16,print1(a(n),", "))

A344397 a(n) = Stirling2(n, floor(n/2)) * floor(n/2)!.

Original entry on oeis.org

1, 0, 1, 1, 14, 30, 540, 1806, 40824, 186480, 5103000, 29607600, 953029440, 6711344640, 248619571200, 2060056318320, 86355926616960, 823172919528960, 38528927611574400, 415357755774998400, 21473732319740064000, 258323865658578720000, 14620825330739032204800
Offset: 0

Views

Author

Peter Luschny, May 21 2021

Keywords

Crossrefs

Programs

  • Maple
    a := n -> add((-1)^k*binomial((2*n-1)/4 + (-1)^n/4,k)*((2*n-1)/4 + (-1)^n/4 - k)^n, k = 0..n/2):
    # Alternative, via Fubini recurrence:
    F := proc(n) option remember; if n = 0 then return 1 fi;
    expand(add(binomial(n, k)*F(n - k)*x, k = 1..n)) end:
    a := n -> coeff(F(n), x, iquo(n, 2));
    seq(a(n), n = 0..22);
  • Mathematica
    a[n_] := StirlingS2[n, Floor[n/2]] * Floor[n/2]!; Array[a, 23, 0] (* Amiram Eldar, May 22 2021 *)
  • SageMath
    def a(n): return stirling_number2(n, n//2) * factorial(n//2)
    print([a(n) for n in range(23)])

Formula

a(n) = [x^(floor(n/2))] F(n, x), the middle coefficient of the Fubini polynomial.
a(n) = Sum_{k=0..n/2} (-1)^k*binomial((2*n - 1)/4 + (-1)^n/4, k)*((2*n - 1)/4 + (-1)^n/4 - k)^n.
Showing 1-7 of 7 results.