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.

A382521 Square array A(n,k), n>=0, k>=0, read by antidiagonals downwards, where n unlabeled objects are distributed into k containers of three kinds. Containers may be left empty.

This page as a plain text file.
%I A382521 #16 Apr 01 2025 18:54:32
%S A382521 1,3,0,6,3,0,10,9,3,0,15,18,15,3,0,21,30,36,18,3,0,28,45,66,55,24,3,0,
%T A382521 36,63,105,114,81,27,3,0,45,84,153,195,189,108,33,3,0,55,108,210,298,
%U A382521 348,276,145,36,3,0,66,135,276,423,558,552,405,180,42,3,0,78,165,351,570,819,936,858,549,225,45,3,0
%N A382521 Square array A(n,k), n>=0, k>=0, read by antidiagonals downwards, where n unlabeled objects are distributed into k containers of three kinds. Containers may be left empty.
%F A382521 A(0,k) = binomial(k + 2, 2) = A000217(k + 1).
%F A382521 A(1,k) = 3 * binomial(k + 1, 2).
%F A382521 A(n,1) = 3.
%F A382521 A(n,k) = Sum_{i=0..k} binomial(k + 2 - i, 2) * A382343(n,i) for k <= n.
%F A382521 A(n,k) = A382343(n+k,k).
%e A382521 Array starts:
%e A382521  0 : [1, 3,  6,  10,   15,   21,   28,    36,    45,    55,    66]
%e A382521  1 : [0, 3,  9,  18,   30,   45,   63,    84,   108,   135,   165]
%e A382521  2 : [0, 3, 15,  36,   66,  105,  153,   210,   276,   351,   435]
%e A382521  3 : [0, 3, 18,  55,  114,  195,  298,   423,   570,   739,   930]
%e A382521  4 : [0, 3, 24,  81,  189,  348,  558,   819,  1131,  1494,  1908]
%e A382521  5 : [0, 3, 27, 108,  276,  552,  936,  1428,  2028,  2736,  3552]
%e A382521  6 : [0, 3, 33, 145,  405,  858, 1532,  2427,  3543,  4880,  6438]
%e A382521  7 : [0, 3, 36, 180,  549, 1248, 2340,  3861,  5811,  8190, 10998]
%e A382521  8 : [0, 3, 42, 225,  741, 1785, 3510,  6000,  9300, 13410, 18330]
%e A382521  9 : [0, 3, 45, 271,  957, 2451, 5051,  8967, 14307, 21126, 29424]
%e A382521 10 : [0, 3, 51, 324, 1227, 3312, 7137, 13125, 21552, 32553, 46194]
%e A382521 ...
%p A382521 b:= proc(n, i) option remember; expand(`if`(n=0, 1, `if`(i<1, 0,
%p A382521       add(x^j*b(n-i*j, min(n-i*j, i-1))*(j+2)*(j+1)/2, j=0..n/i))))
%p A382521     end:
%p A382521 A:= (n, k)-> coeff(b(n+k$2), x, k):
%p A382521 seq(seq(A(n, d-n), n=0..d), d=0..11);  # _Alois P. Heinz_, Mar 31 2025
%o A382521 (Python)
%o A382521 from sympy import binomial
%o A382521 from sympy.utilities.iterables import partitions
%o A382521 def a_row(n, length=11) :
%o A382521     if n == 0 : return [ binomial( k + 2, 2) for k in range( length) ]
%o A382521     t = list( [0] * length)
%o A382521     for p in partitions( n):
%o A382521         fact = 1
%o A382521         s = 0
%o A382521         for k in p :
%o A382521             s += p[k]
%o A382521             fact *= binomial( 2 + p[k], 2)
%o A382521         if s > 0 :
%o A382521             t[s] += fact
%o A382521     a = list( [0] * length)
%o A382521     for i in range( 1, length):
%o A382521         for j in range( i, 0, -1):
%o A382521             a[i] += t[j] * binomial( i - j + 2, 2)
%o A382521     return a
%o A382521 for n in range(11): print(a_row(n))
%Y A382521 Antidiagonal sums give A000716.
%Y A382521 Alternating antidiagonal sums give A107635.
%Y A382521 Without empty containers: A382025.
%Y A382521 Cf. A382343, A000217, 2 kinds: A382345.
%K A382521 nonn,tabl
%O A382521 0,2
%A A382521 _Peter Dolland_, Mar 30 2025