Content deleted Content added
No edit summary |
No edit summary |
||
Line 7:
<math>G(N) = \sum_{n_1 + n_2 + \cdot\cdot\cdot + n_M = N} \prod_{i=1}^M f_i( n_i )</math> with <math>f_i( n ) = y_i^n</math> for <math>1 < i <= M</math> (We also require <math>f_i( 0 ) = 1</math>, right?)
This sum can be calculated efficiently in O(MN) time by utilizing a definition with a recursive structure: {{see|dynamic programming}}
let <math>G(N) = g(m,n)</math>
|