Analyzing the Setup
Imagine you are standing in front of a magical candy shop. You have 21 identical candies, and you need to distribute them among three friends: x, y, and z.
There is a social contract: friend x must receive at least 1 candy, friend y must receive at least 3, and friend z must receive at least 4. We seek the number of ways to distribute these candies under these constraints.
The Constraint Trap
When we look at the equation x+y+z=21, our instinct might be to jump straight to the 'Stars and Bars' formula. However, the standard formula (r−1n+r−1) is a perfectionist.
It only works when your variables are non-negative, meaning x,y,z≥0. Because our variables are restricted (x≥1, y≥3, and z≥4), we must liberate our variables from these constraints to avoid counting physically impossible scenarios.
The Substitution Strategy
To solve this, we use a technique called 'pre-allocation.' We define new variables, x′, y′, and z′, which represent the 'extra' candies each friend receives beyond their minimum requirement.
We set the following substitutions:
x=x′+1
y=y′+3
z=z′+4
Since x≥1, it follows that x′+1≥1, which simplifies to x′≥0. The same logic applies to y′ and z′, successfully transforming our constrained variables into non-negative ones.
The Transformation
Now, let us substitute these into our original equation:
(x′+1)+(y′+3)+(z′+4)=21
If we group the constants, we get:
x′+y′+z′+8=21
Subtracting
8 from both sides, we arrive at the simplified equation:
x′+y′+z′=13
This is the heart of the problem. We are now distributing 13 candies among 3 friends with no restrictions other than that they must receive a non-negative amount.
The Final Calculation
We are ready for the 'Stars and Bars' theorem. Here, n=13 (the remaining candies) and r=3 (the number of friends).
The formula is
(r−1n+r−1), which becomes:
(3−113+3−1)=(215)
Calculating this is straightforward:
(215)=2×115×14=15×7=105
There you have it! By respecting the constraints and transforming the problem, we found that there are exactly 105 ways to satisfy the conditions. Remember, in the JEE, the most complex problems are often just simple problems wearing a disguise.