how many solutions $(x_1,x_2,x_3,x_4)$ are there to the equation $x_1+x_2+x_3+x_4=18$, $1\leq x_1<x_2<x_3<x_4\leq 9$, $x_1,x_2,x_3,x_3\in\mathbb{N}$. Thanks so much!
-
Try using generating functions, for example. There are plenty of examples on MSE, like [this](https://math.stackexchange.com/questions/2477467/how-many-nonnegative-integer-solutions-are-there-to-the-equation-x-1x-2x-3x/) or [this](https://math.stackexchange.com/questions/2877158/xyz-n-finding-the-number-of-solutions/). – rtybase Nov 10 '19 at 09:01
-
@rty the first of those two questions doesn't have the condition that the $x_i$ are increasing. – Gerry Myerson Nov 10 '19 at 09:40
-
@GerryMyerson my argument is to use generating functions and I provided a few examples. What is not related to the question in your opinion? – rtybase Nov 10 '19 at 09:49
-
@rty how do you incorporate the condition $x_1
– Gerry Myerson Nov 10 '19 at 10:37 -
1@GerryMyerson my intent was not to solve OP's problem, but provide him with sufficient material to learn (possibly) a new technique. The 1st example is a very simple one (the only relation to the question is $=18$), the 2nd example contains a technique for $1\leq x \leq y \leq z$ and a link to [this](https://math.stackexchange.com/questions/2623657/number-of-positive-integral-solutions-of-abcde-20-such-that-abcde-an). – rtybase Nov 10 '19 at 10:42
-
Welcome to MathSE. Please edit your question to show what you have attempted and explain where you are stuck. – N. F. Taussig Nov 10 '19 at 14:59
1 Answers
Here are all solutions: $$(\text{x1}=1\land \text{x2}=2\land \text{x3}=6\land \text{x4}=9)\lor (\text{x1}=1\land \text{x2}=2\land \text{x3}=7\land \text{x4}=8)\lor (\text{x1}=1\land \text{x2}=3\land \text{x3}=5\land \text{x4}=9)\lor (\text{x1}=1\land \text{x2}=3\land \text{x3}=6\land \text{x4}=8)\lor (\text{x1}=1\land \text{x2}=4\land \text{x3}=5\land \text{x4}=8)\lor (\text{x1}=1\land \text{x2}=4\land \text{x3}=6\land \text{x4}=7)\lor (\text{x1}=2\land \text{x2}=3\land \text{x3}=4\land \text{x4}=9)\lor (\text{x1}=2\land \text{x2}=3\land \text{x3}=5\land \text{x4}=8)\lor (\text{x1}=2\land \text{x2}=3\land \text{x3}=6\land \text{x4}=7)\lor (\text{x1}=2\land \text{x2}=4\land \text{x3}=5\land \text{x4}=7)\lor (\text{x1}=3\land \text{x2}=4\land \text{x3}=5\land \text{x4}=6)$$
- 94,826
- 4
- 38
- 78