1

There will be 20 defense players and 20 offensive players.
in each room there are 2 players, if the choosing is random, what is the probability that there will not be a room in which there is one defense player and one offensive player?

there are $40 \choose 2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2 $ ways to orders the players to pair of 2,
but in the book they write that there are $40!\choose2^{20}*20!$
Why is that?

gbox
  • 13,645

4 Answers4

2

Imagine that the rooms are numbered $1,2,3,\dots,20$ and that in each room there is a bunk bed. Line up the $40$ people. First person gets top bunk, Room $1$. Second person gets bottom bunk, Room $1$. Third person gets top bunk, Room $2$. And so on. There are $40!$ equally likely room and bunk assignments.

Now we count the number of room and bunk assignments in which people in the same room are of the same type. The rooms for the offensive players can be chosen in $\binom{20}{10}$ ways. For each choice the players can be assigned to rooms and bunks in $20!$ ways. And then the defensive players can be assigned to rooms and bunks in $20!$ ways. That yields probability $\frac{\binom{20}{10}20!20!}{40!}$.

Another way: We could still keep the rooms numbered, but forget about the bunks. Then instead of factorials we get multinomial coefficients. The denominator gets divided by $2^{20}$. Each $20!$ in the numerator gets divided by $2^{10}$.

André Nicolas
  • 514,336
  • Andre so why multiply the ways to makes pairs of 40 in 20! because there are 20! ways of ordering rooms? – gbox Jun 17 '14 at 16:30
  • Once we choose the rooms to be occupied by the offense, we must assign offensive players to rooms and bunks. What we need to do is make sure that in numerator and denominator we are counting the same sort of thing. Since I am using $40!$ (all permutations) in the denominator, I must have all "favourable" permutations on top. We took a counting approach since that's the sort of thing you were using. But note that Ross Millikan's direct solution is in my opinion better. – André Nicolas Jun 17 '14 at 16:38
  • Yes, you are right. Lost the not. – André Nicolas Jun 17 '14 at 19:49
  • There's a direct argument that the answer should be $\frac{\binom{20}{10}}{\binom{40}{20}}$. Put the kids in their rooms before assigning positions. Then $\binom{20}{10}$ is the number of ways to assign the positions by room, and $\binom{40}{20}$ is the total ways to assign the positions. – Thomas Andrews Jun 17 '14 at 20:06
  • Indeed there is. I wanted to stick a little closer to the spirit of OP's approach, first doing the full permutations, and then dividing by appropriate powers of $2$ to get to OP's denominator. – André Nicolas Jun 17 '14 at 20:16
2

There are $\frac{40!}{2^{20}}$ ways to put the players into the rooms, with no conditions.

If we were to put the defensive with the defensive, there are $\binom{20}{10}$ ways to pick the rooms for the defensive men, and then $\frac{20!}{2^{10}}$ ways to put the defensivement in those rooms, and $\frac{20!}{2^{10}}$ ways to put the offensive men in the other rooms, for a total of:

$$\binom{20}{10}\frac{20!20!}{2^{20}}$$

That means that the probability should be $$\frac{\binom{20}{10}\frac{20!20!}{2^{20}}}{\frac{40!}{2^{20}}}=\frac{20!^3}{10!10!40!}\approx 1.3\times 10^{-6}$$

More general, in a team with $2a$ offensive and $2b$ defensive, and $a+b$ rooms, you'd get:

$$\frac{(2a+2b)!}{2^{a+b}}$$ different ways of putting the players in the room, and $$\binom{a+b}{a}\frac{(2a)!}{2^a}\frac{(2b)!}{2^b}$$ different ways up putting the payers together by type, yielding a probability of:

$$\frac{(a+b)!(2a)!(2b)!}{a!b!(2a+2b)!}$$

In your case, $a=b=10$.

Even more generally, if each room holds $k$ players, and you have $m$ positions with $ka_i$ players of position $i=1,\dots,m$, then the number of ways of arbitrarily rooming the players is:

$$\frac{(k(a_1+\dots+a_m))!}{(k!)^{a_1+\dots+a_m}}$$

The number of ways of picking the rooms with each room having only players of one position is:

$$\binom{a_1+\dots+a_m}{a_1,\dots,a_m}\prod_{i=1}^m \frac{(ka_i)!}{(k!)^{a_i}}$$

Taking the ratio, we get:

