Combinatorics – How Many Solutions for x1 + x2 + x3 + x4 + x5 = 55

combinatorics

How many solutions possible for the equation $x_1+x_2+x_3+x_4+x_5=55$ if all $x$ are non-negative integer:

  • No restrictions. The solution is $C(55 + 4, 4) = C(59,4)$ but I fail to see why, can someone explain this to me?
  • Every $x_k$ is odd.
  • If $x_1\ge1,x_2\ge2,x_3\ge3,x_4\ge2,x_5\ge1$

Best Answer

  1. You forgot to say that $0\le x_i$ (otherwise there is an infinite number of solutions). This is a standard "choice with repetitions and without order" case (hence the formula, which is one of the basic formulas in combinatorics). In this case, you have 55 "balls" to distribute freely into the five "holes" - the variables.
  2. Here you can write $x_i=2y_i+1$ and solve for $y_i$ instead of $x_i$. You'll get something like $2(y_1+\dots+y_5)+5=55$ - simplify to get $y_1+\dots+y_5=25$ (how?)
  3. Here you use $x_1=y_1+1$, $x_2=y_2+2$ and then again solve for $y_i$.