In how many way can the number $100$ be expressed as a sum of $3$ different positive integers

contest-mathpuzzle

Australian Mathematics Competition 2022 Junior Level Question 30:

In how many way can the number $100$ be expressed as a sum of $3$ different positive integers?

The way I tried to approach the problem was to assume the first integer was $1$. As the integers had to be different, the possible values were from $1+2+97$ to $1+97+2$ thus there are $96$ ways. If we start from $2$, then the possibilities will range from $2+3+95$ to $2+95+3$ and there are $95$ ways. Thus there are $96+95+94+\ldots+1$ ways. Using the formula $n(n+1)/2$, the answer is $4656$. But we overcounted so we have to divide again by $3!$. So $4656/6=776$. There are $776$ ways but this answer is wrong.

Can anybody assist me with this problem?

Thanks.

Best Answer

Slightly less technical solution. Note that the number of solutions to $x_1 + x_2 + x_3 = 100$ is just $\binom{99}{2}$ by "Stars and Bars." There are no solution with $x_1 = x_2 = x_3$. Now consider the set of solutions with exactly two of the same numbers. They are of the form $((1,1,98),\dots,(49,49,2)).$ Clearly, there are $49$ of these, each of which can be permuted in three ways. Therefore, the total number of tuples with distinct $x_1, x_2, x_3$ is just $\binom{99}{2} - 49 \cdot 3$. Each of these are counted six times by your own reasoning. Therefore, the total number of ways $100$ can be expressed as the sum of three positive integers is just $$\frac{\binom{99}{2} - 49\cdot 3}{6} = \frac{99 \cdot 49 - 3 \cdot 49}{6} = \frac{96 \cdot 49}{6} = 16 \cdot 49 = 28^2 = \fbox{784}.$$