TOPICS
Search

Weak Composition


A weak composition of a nonnegative integer n is an ordered tuple of nonnegative integers whose sum is n. It differs from a composition, whose parts must be positive. For example, (2,0,1) and (0,2,1) are distinct weak compositions of 3 (Tesler 2019).

For a positive integer k, the number of weak compositions of n into k parts is

 C_k^'(n)=(n+k-1; k-1)=(n+k-1; n).

To count them, arrange n stars and k-1 separators in a row. The numbers of stars before, between, and after the separators are the ordered parts. Choosing the separator positions gives the binomial coefficient above. For n=0, there is one weak composition of each positive length, consisting entirely of zeros. There is also one empty weak composition of 0 (Tesler 2019).


See also

Composition, Multinomial Coefficient, Partition

Explore with Wolfram|Alpha

References

Tesler, G. "Integer Compositions and Partitions and Set Partitions." Math 184A, Winter 2019. https://mathweb.ucsd.edu/~gptesler/184a/slides/184a_ch5slides_19-handout.pdf.

Cite this as:

Weisstein, Eric W. "Weak Composition." From MathWorld--A Wolfram Resource. https://mathworld.wolfram.com/WeakComposition.html

Subject classifications