4

I am new to combinatorics and am wondering about an extension of a weak composition of $n$ into $k$ parts where both $n \in \mathbb{N}$ and $k \in \mathbb{N}$. Classically, the (non-weighted) result is, $$ \text{If, }A = \left\{ (b_1, b_2, \ldots, b_k) \in \mathbb{Z}_+^k : \sum_{i = 1}^k b_i = n \right\}, \quad \text{then } |A| = \binom{n + k - 1}{k - 1} $$ where $|\cdot|$ denotes the cardinality of $A$ and $\mathbb{Z}_+$ denotes the field of non-negative integers.

My question is if it is possible to extend this to have a weighted weak composition of integers into $k$ parts? Namely, define a set of fixed weights $\alpha = (a_1, a_2, \ldots, a_k) \in \mathbb{R}_+^k\setminus\left\{ 0\right\}$ and $$ A_\alpha = \left\{ (b_1, b_2, \ldots, b_k) \in \mathbb{Z}_+^k : \lfloor\sum_{i = 1}^k a_i b_i \rfloor = n \right\} $$ Is it possible to compute $|A_\alpha|$? Or perhaps give bounds on $|A_\alpha|$?

JRW
  • 43
  • Yes, you are absolutely correct. I forgot to amend the definition of $A_\alpha$. Sorry about that. I have edited the question – JRW Jan 12 '16 at 05:32
  • I doubt there is a simple closed form for $|A_\alpha |$ in general but it should be possible to calculate it with a recurrence. There is the slight twist that for $a_i \lt 1$ that there may be more than one satisfying value of $b_i$ even if the other $a_j$ and $b_j$ stay the same, while if $a_i \gt 1$ there may be none. – Henry Jan 12 '16 at 07:48
  • Thanks for the reply. In what sense would a recurrence be built? A recurrence in $n$? – JRW Jan 12 '16 at 08:20
  • A recurrence involving $i$ and the sum. I will give an example. – Henry Jan 12 '16 at 09:51
  • After doing some further digging, another alternative to get a decomposition for $A_\alpha$ would be to construct the generating function similar to this example. Using this to target $|A_\alpha|$ seems daunting though. – JRW Jan 13 '16 at 06:29

1 Answers1

1

As an example of how to do this with a recurrence, the number of ways $N_{s,i}$ of reaching a particular sum $s$ with $i$ weights $(a_1,a_2,\ldots,a_i)$ satisfies $$ N_{s,i} = N_{s,i-1}+N_{s-a_i,i}$$ starting with $N_{0,0}=1$ and $N_{s,0}=0$ for $s\not= 0$.

You then need to take $\displaystyle |A_\alpha|=\sum_{n \le s \lt n+1} N_{s,k}$ to get the result in your formulation.

For example suppose $n=2$, $k=5$ and the weights are $(0.7,0.5,0.9,0.8,0.6)$. The recurrence might then produce this table for $N_{s,i}$

0       1   1   1   1   1   1
0.1     0   0   0   0   0   0
0.2     0   0   0   0   0   0
0.3     0   0   0   0   0   0
0.4     0   0   0   0   0   0
0.5     0   0   1   1   1   1
0.6     0   0   0   0   0   1
0.7     0   1   1   1   1   1
0.8     0   0   0   0   1   1
0.9     0   0   0   1   1   1
1       0   0   1   1   1   1
1.1     0   0   0   0   0   1
1.2     0   0   1   1   1   2
1.3     0   0   0   0   1   2
1.4     0   1   1   2   2   3
1.5     0   0   1   1   2   3
1.6     0   0   0   1   2   3
1.7     0   0   1   1   2   3
1.8     0   0   0   1   2   4
1.9     0   0   1   2   2   4
2       0   0   1   1   2   5
2.1     0   1   1   2   3   6
2.2     0   0   1   1   3   6
2.3     0   0   0   2   4   7
2.4     0   0   1   2   4   8
2.5     0   0   1   2   4   8
2.6     0   0   1   2   4   9
2.7     0   0   1   2   4   10
2.8     0   1   1   3   5   11
2.9     0   0   1   2   5   12

giving the solution as the sum of the last ten numbers in the final column, i.e. $82$

Henry
  • 169,616
  • Thanks for the computation strategy. There is a typo in your final answer. The 196 should be 82 given your table. On the other hand, I did a brute force computation on R and reached an answer of 83 for your calibrated example which means our computations disagree by one.

    Do you believe there is a closed form type bound on $|A_\alpha|$? That is actually my end goal in the hopes of bounding a term involving $|A_\alpha|$. E.g. An equivalent type bound of $|A| = \binom{n + k - 1}{k - 1} = O(n^{k-1})$. I should perhaps amend my question to show this?

    – JRW Jan 12 '16 at 23:33