login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A361682 Array read by descending antidiagonals. A(n, k) is the number of multiset combinations of {0, 1} whose type is defined in the comments. Also A(n, k) = hypergeom([-k, -2], [1], n). 3

%I #16 Mar 23 2023 07:57:37

%S 1,1,1,1,3,1,1,6,5,1,1,10,13,7,1,1,15,25,22,9,1,1,21,41,46,33,11,1,1,

%T 28,61,79,73,46,13,1,1,36,85,121,129,106,61,15,1,1,45,113,172,201,191,

%U 145,78,17,1,1,55,145,232,289,301,265,190,97,19,1

%N Array read by descending antidiagonals. A(n, k) is the number of multiset combinations of {0, 1} whose type is defined in the comments. Also A(n, k) = hypergeom([-k, -2], [1], n).

%C A combination of a multiset M is an unordered selection of k objects of M, where every object can appear at most as many times as it appears in M.

%C A(n, k) = Cardinality(Union_{j=0..k} Combination(MultiSet(1^[j*n], 0^[(k-j)*n]))), where MultiSet(r^[s], u^[v]) denotes a set that contains the element r with multiplicity s and the element u with multiplicity v; thus the multisets under consideration have n*k elements. Since the base set is {1, 0} the elements can be represented as binary strings. Applying the combination operator to the multisets results in a set of binary strings where '0' resp. '1' can appear at most j*n resp. (k-j)*n times. 'At most' means that they do not have to appear; in other words, the resulting set always includes the empty string ''.

%C In contrast to the procedure in A361045 we consider here the cardinality of the set union and not the sum of the individual cardinalities. If you want to exclude the empty string, you will find the sequences listed in A361521. The same construction with multiset permutations instead of multiset combinations results in A361043.

%C A different view can be taken if one considers the hypergeometric representation, hypergeom([-k, -m], [1], n). This is a family of arrays that includes the 'rascal' triangle: the all 1's array A000012 (m = 0), the rascal array A077028 (m = 1), this array (m = 2), and A361731 (m = 3).

%F A(n, k) = 1 + n*k*(4 + n*(k - 1))/2.

%F T(n, k) = 1 + k*(n - k)*(4 + k*(n - k - 1))/2.

%F A(n, k) = [x^k] (1 + (n - 1)*x)^2 / (1 - x)^3.

%F A(n, k) = hypergeom([-k, -2], [1], n).

%F A(n, k) = A361521(n, k) + 1.

%e Array A(n, k) starts:

%e [0] 1, 1, 1, 1, 1, 1, 1, 1, ... A000012

%e [1] 1, 3, 6, 10, 15, 21, 28, 36, ... A000217

%e [2] 1, 5, 13, 25, 41, 61, 85, 113, ... A001844

%e [3] 1, 7, 22, 46, 79, 121, 172, 232, ... A038764

%e [4] 1, 9, 33, 73, 129, 201, 289, 393, ... A081585

%e [5] 1, 11, 46, 106, 191, 301, 436, 596, ... A081587

%e [6] 1, 13, 61, 145, 265, 421, 613, 841, ... A081589

%e [7] 1, 15, 78, 190, 351, 561, 820, 1128, ... A081591

%e 000012 | A028872 | A239325 |

%e A005408 A100536 A069133

%e .

%e Triangle T(n, k) starts:

%e [0] 1;

%e [1] 1, 1;

%e [2] 1, 3, 1;

%e [3] 1, 6, 5, 1;

%e [4] 1, 10, 13, 7, 1;

%e [5] 1, 15, 25, 22, 9, 1;

%e [6] 1, 21, 41, 46, 33, 11, 1;

%e [7] 1, 28, 61, 79, 73, 46, 13, 1;

%e [8] 1, 36, 85, 121, 129, 106, 61, 15, 1;

%e [9] 1, 45, 113, 172, 201, 191, 145, 78, 17, 1.

%e .

%e Row 4 of the triangle:

%e A(0, 4) = 1 = card('').

%e A(1, 3) = 10 = card('', 0, 00, 000, 1, 10, 100, 11, 110, 111).

%e A(2, 2) = 13 = card('', 0, 00, 000, 0000, 1, 10, 100, 11, 110, 1100, 111, 1111).

%e A(3, 1) = 7 = card('', 0, 00, 000, 1, 11, 111).

%e A(4, 0) = 1 = card('').

%p A := (n, k) -> 1 + n*k*(4 + n*(k - 1))/2:

%p for n from 0 to 7 do seq(A(n, k), k = 0..7) od;

%p # Alternative:

%p ogf := n -> (1 + (n - 1)*x)^2 / (1 - x)^3:

%p ser := n -> series(ogf(n), x, 12):

%p row := n -> seq(coeff(ser(n), x, k), k = 0..9):

%p seq(print(row(n)), n = 0..7);

%o (SageMath)

%o def A(m: int, steps: int) -> int:

%o if m == 0: return 1

%o size = m * steps

%o cset = set()

%o for a in range(0, size + 1, m):

%o S = [str(int(i < a)) for i in range(size)]

%o C = Combinations(S)

%o cset.update("".join(i for i in c) for c in C)

%o return len(cset)

%o def ARow(n: int, size: int) -> list[int]:

%o return [A(n, k) for k in range(size + 1)]

%o for n in range(8): print(ARow(n, 7))

%Y Rows: A000012, A000217, A001844, A038764, A081585, A081587, A081589, A081591.

%Y Columns: A000012, A005408, A028872, A100536, A239325, A069133.

%Y Cf. A239592 (main diagonal), A239331 (transposed array).

%Y Cf. A361045, A361043, A361521, A361731, A077028.

%K nonn,tabl

%O 0,5

%A _Peter Luschny_, Mar 21 2023

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 12 13:47 EDT 2024. Contains 374247 sequences. (Running on oeis4.)