There is a game where you need to gather money from people participating to it and when you have the total you need to divide it in order to put a "reasonable amount" for each of the n prizes they will be able to win.
E.g. in general we usually make the calcution approximately, so in case you have a total of 8$ (t = 8) and 5 prizes (n = 5) we could divide the total into:
- prize 1:
0.8$ - prize 2:
1.2$ - prize 3:
1.5$ - prize 4:
1.9$ - prize 5:
2.6$
As you can see it would be important to have prize n to be "more important" than prize 1, in general.
I would like to find a rule to obtain those prize values dynamically according to:
t = total amount of moneyn = number of prizesy = a variable factor to provide in order to abtain different combinations of prize values, in a way that a lower 'y' value means being more "fair" in giving values to prizes, on the contrary a higher 'y' value means increasing the difference between prize 1 and prize 'n'
E.g. in case I want to be more "fair" a possibility would be:
- prize 1:
1.2$ - prize 2:
1.4$ - prize 3:
1.6$ - prize 4:
1.8$ - prize 5:
2.0$
or
- prize 1:
1.1$ - prize 2:
1.2$ - prize 3:
1.5$ - prize 4:
2.0$ - prize 5:
2.2$
but I really have no idea about what formula or algorithm I could use to make that calculation by simply having as input (y, n and t) and how to be able to provide a y factor to use in order to vary the resulting prize values.
Any idea about it?
Thanks
Here's a possibility:
Set the $k$th prize to be $$ C r^{k-1} $$ for some value of $C$, where $r = 1 + y$. For $y = 0$, you get all prizes the same; for $y = 1$, each prize is double the previous one. For $y = 0.1$, you get something like the values you had.
Of course, to complete this, I have to give a value for $C$. But we know that the sum of all the prizes has to be $$ C(1 + r + \ldots + r^{n-1}) = C \frac{1-r^n}{1-r} $$ and we want this sum to be the total $t$. That means that $$ C = t \frac{1-r}{1-r^n}. $$ The formula for the $k$th prize, where $k$ goes from $1$ to $n$ is thus \begin{align} p_k &= t\, r^{k-1} \frac{1-r}{1-r^n}\\ &= t\, (1+y)^{k-1} \frac{y}{(1+y)^n - 1} \end{align}
If I were writing a program, I'd compute $r = 1+y$ first, and then use the first form rather than the second, but that's a matter of taste.