PROFESSOR: So let's do a basic example
of counting that illustrates the use
of these new generalized rules of the Division
Rule and the Generalized Product Rule.
And let's count some particular kind of poker hands
called a 2-pair.
So poker is a game where each player is dealt five cards
from a deck of 52 cards.
And the definition of a 2-pair hand
is that there are 2 cards of some rank.
The ranks are Ace, Deuce, up through King,
so the ranks are 13 possible ranks.
Ace is 1, 2, 3, up through 10, and then Jack, Queen, King
is 11, 12, 13.
So there are 13 possible ranks.
We're going to choose 2 cards of some rank-- that's
called a pair.
Then we're going to choose 2 cards of a different rank--
a second rank.
And finally, we're going to choose
a card of still a third rank.
So I get a pair, and another pair,
and another card that does not match the ranks of either
of the first two.
And that is the definition of a hand that,
in poker, is called 2-pair.
Let's take an example.
Here's a typical 2-pair hand.
I've got 2 Kings.
They both have rank 13.
One is a King of Diamonds, the other is a King of Hearts.
There are four of these suits, so-called-- Diamonds, Hearts,
Spades, Clubs.
There are 2 Aces, a pair of Aces.
One is an Ace of Diamonds, the other's an Ace of Spades.
And finally, there hanging loose, this third rank
that doesn't match the Kings or the Aces-- namely a 3 of Clubs.
Now, the way that I'm going to propose
to count the number of 2-pair hands
is to think about it this way.
I'm going to begin by choosing the rank for the first pair,
and there are 13 possible ranks that the first pair might have.
Once I've fixed the rank for the first pair,
the second pair has to have a different rank.
So there are 12 ranks left.
And once I've picked the ranks for the 2 pairs,
then I have the rank of the last card,
which is 11 possible choices.
Then, in addition, once I've chosen
the rank of the first pair, the rank of the second pair,
and the rank of the loose card, the fifth card,
I select a pair of suits to go for the first pair.
So let's say if the first pair, I've figured out we're
going to be 2 Aces.
Which two aces should they be?
Well, pick two of the four suits.
And there are four choose two ways to choose
the suits for the pair of aces.
Likewise, there are four choose two ways to choose the two
suits for the pair of kings.
And finally, there are four possible suits
I can choose for the rank of the last card.
So that says that I might, for example, specify
a two-pair hand by saying, OK, let's
choose a pair of kings to come first and a pair of aces
to be the second pair and a three to be the loose card.
Let's choose the set of two elements diamonds
and hearts for the kings, the two elements
diamonds and spades for the aces, and a club for the three.
This sequence of choices specifies
exactly the two-pair hand that we illustrated
on the previous slide, namely two kings, a diamond
and a hearts; two aces, a diamond and a space;
and the three of clubs.
So I can count the number of two-pair her hands fairly
straightforwardly.
There were 13 choices for the rank of the first pair,
12 for the second, 11 for the rank of the third card,
four choose way to choose the suits of the first pair,
four choose way to choose two ways to choose
the suits of the second pair, and four ways
to choose the suits for the last pair.
So this is the total-- 13 times 12 times 11 times 4 choose 2
twice times 4.
And that's not right.
There's a bug.
What's the bug?
Well, the problem is that what I've
described in this number on the previous slide, that number,
is exactly the set of six tuples,
consisting of the first card ranks and the second card ranks
and the last card rank and the first card suits
and the second card suits and the last card suit.
That is, if it's counting the number of possible ranks
for a first choice, the number of possible
ranks for a second choice, third,
and so on, this set of six things
are being counted correctly by the formula
on the previous page.
The difficulty is that counting these six tuples
is not the same as counting the number of two-pair hands.
We've counted the number of six tuples of this kind correctly,
but not the number of two-pair, because this mapping
from six tuples to two-pair hands is not a bijection.
Namely, if I look at the six tuple,
choose kings and then aces and a three
with these suits and those suits and final suit
for the three, which determines this hand-- the king
of diamonds, king of hearts, ace of diamonds, ace of spades,
three of clubs-- there's another six tuple that
would also yield the same hand.
Namely, what I can do is I'll keep
the three of clubs specified.
But instead of choosing the kings and their suits
and the aces and their suits, I'll
choose the aces and their suits and the kings and their suits.
So I'm just switching these two entries and those two entries.
And if I do that, here's a different six tuple
that's specifying the same two-pair hand.
That is, this tuple is specifying
a pair of aces and a pair of kings, where the aces have
suits diamonds spades and the kings have suits diamonds
hearts and the three has suits clubs.
So the bug in our reasoning was that when we were counting
and we said there are 13 possible ranks
for the first pair and there are 12
possible ranks for the second pair
and we were distinguishing the first pair
from the second pair, that was a mistake.
There isn't any first pair and second pair.
There are simply two pairs.
And there's no way to tell which is first
and which is second, which is why
we got two different ways from our sextuples of mapping
to the same two-pair, depending in the sextuple which
of the two-pair I wanted to list first.
So in fact, since either pair might be first
what I get is this map, from six tuples to two-pair hands,
is actually a two-to-one mapping.
It's not a bijection, because there's
no difference between the first pair and the second pair.
There's just a couple of pair.
If I do that, then I can fix this formula.
Now that I realize that the mapping from these six
tuples, which I've counted correctly
to the things I want to count-- namely, the two-pair hands-- is
two to one, then, by the generalized product rule,
or by the division rule, all I need to do
is divide this number by a half.
And that is really the answer of the number of two-pair hands.