Is there any known formula for the number of compositions of an integer k (partitions with considering the order of the parts) of length m (exactly m parts) where the parts do not exceed a given integer n? Without limitation of the parts there is, of course, a wellknown formula (binomial k1 over m1). Introducing the limitation I worked out a formula but I don´t know whether it´s already published anywhere ...
If I understand well, you consider the number $a(k,n,m)$ of multiindices $a=(a_1,\dots,a_m)\in\{1,\dots,n\}^m$ with weight $\sum_{i=1}^m a_i=k$. This is therefore the coefficient of $x^k$ in $$\left (\sum _ {j=1}^n x^j \right)^m = x^m(1x^n)^m (1x)^{m}\, .$$ Since the above generating function is the product of functions with elementary power series expansion, a formula for $a(k,n,m)$ is available as a convolution of binomial coefficients. Is this what you mean? This is certainly in any text on the subject . 


Heubach and Mansour's Combinatorics of Compositions and Words (CRC 2010) call these "limited" in an exercise (copied below), although I have not found that terminology elsewhere. Part 2 suggests there is a "simple" formula for what you want. p85, Exercise 3.12 A composition $\sigma = \sigma_1 \cdots \sigma_m$ of $n$ with $m$ parts is said to be limited if $1 \leq \sigma_i \leq n_i$ for all $i = 1, 2, \ldots, n$. [[I think that should be $1, 2, \ldots m$.]] (1) Derive a formula for the generating function for the number of limited compositions of $n$. (2) Using Part (1), obtain a simple formula for the case $n_i = k$ for all $i$. (3) Prove that the number of limited compositions of $n$ is given by $F_{n+1}$ [[Fibonacci]] when $n_i = 2$ for all $i$. I wanted more room to follow up on Douglas' comment than a comment would allow. Douglas, I believe you're right, that everything comes down to essentially Pietro's generating function and the summation you gave in a comment there. Let me just add some other names used for the numbers that answer Fink's original question. For maximum part $k = 2$, as in the Heubach & Mansour exercise part (3) above, there are $F_{n+1}$ (Fibonacci) limited compositions of $n$. The number with $m$ parts is $\binom{m}{nm}$ (there are $nm$ 2's and $2mn$ 1's). The connection between these binomial coefficients and the Fibonacci number is often expressed as sums of diagonal entries in Pascal's triangle; proving the identity in terms of limited compositions is the basis of Benjamin & Quinn's Proofs that Really Count (MAA 2003, Identity 4). For maximum part $k = 3$, Fibonacci numbers are replaced by "tribonacci" numbers (recurrence $a_n = a_{n1}+a_{n2}+a_{n3}$) and binomial coefficients are replaced by trinomial coefficients, so not Pascal's triangle of coefficients of $(1+x)^n$ but coefficients of $(1+x+x^2)^n$, studied by Euler (see http://arXiv.org/abs/math.HO/0505425). For $k = 4$ the total number of limited compositions are given by "tetranacci" numbers (OEIS http://oeis.org/A000078) and the number with $m$ parts is given by "quadronomial" coefficients (http://oeis.org/A008287). A comment for that integer sequence describes the general result:



Here's a fast python implementation of the a(k,n,m) function you described. You can use it to check your answers as I noticed some incorrect answers in the posts above.


