In combinatoric, with the equation $$x_1+x_2+x_3+x_4+\dots +x_n=k,\quad x_i \geq 0,$$ we know, that the number of solutions is: $$ \left({n\choose k}\right)={n+k-1 \choose n-1}=\frac{(n+k-1)!}{(n-1)!\cdot k!} $$
Is there a way in combinatoric to find the numbers of solution for an equations like $$a_1\cdot x_1+a_2\cdot x_2+a_3\cdot x_3 + \dots + a_n\cdot x_n=k, \quad x_i \geq 0,$$ where we know the values of $a_1,a_2,\dots, a_n$?
The number of solutions is the coefficient of $x^k$ in the generating function
$$ \prod_{i=1}^n\frac1{1-x^{a_i}}\;. $$