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

A361781 A(n,k) is the n-th term of the k-th inverse binomial transform of the Bell numbers (A000110); square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 0, 2, 1, -1, 1, 5, 1, -2, 2, 1, 15, 1, -3, 5, -3, 4, 52, 1, -4, 10, -13, 7, 11, 203, 1, -5, 17, -35, 36, -10, 41, 877, 1, -6, 26, -75, 127, -101, 31, 162, 4140, 1, -7, 37, -139, 340, -472, 293, -21, 715, 21147, 1, -8, 50, -233, 759, -1573, 1787, -848, 204, 3425, 115975
Offset: 0

Views

Author

Alois P. Heinz, Mar 23 2023

Keywords

Examples

			Square array A(n,k) begins:
    1,   1,   1,    1,     1,      1,       1,       1, ...
    1,   0,  -1,   -2,    -3,     -4,      -5,      -6, ...
    2,   1,   2,    5,    10,     17,      26,      37, ...
    5,   1,  -3,  -13,   -35,    -75,    -139,    -233, ...
   15,   4,   7,   36,   127,    340,     759,    1492, ...
   52,  11, -10, -101,  -472,  -1573,   -4214,   -9685, ...
  203,  41,  31,  293,  1787,   7393,   23711,   63581, ...
  877, 162, -21, -848, -6855, -35178, -134873, -421356, ...
		

Crossrefs

Columns k=0-5 give: A000110, A000296, A126617, A346738, A346739, A346740.
Rows n=0-2 give: A000012, A024000, A160457.
Main diagonal gives A290219.
Antidiagonal sums give A361380.
Cf. A108087.

