the number of k-compositions of an integer - Maple Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Mathematics : Discrete Mathematics : Combinatorics : combinat : combinat/numbcomp

combinat[numbcomp] - the number of k-compositions of an integer

Calling Sequence

numbcomp(n, k)

Parameters

n, k

-

any integers

Description

• 

The numbcomp command counts the number of distinct ordered k-tuples of positive integers whose elements sum to n. For information on the composition command, which constructs k-compositions, see the combinat[composition] help page.

• 

Note that numbcompn,k=nopscompositionn,k=binomialn1,k1 for n,k>0 .

Examples

withcombinat,numbcomp

numbcomp

(1)

numbcomp7,3

15

(2)

numbcomp5,4

4

(3)

See Also

combinat[composition]


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam