Skip to main content
2 of 4
added 490 characters in body
Will Sawin
  • 148.5k
  • 9
  • 324
  • 563

The generating function is $$ \sum_{s_1,s_2, s_3} {s_1 + s_2-1 \choose s_2} {s_2+ s_3-1 \choose s_3} x^{s_1+s_2+s_3}.$$

$$ \sum_{s_3} {s_2+ s_3-1 \choose s_3} x^{s_3} = \left( \frac{1}{1-x}\right)^{s_2}$$.

Then the sum over the $s_2$ variable is

$$ \sum_{s_2} {s_1 + s_2-1 \choose s_2}\left( \frac{x}{1-x}\right)^{s_2} = \left( \frac{1}{1- \frac{x}{1-x}} \right)^{s_1} = \left( \frac{1-x}{1-2x} \right)^{s_1}$$

and the sum over just the $s_1$ variable is

$$ \sum_{s_1} \left( \frac{x-x^2}{1-2x}\right)^{s_1} = \frac{1}{1- \frac{x}{1-x}} \right)^{s_1} = \left( \frac{1-x}{1-2x} \right)^{s_1}$$

Examining just the sum over the $s_3$ variable, we get $1/(1-x)^{s_2}.$ then the sum over just the $s_2$ variable is $1/(1-x/(1-x))^{s_1}=((1-x)/(1-2x))^{s_1}$ and so the whole generating function is $(1-2x)/(1-3x+ x^2)$. Thus explains two of the eugenvalues Carlo found. The remaining one comes from the fact that for this to work we need ${-1 \choose 0}=1$. We have to subtract off the terms where $s_1,s_2,$ or $s_3$ is zero. If any is zero then all later ones are zero so these are all contained I $s_3=0$ which gives $(1-x)/(1-2x)$. Subtracting this off we should get the right formula.

Will Sawin
  • 148.5k
  • 9
  • 324
  • 563