[Math] Dice probability with limited reroll

diceprobabilityprobability distributions

What is the probability of getting 2 successes when 3 dice are rolled once, and then one die is optionally rerolled?

$$
n = \text{Number of dice} = 3
$$
$$
p_s = \text{Single die success probability (when the face is 3 or more)} = \frac{1}{2}
$$
$$
k = \text{Number of successful die} \in 0, 1, 2, 3
$$
$$
P(n, k, p) = \binom{n}{k}p^k(1-p)^{n-k}
$$


The probability of getting 2 success $(k=2)$ if each die is rolled only once $(p = p_s = \frac{1}{2})$ is
$$
P\left(3,\ 2,\ \frac{1}{2}\right) = \binom{3}{2}\left(\frac{1}{2}\right)^2\left(1-\frac{1}{2}\right)^{3-2} = \frac{3}{8} = 0.375
$$


If we have the option to reroll any failed die once, then
$$
p = p_s + (1-p_s)p_s = \frac{3}{4}\\
$$
and
$$
P\left(3,\ 2,\ \frac{3}{4}\right) = \binom{3}{2}\left(\frac{3}{4}\right)^2\left(1-\frac{3}{4}\right)^{3-2} = \frac{27}{64} = 0.421875
$$


Following the principles from this answer: Fair and Unfair coin Probability

Out of the 3 dice, 2 $(n_{1,2} = 2)$ are rolled once $(p_{1,2} = p_s = \frac{1}{2})$ and 1 die $(n_3 = 1)$ is rolled twice $(p_3 = p_s + (1 – p_s)p_s = \frac{3}{4})$

The probability of rolling 2 successes when all three dice are rolled and then one is rerolled is:
$$P(\text{Rolling 2 successes on the 1-roll dice})\times P(\text{Rolling 0 successes on the 2-roll die})$$
$$+\ P(\text{Rolling 1 success on the 1-roll dice})\times P(\text{Rolling 1 success on the 2-roll die})$$
$$= P\left(2,\ 2,\ \frac{1}{2}\right)\cdot P\left(1,\ 0,\ \frac{3}{4}\right) + P\left(2,\ 1,\ \frac{1}{2}\right)\cdot P\left(1,\ 1,\ \frac{3}{4}\right)$$
$$= \binom{2}{2}\left(\frac{1}{2}\right)^2\left(1 – \frac{1}{2}\right)^{2 – 2}\cdot\binom{1}{0}\left(\frac{3}{4}\right)^0\left(1 – \frac{3}{4}\right)^{1 – 0}$$
$$ + \binom{2}{1}\left(\frac{1}{2}\right)^1\left(1 – \frac{1}{2}\right)^{2 – 1}\cdot\binom{1}{1}\left(\frac{3}{4}\right)^1\left(1 – \frac{3}{4}\right)^{1 – 1}$$
$$= \frac{7}{16} = 0.4375$$

However this seems wrong because it's greater than if I were to roll 3 dice with rerolling $P\left(3,\ 2,\ \frac{3}{4}\right) = \frac{27}{64} = 0.421875$

What am I missing?

Best Answer

It seems to me now that there was a misunderstanding regarding your first question. In that question, you didn't state that you stop if you get the desired number of successes on the first attempt ("What is the probability of having exactly $k$ successes from $n$ coins if all $n$ coins are flipped and there are $x$ successes, then $n - x$ coins are re-flipped to give the additional $k - x$ successes?") This (and the fact that you were expecting the success probabilities to add up to $1$) led me to think that you always reflip the failed coins, independent of the result of the first flip. Now I see from the fact that you had $P(2)=f(2)+\cdots$ instead of $P(2)=f(2)f(0)+\cdots$ and $P(1)=f(1)+\cdots$ instead of $P(1)=f(1)f(0)+\cdots$, and from the way you're now trying to apply my answer, that apparently you meant all along that you stop if the first flip gives you the $k$ successes.

In that case, my answer to that other question is wrong, and that also explains what's going wrong here: Your result $\frac{27}{64}$ is the probability to get exactly $2$ successes if all failed coins are reflipped, even if the first flip yielded exactly $2$ successes. This is less than the probability you actually want.