|
For each position in the deck, indexed by the number of cards m cards dealt so far, compute the probability of a correct guess. By linearity, the desired expectation is the sum of these probabilities.
Given that we have seen m cards so far, the probability that exactly k were red is
p[n, m, k] = Binomial[m, k]Binomial[2n - m, n - k]/Binomial[2n, n]
in which case we will guess correctly with probability
q[n, m, k] = If[k <= m/2, n - k, n - m + k]/(2n - m)
Summing over k (0 to m in the first half of the deck, and m - n to n in the second half) and m yields the expected number of correct guesses:
Sum[ Sum[ p[n, m, k]q[n, m, k], {k, Max[0, m - n], Min[m, n]} ], {m, 0, 2n - 1} ]
For a standard deck/(2n - m)
Summing over k (0 to m in the first half of the deck, and m - n to n in the second half) and m yields the expected number of correct guesses:
Sum[ Sum/(2n - m)
Summing over k (0 to m in the first half of the deck, and m - n to n in the second half) and m yields the expected number of correct guesses:
Sum[ Sum[ p[n, m, k]q[n, m, k], {k, Max[0, m - n], Min[m, n]} ], {m, 0, 2n - 1} ]
For a standard deck/(2n - m)
Summing over k (0 to m in the first half of the deck, and m - n to n in the second half) and m yields the expected number of correct guesses:
Sum[ Sum[ p[n, m, k]q[n, m, k], {k, Max[0, m - n], Min[m, n]} ], {m, 0, 2n - 1} ]
For a standard deck of 52 cards (n = 26), expect to guess 30.0407 correctly on average, or 57.7705%.
ObPuzzle: Is it possible to guess _less_ than half correctly?
Eric Farmer
|