6
$\begingroup$

Cards are drawn one by one from a regular deck ($13$ cards for each of the $4$ suits). If $7$ cards are drawn, what is the probability that no suit will be missing?

Ok, so I tried the approach where I choose the $1$ suit out of $4$ and then I don't know what do next. I dont know how am I supposed to arrange the cards in such a random manner, and I found the total which is obvious, $52$ choose $7$.

$\endgroup$
0

4 Answers 4

4
$\begingroup$

There are $4$ conditions, one for each suit that needs to be included. The number of (unordered) draws that violate $k$ particular conditions is $\binom{13(4-k)}7$, so by inclusion-exclusion the desired probability is

\begin{align} \binom{52}7^{-1}\sum_{k=0}^3(-1)^k\binom4k\binom{13(4-k)}7 &= \binom{52}7^{-1}\left(\binom{52}7-4\binom{39}7+6\binom{26}7-4\binom{13}7\right) \\ &= \frac{63713}{111860} \\ &\approx57\%\;. \end{align}

$\endgroup$
1
  • 1
    $\begingroup$ Nice answer (will undoubtedly percolate to the top). Very intuitive and easy to understand. (+1.) $\endgroup$ Commented Jul 21, 2016 at 22:46
2
$\begingroup$

Observe that the generating function of these cards is given by

$$(A_1+A_2+\cdots+A_{13})(X_1+X_2+X_3+X_4).$$

It follows by the Polya Enumeration Theorem (set operator) that the generating function of seven cards being chosen from these is

$$Z(P_7)((A_1+A_2+\cdots+A_{13})(X_1+X_2+X_3+X_4))$$

where $Z(P_7)$ is the cycle index of the set operator acting on seven slots.

Now using Inclusion-Exclusion to remove those terms where some suits are missing we get

$$\sum_{S\subseteq X} (-1)^{|S|} \left.Z(P_7)((A_1+A_2+\cdots+A_{13})(X_1+X_2+X_3+X_4))\right|_{S=0}.$$

The substitution rule for the cycle index says that we use

$$a_d = (A_1^d+A_2^d+\cdots+A_{13}^d)(X_1^d+X_2^d+X_3^d+X_4^d).$$

This yields

$$a_d = 13 \times (4-|S|).$$

We thus obtain

$$\sum_{k=0}^4 {4\choose k} (-1)^k Z(P_7)_{a_d = 13(4-k)}.$$

The cycle index in question is

$$Z(P_7) = {\frac {{a_{{1}}}^{7}}{5040}}-{\frac {{a_{{1}}}^{5}a_{{2}}}{ 240}}+{\frac {{a_{{1}}}^{4}a_{{3}}}{72}}+1/48\,{a_{{1}}}^{3}{a _{{2}}}^{2}\\ -1/24\,{a_{{1}}}^{3}a_{{4}}-1/12\,{a_{{1}}}^{2}a_{{ 2}}a_{{3}}-1/48\,a_{{1}}{a_{{2}}}^{3}+1/10\,{a_{{1}}}^{2}a_{{5 }}\\+1/8\,a_{{1}}a_{{2}}a_{{4}} +1/18\,a_{{1}}{a_{{3}}}^{2}+1/24 \,{a_{{2}}}^{2}a_{{3}}-1/6\,a_{{1}}a_{{6}}\\ -1/10\,a_{{2}}a_{{5} }-1/12\,a_{{3}}a_{{4}}+1/7\,a_{{7}}.$$

We get $76200748$ favorable cases for a probability of

$$76200748 \times {52\choose 7}^{-1} = {\frac {63713}{111860}} \approx 0.5695780440.$$

The Maple code for this was as follows.

pet_cycleind_set :=
proc(n)
local p, s;
option remember;

    if n=0 then return 1; fi;

    expand(1/n*add((-1)^(l-1)*a[l]*
                   pet_cycleind_set(n-l), l=1..n));
end;

X :=
proc()
    option remember;
    local k, res, ind, subsl;

    ind := pet_cycleind_set(7);

    res := 0;

    for k from 0 to 4 do
        subsl := [seq(a[d]=13*(4-k), d=1..7)];

        res := res +
        binomial(4,k)*(-1)^k*subs(subsl, ind);
    od;

    res;
end;

The set operator was documented at this MSE link and the inclusion-exclusion argument at this MSE link II.

It appears this problem is just simple enough to be treated by total enumeration. The following Perl script does this, using about twenty-five minutes of computation time to produce the answer $$76200748.$$

