During my research, I had encountered the following issue. Consider the equation $$\sum_{k=1}^K\alpha_k P_k = P$$
where $\sum_{k=1}^K\alpha_k=1$, $\alpha_k > 0$, $P_k > 0, P>0$.
So you are given $\{\alpha_k\}$, $K$ and $P$. The task is to generate randomly $\{P_k\}$ such that the above equation is satisfied. I am looking for an efficient way to generate these numbers.
My strategy
I have one method. Basically, we generate $K$ distinct uniform numbers between $(0,1)$. Call them $\{b_k\}$. Then we compute $\sum_{k=1}^K\alpha_k b_k = B$. Now the sequence $\{\frac{b_kP}{B}\}$ is the desired sequence.
However, if you observe, using this method, $P_k$ can never exceed $P$ and in my work, I require some of the values to exceed $P$. E.g. if $\alpha_1=0.5, \alpha_2=0.5$, even $(2P,0)$ is a valid solution.
Is there a way to generate these numbers so as to circumvent this issue?
Update: Given $\{\alpha_k\}$, it follows that $P_k \leq P/\alpha_{\min}$. Note: The above counter example is not valid. Apparently the algorithm works fine.