Probability given pairs

14 Views Asked by At

I have a list of numbers (1 - p) except I have every number twice. Given a random subset of these numbers (say length q). What is the probability that I have a duplicate number?

Thanks

1

There are 1 best solutions below

0
On BEST ANSWER

So we have two copies of $1$, two copies of $2$, and so on up to two copies of $p$, a total of $2p$ objects. Given any pair of identical numbers, paint one of them green and the other red to make them distinct. Note that for sure there will be a duplicate if $q\gt p$. So from now on assume that $q\le p$.

There are $\binom{2p}{q}$ equally likely ways to choose a sample of $q$.

We find the number of ways to have no duplicate. The types of numbers that we pick can be chosen in $\binom{p}{q}$ ways. For each selection of types, the colours we use can be chosen in $2^q$ ways, for a total of $\binom{p}{q}2^q$.

Thus the probability of no duplicate is $\dfrac{\binom{p}{q}2^q}{\binom{2p}{q}}$.