#! /usr/bin/perl -w
#

sub choose {
    my ($src, $sofar, $fref) = @_;

    my $sel = scalar(@$sofar);

    if($sel == 7){
        my %suits = ();

        @suits{ map { $src->[$_]->[0] }
                @$sofar } = (1) x 7;

        $$fref++ if scalar(keys(%suits)) == 4;
        return;
    }

    my $base = 0;
    $base = $sofar->[-1] + 1 if $sel > 0;

    for(my $idx = $base; $idx < 52; $idx++){
        push @$sofar, $idx;
        choose($src, $sofar, $fref);
        pop @$sofar;
    }

    return;
}

MAIN : {
    $| = 1;

    my $cards = [];

    for(my $suit = 1; $suit <= 4; $suit++){
        for(my $card = 1; $card <= 13; $card++){
            push @$cards, [$suit, $card];
        }
    }

    my $favorable = 0;
    choose($cards, [], \$favorable);

    print "$favorable\n";
}
$\endgroup$
0
$\begingroup$

Calculate the number of ways to chose a 7 cards of different suits over the total number of ways to choose 7 cards from 52 and think of the various ways to do this. For example, say you draw 4 cards of one suit and then 3 of unique suits. You then have ${4 \choose 1}{13 \choose 4}13^3$. The ${4 \choose 1}$ is because there are 4 suits for which this can happen,${13 \choose 4}$ is the ways to choose 4 cards from the 13 per suit, and the $13^3$ accounts for the ways to pick one card from the remaining sets of 13 per suit. Now repeat this pattern, but account for how many different cards can be picked in order for your condition to be true. So for 3 cards being picked from one suit, and then the remaining 4 from different suits you have ${4 \choose 1}{13 \choose 3}{13 \choose 2}(13^2)$ and ${4 \choose 1}{13 \choose 2}^3(13)$. Adding all of these together and putting them over the number of ways to select 7 cards from 52. This gets you the probability $\frac{{4 \choose 1}{13 \choose 4}13^3 + {4 \choose 1}{13 \choose 3}{13 \choose 2}(13^2) + {4 \choose 1}{13 \choose 2}^3(13)}{{52 \choose 7}}$.

$\endgroup$
1
  • 1
    $\begingroup$ The $3$-$2$-$1$-$1$ case looks as if there may be a missing $\binom{3}{1}$. $\endgroup$ Commented Jul 21, 2016 at 20:10
0
$\begingroup$

That is $= 1-P$(one of the suits not included); for that we have $4$ scenarios for each suit(spades, clubs, hearts, and diamonds) and in each scenario we will take into consideration the previous ones. First lets get P1(spades not included)$= \frac{{39\choose 7}}{{52 \choose 7}}$. Now lets get $P_2$(clubs not included), but here notice in the previous one we already took into consideration the scenario where the chosen ones are just from hearts and/or diamonds which is included in ${39\choose 7}$. So to get rid of that we should subtract ${26\choose 7}$ ; then for P(spades not included)$=$ $\frac{{39\choose 7}-{26\choose 7}}{{52 \choose 7}}$. Now lets calculate $P_3$(hearts not included) , and here again we already took into consideration the scenario where the chosen ones are just from clubs and/or diamonds in $P_1$, and where the chosen ones are just from spades and/or diamonds in $P_2$. So we should subtract $ {26\choose 7}$ 2 times; but notice the scenario where the chosen ones are just from diamonds is removed twice so we add $ {13\choose 7}$ ; then $P_3$(hearts not included)$=$ $\frac{{39\choose 7}-2{26\choose 7}+{13\choose 7}}{{52 \choose 7}}$. Finally, lets calculate $P_4$(diamonds not included), and as in the previous ones we already took into consideration the scenario where the chosen ones are just from clubs and/or hearts in $P_1$, and where the chosen ones are just from spades and/or hearts in $P_2$,and where the chosen ones are just from spades and/or clubs in $P_3$. So we should subtract $ {26\choose 7}$ 3 times, and add$ {13\choose 7}$ 3 times, since each of (hearts, clubs, spades) was removed twice; thus $P_4$(diamonds not included)$=$ $\frac{{39\choose 7}-3{26\choose 7}+3{13\choose 7}}{{52 \choose 7}}$. Adding all probabilities we get $P$(one of the suits not included)$= 0.43$. So, answer $= 1-0.43= 0.57$.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .