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.

A371568 Array read by ascending antidiagonals: A(n, k) is the number of paths of length k in Z^n from the origin to points such that x1+x2+...+xn = k with x1,...,xn > 0.

This page as a plain text file.
%I A371568 #27 Jun 16 2025 23:48:45
%S A371568 1,0,1,0,2,1,0,0,6,1,0,0,6,14,1,0,0,0,36,30,1,0,0,0,24,150,62,1,0,0,0,
%T A371568 0,240,540,126,1,0,0,0,0,120,1560,1806,254,1,0,0,0,0,1800,8400,5796,
%U A371568 510,1
%N A371568 Array read by ascending antidiagonals: A(n, k) is the number of paths of length k in Z^n from the origin to points such that x1+x2+...+xn = k with x1,...,xn > 0.
%C A371568 T(n, k) can also be seen as the number of ordered partitions of k items into n nonempty buckets.
%C A371568 T(n, n) = n!, which is readily seen because to go from the origin to a point in Z^n a distance n away, with at least one step taken in each dimension, the first step can be in any of n dimensions, the second step in any of n-1 dimensions, and so on.
%C A371568 This array is the image of Pascal's triangle A007318 under the Akiyama-Tanigawa transformation. See the Python program. - _Peter Luschny_, Apr 19 2024
%F A371568 A(n,k) = Sum_{i=1..n} (-1)^(n-i) * binomial(n,i) * i^k
%e A371568  n\k 1 2 3  4   5    6     7      8       9       10
%e A371568   --------------------------------------------------
%e A371568  1|  1 1 1  1   1    1     1      1       1        1
%e A371568  2|  0 2 6 14  30   62   126    254     510     1022
%e A371568  3|  0 0 6 36 150  540  1806   5796   18150    55980
%e A371568  4|  0 0 0 24 240 1560  8400  40824  186480   818520
%e A371568  5|  0 0 0  0 120 1800 16800 126000  834120  5103000
%e A371568  6|  0 0 0  0   0  720 15120 191520 1905120 16435440
%e A371568  7|  0 0 0  0   0    0  5040 141120 2328480 29635200
%e A371568  8|  0 0 0  0   0    0     0  40320 1451520 30240000
%e A371568  9|  0 0 0  0   0    0     0      0  362880 16329600
%e A371568 10|  0 0 0  0   0    0     0      0       0  3628800
%t A371568 A[n_,k_] := Sum[(-1)^(n-i) * i^k * Binomial[n,i], {i,1,n}]
%o A371568 (Python)
%o A371568 # The Akiyama-Tanigawa algorithm for the binomial generates the rows.
%o A371568 # Adds row(0) = 0^k and column(0) = 0^n.
%o A371568 from math import comb as binomial
%o A371568 def ATBinomial(n, len):
%o A371568     A = [0] * len
%o A371568     R = [0] * len
%o A371568     for k in range(len):
%o A371568         R[k] = binomial(k, n)
%o A371568         for j in range(k, 0, -1):
%o A371568             R[j - 1] = j * (R[j] - R[j - 1])
%o A371568         A[k] = R[0]
%o A371568     return A
%o A371568 for n in range(11): print([n], ATBinomial(n, 11))  # _Peter Luschny_, Apr 19 2024
%Y A371568 Cf. A000918 (n=2), A001117 (n=3), A000919 (n=4), A001118 (n=5), A000920 (n=6).
%Y A371568 Cf. A135456 (n=7), A133068 (n=8), A133360 (n=9), A133132 (n=10).
%Y A371568 Cf. A371064, A007318.
%Y A371568 See A019538 and A131689 for other versions.
%K A371568 nonn,tabl
%O A371568 1,5
%A A371568 _Shel Kaphan_, Mar 28 2024