Programs

  • Magma
    T:= func< n,k | (&+[(-k)^j*Binomial(n,j)*Bell(n-j): j in [0..n]]) >;
    A361781:= func< n,k | T(k, n-k) >;
    [A361781(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Jun 12 2024
    
  • Maple
    A:= proc(n, k) option remember; uses combinat;
          add(binomial(n, j)*(-k)^j*bell(n-j), j=0..n)
        end:
    seq(seq(A(n, d-n), n=0..d), d=0..10);
    # second Maple program:
    b:= proc(n, m) option remember;
         `if`(n=0, 1, b(n-1, m+1)+m*b(n-1, m))
        end:
    A:= (n, k)-> b(n, -k):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    T[n_, k_]:= T[n, k]= If[k==0, BellB[n], Sum[(-k)^j*Binomial[n,j]*BellB[n-j], {j,0,n}]];
    A361781[n_, k_]= T[k, n-k];
    Table[A361781[n,k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, Jun 12 2024 *)
  • SageMath
    def T(n,k): return sum( (-k)^j*binomial(n,j)*bell_number(n-j) for j in range(n+1))
    def A361781(n, k): return T(k, n-k)
    flatten([[A361781(n, k) for k in range(n+1)] for n in range(13)]) # G. C. Greubel, Jun 12 2024

Formula

E.g.f. of column k: exp(exp(x) - k*x - 1).
A(n,k) = Sum_{j=0..n} (-k)^j*binomial(n,j)*Bell(n-j).

A358622 Regular triangle read by rows. T(n, k) = [[n, k]], where [[n, k]] are the second order Stirling cycle numbers (or second order reciprocal Stirling numbers). T(n, k) for 0 <= k <= n.

Original entry on oeis.org

1, 0, 0, 0, 1, 0, 0, 2, 0, 0, 0, 6, 3, 0, 0, 0, 24, 20, 0, 0, 0, 0, 120, 130, 15, 0, 0, 0, 0, 720, 924, 210, 0, 0, 0, 0, 0, 5040, 7308, 2380, 105, 0, 0, 0, 0, 0, 40320, 64224, 26432, 2520, 0, 0, 0, 0, 0, 0, 362880, 623376, 303660, 44100, 945, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Peter Luschny, Nov 23 2022

Keywords

Comments

[[n, k]] are the number of permutations of an n-set having at least two elements in each orbit. These permutations have no fixed points and therefore [[n, k]] is the number of k-orbit derangements of an n-set. This is the definition and notation (doubling the stacked delimiters of the Stirling cycle numbers) as given by Fekete (see link).
The formal definition expresses the second order Stirling cycle numbers as a binomial sum over second order Eulerian numbers (see the first formula below). The terminology 'associated Stirling numbers of first kind' used elsewhere should be dropped in favor of the more systematic one used here.
Also the Bell transform of the factorial numbers with 0! = 0. For the definition of the Bell transform see A264428.

Examples

			Triangle T(n, k) starts:
[0] 1;
[1] 0,     0;
[2] 0,     1,     0;
[3] 0,     2,     0,     0;
[4] 0,     6,     3,     0,    0;
[5] 0,    24,    20,     0,    0,  0;
[6] 0,   120,   130,    15,    0,  0,  0;
[7] 0,   720,   924,   210,    0,  0,  0,  0;
[8] 0,  5040,  7308,  2380,  105,  0,  0,  0,  0;
[9] 0, 40320, 64224, 26432, 2520,  0,  0,  0,  0,  0;
		

References

  • Ronald L. Graham, Donald E. Knuth, and Oren Patashnik, Concrete Mathematics, Addison-Wesley, Reading, 2nd ed. 1994, thirty-fourth printing 2022.

Crossrefs

A008306 is an irregular subtriangle with more information.
Cf. A000166 (row sums), A024000 (alternating row sums).

Programs

  • Maple
    P := (n, x) -> (-x)^n*hypergeom([-n, x], [], 1/x):
    row := n -> seq(coeff(simplify(P(n, x)), x, k), k = 0..n):
    for n from 0 to 9 do row(n) od;
    # Alternative:
    T := (n, k) -> add(binomial(n, k - j)*abs(Stirling1(n - k + j, j))*(-1)^(k - j), j =  0..k): for n from 0 to 9 do seq(T(n, k), k = 0..n) od;
    # Using the e.g.f.:
    egf := (exp(t)*(1 - t))^(-z): ser := series(egf, t, 12):
    seq(print(seq(n!*coeff(coeff(ser, t, n), z, k), k=0..n)), n = 0..9);
    # Using second order Eulerian numbers:
    A358622 := proc(n, k) local j;
    add(binomial(j, n - 2*k)*combinat:-eulerian2(n - k, j), j = 0..n-k) end:
    seq(seq(A358622(n, k), k = 0..n), n = 0..12);
    # Using generalized Laguerre polynomials:
    P := (n, x) -> (-1)^n*n!*LaguerreL(n, -n - x, -x):
    row := n -> seq(coeff(simplify(P(n, x)), x, k), k = 0..n):
    seq(print(row(n)), n = 0..9);
  • Python
    # recursion over rows
    from functools import cache
    @cache
    def StirlingCycleOrd2(n: int) -> list[int]:
        if n == 0: return [1]
        if n == 1: return [0, 0]
        rov: list[int] = StirlingCycleOrd2(n - 2)
        row: list[int] = StirlingCycleOrd2(n - 1) + [0]
        for k in range(1, n // 2 + 1):
            row[k] = (n - 1) * (rov[k - 1] + row[k])
        return row
    for n in range(9): print(StirlingCycleOrd2(n))
    # Alternative, using function BellMatrix from A264428.
    from math import factorial
    def f(k: int) -> int:
        return factorial(k) if k > 0 else 0
    print(BellMatrix(f, 9))

Formula

T(n, k) = Sum_{j=0..n-k} binomial(j, n - 2*k)*<>, where <> denote the second order Eulerian numbers (extending Knuth's notation).
T(n, k) = [x^n] (-x)^n * hypergeom([-n, x], [], -1/x).
T(n, k) = n!*[z^k][t^n] (exp(t)*(1 - t))^(-z). (Compare with (exp(t)/(1 - t))^z, which is the e.g.f. of the Sylvester polynomials A341101.)
T(n, k) = [x^k] (-1)^n * n! * L(n, -x - n, -x), where L(n, a, x) is the n-th generalized Laguerre polynomial.
T(n, k) = Sum_{j=0..k} binomial(n, k - j)*[n - k + j, j]*(-1)^(k - j), where [n, k] denotes the (signless) Stirling cycle numbers.
T(n, k) = (n - 1) * (T(n-2, k-1) + T(n-1, k)) with suitable boundary conditions.
T(n + k, k) = A269940(n, k), which might be called the Ward cycle numbers.

A221131 Table, T, read by antidiagonals where T(-j,k) = ((1+sqrt(j))^k + (1-sqrt(j))^k)/2.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, -1, -2, 1, 1, 1, -2, -5, -4, 1, 1, 1, -3, -8, -7, -4, 1, 1, 1, -4, -11, -8, 1, 0, 1, 1, 1, -5, -14, -7, 16, 23, 8, 1, 1, 1, -6, -17, -4, 41, 64, 43, 16, 1, 1, 1, -7, -20, 1, 76, 117, 64, 17, 16, 1, 1, 1, -8, -23, 8, 121, 176, 29, -128, -95, 0, 1
Offset: 0

Views

Author

Al Hakanson (hawkuu(AT)gmail.com) and Robert G. Wilson v, Jan 02 2013

Keywords

Comments

.j\k.........0..1...2....3...4....5....6......7.......8......9......10
.0: A000012..1..1...1....1...1....1....1......1.......1......1.......1
-1: A146559..1..1...0...-2..-4...-4....0......8......16.....16.......0
-2: A087455..1..1..-1...-5..-7....1...23.....43......17....-95....-241
-3: A138230..1..1..-2...-8..-8...16...64.....64....-128...-512....-512
-4: A006495..1..1..-3..-11..-7...41..117.....29....-527..-1199.....237
-5: A138229..1..1..-4..-14..-4...76..176...-104...-1264..-1904....3776
-6: A090592..1..1..-5..-17...1..121..235...-377...-2399..-2159...12475
-7: A090590..1..1..-6..-20...8..176..288...-832...-3968..-1280...29184
-8: A025172..1..1..-7..-23..17..241..329..-1511...-5983...1633...57113
-9: A120743..1..1..-8..-26..28..316..352..-2456...-8432...7696...99712
-10: ........1..1..-9..-29..41..401..351..-3709..-11279..18241..160551

Crossrefs

Programs

  • Mathematica
    T[j_, k_] := Expand[((1 + Sqrt[j])^k + (1 - Sqrt[j])^k)/2]; Table[ T[ -j + k, k], {j, 0, 11}, {k, 0, j}] // Flatten

A373164 Triangle read by rows: the exponential almost-Riordan array ( 1 | 2 - exp(x), x ).

Original entry on oeis.org

1, 0, 1, 0, -1, 1, 0, -1, -2, 1, 0, -1, -3, -3, 1, 0, -1, -4, -6, -4, 1, 0, -1, -5, -10, -10, -5, 1, 0, -1, -6, -15, -20, -15, -6, 1, 0, -1, -7, -21, -35, -35, -21, -7, 1, 0, -1, -8, -28, -56, -70, -56, -28, -8, 1, 0, -1, -9, -36, -84, -126, -126, -84, -36, -9, 1
Offset: 0

Views

Author

Stefano Spezia, May 26 2024

Keywords

Examples

			The triangle begins:
  1;
  0,  1;
  0, -1,  1;
  0, -1, -2,   1;
  0, -1, -3,  -3,   1;
  0, -1, -4,  -6,  -4,   1;
  0, -1, -5, -10, -10,  -5,   1;
  0, -1, -6, -15, -20, -15,  -6,  1;
  0, -1, -7, -21, -35, -35, -21, -7, 1;
  ...
		

Crossrefs

Cf. A000012 (right diagonal), A024000 (subdiagonal), A122958 (row sums), A153881 (k=1).
Triangle A154926 with 1st column A000007.

Programs

  • Mathematica
    T[n_,0]:=KroneckerDelta[n,0]; T[n_,k_]:=(n-1)!/(k-1)!SeriesCoefficient[(2-Exp[x])x^(k-1),{x,0,n-1}]; Table[T[n,k],{n,0,10},{k,0,n}]//Flatten

Formula

T(n,0) = A000007(n); T(n,k) = (n-1)!/(k-1)! * [x^(n-1)] (2-exp(x))*x^(k-1).
Previous Showing 11-14 of 14 results.