$$\frac{(a_1+\dots+a_m)!(ka_1)!(ka_2)!\dots(ka_m)!}{(k(a_1+\dots+a_m))!a_1!\dots a_m!}$$

If $n=a_1+\dots a_m$ is the number of rooms, then this is:

$$\frac{\binom{n}{a_1,\dots,a_m}}{\binom{kn}{ka_1,\dots,ka_m}}$$

That's an interesting formula. The way to think of it is in terms of assigning the players positions after their rooms. There are $\binom{kn}{ka_1,\dots,ka_m}$ ways to assign the positions, total, but once the players are put in the rooms, if the condition is that each room must contain players of one type, then there are $\binom{n}{a_1,\dots,a_m}$ ways of assigning the positions to the players that match the room assignments.

Thomas Andrews
  • 186,215
1

You ask about probability, which should be less than $1.$ What you quote from the book looks like the number of arrangements. For your question, pick somebody to be the first in the first room. When you pick a person to put with him, the chance he is the other type is $\frac {20}{39}$ Assuming you succeed, in the next room, again put somebody, pick a second who will be the other type with probability $\frac {19}{37}$ At the end, you have a chance of success of $\frac {20\cdot 19 \cdot 18 \dots 1}{39 \cdot 37 \cdot 35 \dots 1}=\frac {20!}{39!!}\approx 7.6 \cdot 10^{-6}$

Added: the above calculated the chance that every room had one offensive and one defensive player. The question wants every room to have a matched pair. If we line all the players up, there are $40!$ ways to do that. Of those, we have ${20 \choose 10}$ ways to choose the rooms that will get offensive players, then $20!$ ways to put them in order, and $20!$ ways to put the defensive players in order, giving $\frac {{20 \choose 10}20!^2}{40!}\approx 1.34 \cdot 10^{-6}$. It seems reasonable that this is close to and smaller than the first calculation. When the first player is selected, he has a little less than (instead of a little more than) $\frac 12$ chance of being paired correctly.

Ross Millikan
  • 383,099
  • I did not get to the stage of probability I just do not get why if we know the number of option to put 40 players into a room of 2, why do we need to multiply it by 20!? – gbox Jun 17 '14 at 16:27
  • 1
    @Ross You've found the probability that all of the pairs are "Offence & Defence". I understood the question as asking for the chance that none of the pairs are "Offence & Defence". –  Jun 17 '14 at 18:37
  • @ByronSchmuland: you are correct. I'll add that in. – Ross Millikan Jun 17 '14 at 19:30
  • Interestingly, there is a reason the result is $$\frac{\binom{20}{10}}{\binom{40}{20}}$$ Essentially, this counts the other direction: after assigning the rooms first, if you assign "defensive" or "offensive" to the players, what is the probability that you get each room having only one position. See my answer for the generalization. – Thomas Andrews Jun 17 '14 at 19:51
  • Just for future readers, you really should make clear you are answering the wrong question in the first paragraph before you give that answer. It's legal to edit the beginning of the question... – Thomas Andrews Jun 17 '14 at 19:59
1

I am going to attempt this problem over multiple cases:

  1. All players and all rooms are distinct.

That means each player can be labelled a number $i$ and each room a number $j$ in which case there are $ 40 * 39 * 38... = 40!$ ways to arrange them but since we have over counted (the order we introduce the players in appears to affect the result) we must divide this by (2!) to get

$$\frac{40!}{2^{20}}$$

The number of cases in which there is NOT one defensive or Offense player in the same room is given by:

$$ 20 * 19 * 18 ... = 20! $$ ways to fill up 10 rooms with all defensive players (again divide by 2! to account for overcounting) so $\frac{20!}{2!^{10}10!}$

$$ \frac{20!}{10!10!} = 20_choose K $$ ways to select 10 rooms to be filled with defensive the players

$$ 20* 19 * 19 ... = 20! $$ ways to fill up the remaining rooms with offensive players (again divide by 2! to account for overcounting) so $\frac{20!}{2!^{10}10!}$

Therefore there are : $(\frac{20!^3}{2^{20}*10!^2}) $ ways to fill up the rooms and ensure that there is no room with one defensive and one offensive player.

Thus: the probability that no rooms have a defensive or offensive player is given by:

$$ \frac{\frac{20!^3}{2^{20}10!^4}}{\frac{40!}{2^{20}}} =\frac{20!^3}{ 40!10!^2} $$ 2. Players within their respective groups (defense and offense) are NOT distinct but rooms are all distinct.