Probability of extracting k different coloured balls in a sample of m>k balls.
$begingroup$
I am having some problems with the next excercise:
Suppose an urn with balls of only six different colours where the chances to obtain each colour is exactly the same for all of them in each extraction. i.e, the probabiblity doesn't change from one iteration to the next one.
Now, let's extract a sample of 10 balls and compute the probability of obtaining the six different colours in it.
This might be a dumb question but I have no idea about how to proceed. Please, help me.
probability probability-theory statistics probability-distributions
$endgroup$
add a comment |
$begingroup$
I am having some problems with the next excercise:
Suppose an urn with balls of only six different colours where the chances to obtain each colour is exactly the same for all of them in each extraction. i.e, the probabiblity doesn't change from one iteration to the next one.
Now, let's extract a sample of 10 balls and compute the probability of obtaining the six different colours in it.
This might be a dumb question but I have no idea about how to proceed. Please, help me.
probability probability-theory statistics probability-distributions
$endgroup$
$begingroup$
Well, the first thing to notice is that every possible sequence of colors has the same probability, $6^{-10},$ so the problem is simply to count the sequences that have at least one of each color.
$endgroup$
– saulspatz
Dec 6 '18 at 20:03
$begingroup$
Yes. But that is exactly where I have the problem. I don't know how to find out how many favorable cases are there.
$endgroup$
– Israel Barquín
Dec 6 '18 at 21:35
$begingroup$
There are ten balls. Six of them are of different colors. That leaves only four balls to account for. Try writing down the possibilities.
$endgroup$
– saulspatz
Dec 6 '18 at 22:36
add a comment |
$begingroup$
I am having some problems with the next excercise:
Suppose an urn with balls of only six different colours where the chances to obtain each colour is exactly the same for all of them in each extraction. i.e, the probabiblity doesn't change from one iteration to the next one.
Now, let's extract a sample of 10 balls and compute the probability of obtaining the six different colours in it.
This might be a dumb question but I have no idea about how to proceed. Please, help me.
probability probability-theory statistics probability-distributions
$endgroup$
I am having some problems with the next excercise:
Suppose an urn with balls of only six different colours where the chances to obtain each colour is exactly the same for all of them in each extraction. i.e, the probabiblity doesn't change from one iteration to the next one.
Now, let's extract a sample of 10 balls and compute the probability of obtaining the six different colours in it.
This might be a dumb question but I have no idea about how to proceed. Please, help me.
probability probability-theory statistics probability-distributions
probability probability-theory statistics probability-distributions
asked Dec 6 '18 at 19:41
Israel BarquínIsrael Barquín
276
276
$begingroup$
Well, the first thing to notice is that every possible sequence of colors has the same probability, $6^{-10},$ so the problem is simply to count the sequences that have at least one of each color.
$endgroup$
– saulspatz
Dec 6 '18 at 20:03
$begingroup$
Yes. But that is exactly where I have the problem. I don't know how to find out how many favorable cases are there.
$endgroup$
– Israel Barquín
Dec 6 '18 at 21:35
$begingroup$
There are ten balls. Six of them are of different colors. That leaves only four balls to account for. Try writing down the possibilities.
$endgroup$
– saulspatz
Dec 6 '18 at 22:36
add a comment |
$begingroup$
Well, the first thing to notice is that every possible sequence of colors has the same probability, $6^{-10},$ so the problem is simply to count the sequences that have at least one of each color.
$endgroup$
– saulspatz
Dec 6 '18 at 20:03
$begingroup$
Yes. But that is exactly where I have the problem. I don't know how to find out how many favorable cases are there.
$endgroup$
– Israel Barquín
Dec 6 '18 at 21:35
$begingroup$
There are ten balls. Six of them are of different colors. That leaves only four balls to account for. Try writing down the possibilities.
$endgroup$
– saulspatz
Dec 6 '18 at 22:36
$begingroup$
Well, the first thing to notice is that every possible sequence of colors has the same probability, $6^{-10},$ so the problem is simply to count the sequences that have at least one of each color.
$endgroup$
– saulspatz
Dec 6 '18 at 20:03
$begingroup$
Well, the first thing to notice is that every possible sequence of colors has the same probability, $6^{-10},$ so the problem is simply to count the sequences that have at least one of each color.
$endgroup$
– saulspatz
Dec 6 '18 at 20:03
$begingroup$
Yes. But that is exactly where I have the problem. I don't know how to find out how many favorable cases are there.
$endgroup$
– Israel Barquín
Dec 6 '18 at 21:35
$begingroup$
Yes. But that is exactly where I have the problem. I don't know how to find out how many favorable cases are there.
$endgroup$
– Israel Barquín
Dec 6 '18 at 21:35
$begingroup$
There are ten balls. Six of them are of different colors. That leaves only four balls to account for. Try writing down the possibilities.
$endgroup$
– saulspatz
Dec 6 '18 at 22:36
$begingroup$
There are ten balls. Six of them are of different colors. That leaves only four balls to account for. Try writing down the possibilities.
$endgroup$
– saulspatz
Dec 6 '18 at 22:36
add a comment |
2 Answers
2
active
oldest
votes
$begingroup$
This is an example of the famous coupon collector's problem which is part of a more general probability problem called the classical occupancy problem. It can be reframed as follows:
Suppose we have $n=10$ balls and $m=6$ (coloured) bins. We allocate the balls to the bins at random. Find the distribution of the number of non-empty bins (classical occupancy problem), and the probability that all bins are non-empty (coupon collector's problem).
Let $K$ be the number of colours obtained from this allocation (i.e., the number of bins that are non-empty). The distribution of this random variable is the classical occupancy distribution which has mass function (see related question):
$$text{Occ}(k|n,m) = frac{(m)_k cdot S(n,k)}{m^n} quad quad text{for all } k = 1,2,..., min(n,m).$$
(In this expression the values $(m)_k = m (m-1) cdots (m-k+1)$ are the falling factorials and the values $S(n,k)$ are the Stirling numbers of the second kind.) For the coupon collector's problem we are interested in the probability that $K=m$, which is:
$$text{Occ}(m|n,m) = frac{m! cdot S(n,m)}{m^n} cdot mathbb{I}(m leqslant n).$$
For your particular problem the desired probability for the coupon collector's problem is:
$$text{Occ}(6|10,6) = frac{6! cdot S(10,6)}{6^{10}}
= frac{720 cdot 22827}{60466176}
= frac{16435440}{60466176}
= 0.2718121.$$
Confirming this by simulation: We can easily simulate the occupancy number in R
by simulating the underlying allocation problem. Taking $S = 10^6$ simulations gives the following sample proportions for the occupancy number.
#Simulate this problem S times
set.seed(1);
S <- 10^6;
BALLS <- array(ceiling(6*runif(10*S)), dim = c(S, 10));
#Count number of occupied bins
OCC <- rep(0, S);
for (s in 1:S) { OCC[s] <- dim(table(BALLS[s,])) }
#Show sample proportions of outcomes
table(OCC)/S;
OCC
2 3 4 5 6
0.000279 0.018522 0.203018 0.506310 0.271871
We can see that the proportion of cases where $K=6$ closely matches our probability calculation using the classical occupancy distribution.
$endgroup$
add a comment |
$begingroup$
Hint:
There are two approaches to counting the number before dividing by $6^{10}$
The labour-intensive way is by inclusion-exclusion
The quick way is to take a particular known value of Stirling numbers of the second kind, and multiply by a suitable factorial to take account of the colours being distinguishable
$endgroup$
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3028945%2fprobability-of-extracting-k-different-coloured-balls-in-a-sample-of-mk-balls%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
This is an example of the famous coupon collector's problem which is part of a more general probability problem called the classical occupancy problem. It can be reframed as follows:
Suppose we have $n=10$ balls and $m=6$ (coloured) bins. We allocate the balls to the bins at random. Find the distribution of the number of non-empty bins (classical occupancy problem), and the probability that all bins are non-empty (coupon collector's problem).
Let $K$ be the number of colours obtained from this allocation (i.e., the number of bins that are non-empty). The distribution of this random variable is the classical occupancy distribution which has mass function (see related question):
$$text{Occ}(k|n,m) = frac{(m)_k cdot S(n,k)}{m^n} quad quad text{for all } k = 1,2,..., min(n,m).$$
(In this expression the values $(m)_k = m (m-1) cdots (m-k+1)$ are the falling factorials and the values $S(n,k)$ are the Stirling numbers of the second kind.) For the coupon collector's problem we are interested in the probability that $K=m$, which is:
$$text{Occ}(m|n,m) = frac{m! cdot S(n,m)}{m^n} cdot mathbb{I}(m leqslant n).$$
For your particular problem the desired probability for the coupon collector's problem is:
$$text{Occ}(6|10,6) = frac{6! cdot S(10,6)}{6^{10}}
= frac{720 cdot 22827}{60466176}
= frac{16435440}{60466176}
= 0.2718121.$$
Confirming this by simulation: We can easily simulate the occupancy number in R
by simulating the underlying allocation problem. Taking $S = 10^6$ simulations gives the following sample proportions for the occupancy number.
#Simulate this problem S times
set.seed(1);
S <- 10^6;
BALLS <- array(ceiling(6*runif(10*S)), dim = c(S, 10));
#Count number of occupied bins
OCC <- rep(0, S);
for (s in 1:S) { OCC[s] <- dim(table(BALLS[s,])) }
#Show sample proportions of outcomes
table(OCC)/S;
OCC
2 3 4 5 6
0.000279 0.018522 0.203018 0.506310 0.271871
We can see that the proportion of cases where $K=6$ closely matches our probability calculation using the classical occupancy distribution.
$endgroup$
add a comment |
$begingroup$
This is an example of the famous coupon collector's problem which is part of a more general probability problem called the classical occupancy problem. It can be reframed as follows:
Suppose we have $n=10$ balls and $m=6$ (coloured) bins. We allocate the balls to the bins at random. Find the distribution of the number of non-empty bins (classical occupancy problem), and the probability that all bins are non-empty (coupon collector's problem).
Let $K$ be the number of colours obtained from this allocation (i.e., the number of bins that are non-empty). The distribution of this random variable is the classical occupancy distribution which has mass function (see related question):
$$text{Occ}(k|n,m) = frac{(m)_k cdot S(n,k)}{m^n} quad quad text{for all } k = 1,2,..., min(n,m).$$
(In this expression the values $(m)_k = m (m-1) cdots (m-k+1)$ are the falling factorials and the values $S(n,k)$ are the Stirling numbers of the second kind.) For the coupon collector's problem we are interested in the probability that $K=m$, which is:
$$text{Occ}(m|n,m) = frac{m! cdot S(n,m)}{m^n} cdot mathbb{I}(m leqslant n).$$
For your particular problem the desired probability for the coupon collector's problem is:
$$text{Occ}(6|10,6) = frac{6! cdot S(10,6)}{6^{10}}
= frac{720 cdot 22827}{60466176}
= frac{16435440}{60466176}
= 0.2718121.$$
Confirming this by simulation: We can easily simulate the occupancy number in R
by simulating the underlying allocation problem. Taking $S = 10^6$ simulations gives the following sample proportions for the occupancy number.
#Simulate this problem S times
set.seed(1);
S <- 10^6;
BALLS <- array(ceiling(6*runif(10*S)), dim = c(S, 10));
#Count number of occupied bins
OCC <- rep(0, S);
for (s in 1:S) { OCC[s] <- dim(table(BALLS[s,])) }
#Show sample proportions of outcomes
table(OCC)/S;
OCC
2 3 4 5 6
0.000279 0.018522 0.203018 0.506310 0.271871
We can see that the proportion of cases where $K=6$ closely matches our probability calculation using the classical occupancy distribution.
$endgroup$
add a comment |
$begingroup$
This is an example of the famous coupon collector's problem which is part of a more general probability problem called the classical occupancy problem. It can be reframed as follows:
Suppose we have $n=10$ balls and $m=6$ (coloured) bins. We allocate the balls to the bins at random. Find the distribution of the number of non-empty bins (classical occupancy problem), and the probability that all bins are non-empty (coupon collector's problem).
Let $K$ be the number of colours obtained from this allocation (i.e., the number of bins that are non-empty). The distribution of this random variable is the classical occupancy distribution which has mass function (see related question):
$$text{Occ}(k|n,m) = frac{(m)_k cdot S(n,k)}{m^n} quad quad text{for all } k = 1,2,..., min(n,m).$$
(In this expression the values $(m)_k = m (m-1) cdots (m-k+1)$ are the falling factorials and the values $S(n,k)$ are the Stirling numbers of the second kind.) For the coupon collector's problem we are interested in the probability that $K=m$, which is:
$$text{Occ}(m|n,m) = frac{m! cdot S(n,m)}{m^n} cdot mathbb{I}(m leqslant n).$$
For your particular problem the desired probability for the coupon collector's problem is:
$$text{Occ}(6|10,6) = frac{6! cdot S(10,6)}{6^{10}}
= frac{720 cdot 22827}{60466176}
= frac{16435440}{60466176}
= 0.2718121.$$
Confirming this by simulation: We can easily simulate the occupancy number in R
by simulating the underlying allocation problem. Taking $S = 10^6$ simulations gives the following sample proportions for the occupancy number.
#Simulate this problem S times
set.seed(1);
S <- 10^6;
BALLS <- array(ceiling(6*runif(10*S)), dim = c(S, 10));
#Count number of occupied bins
OCC <- rep(0, S);
for (s in 1:S) { OCC[s] <- dim(table(BALLS[s,])) }
#Show sample proportions of outcomes
table(OCC)/S;
OCC
2 3 4 5 6
0.000279 0.018522 0.203018 0.506310 0.271871
We can see that the proportion of cases where $K=6$ closely matches our probability calculation using the classical occupancy distribution.
$endgroup$
This is an example of the famous coupon collector's problem which is part of a more general probability problem called the classical occupancy problem. It can be reframed as follows:
Suppose we have $n=10$ balls and $m=6$ (coloured) bins. We allocate the balls to the bins at random. Find the distribution of the number of non-empty bins (classical occupancy problem), and the probability that all bins are non-empty (coupon collector's problem).
Let $K$ be the number of colours obtained from this allocation (i.e., the number of bins that are non-empty). The distribution of this random variable is the classical occupancy distribution which has mass function (see related question):
$$text{Occ}(k|n,m) = frac{(m)_k cdot S(n,k)}{m^n} quad quad text{for all } k = 1,2,..., min(n,m).$$
(In this expression the values $(m)_k = m (m-1) cdots (m-k+1)$ are the falling factorials and the values $S(n,k)$ are the Stirling numbers of the second kind.) For the coupon collector's problem we are interested in the probability that $K=m$, which is:
$$text{Occ}(m|n,m) = frac{m! cdot S(n,m)}{m^n} cdot mathbb{I}(m leqslant n).$$
For your particular problem the desired probability for the coupon collector's problem is:
$$text{Occ}(6|10,6) = frac{6! cdot S(10,6)}{6^{10}}
= frac{720 cdot 22827}{60466176}
= frac{16435440}{60466176}
= 0.2718121.$$
Confirming this by simulation: We can easily simulate the occupancy number in R
by simulating the underlying allocation problem. Taking $S = 10^6$ simulations gives the following sample proportions for the occupancy number.
#Simulate this problem S times
set.seed(1);
S <- 10^6;
BALLS <- array(ceiling(6*runif(10*S)), dim = c(S, 10));
#Count number of occupied bins
OCC <- rep(0, S);
for (s in 1:S) { OCC[s] <- dim(table(BALLS[s,])) }
#Show sample proportions of outcomes
table(OCC)/S;
OCC
2 3 4 5 6
0.000279 0.018522 0.203018 0.506310 0.271871
We can see that the proportion of cases where $K=6$ closely matches our probability calculation using the classical occupancy distribution.
edited Dec 7 '18 at 4:15
answered Dec 7 '18 at 0:11
BenBen
1,118115
1,118115
add a comment |
add a comment |
$begingroup$
Hint:
There are two approaches to counting the number before dividing by $6^{10}$
The labour-intensive way is by inclusion-exclusion
The quick way is to take a particular known value of Stirling numbers of the second kind, and multiply by a suitable factorial to take account of the colours being distinguishable
$endgroup$
add a comment |
$begingroup$
Hint:
There are two approaches to counting the number before dividing by $6^{10}$
The labour-intensive way is by inclusion-exclusion
The quick way is to take a particular known value of Stirling numbers of the second kind, and multiply by a suitable factorial to take account of the colours being distinguishable
$endgroup$
add a comment |
$begingroup$
Hint:
There are two approaches to counting the number before dividing by $6^{10}$
The labour-intensive way is by inclusion-exclusion
The quick way is to take a particular known value of Stirling numbers of the second kind, and multiply by a suitable factorial to take account of the colours being distinguishable
$endgroup$
Hint:
There are two approaches to counting the number before dividing by $6^{10}$
The labour-intensive way is by inclusion-exclusion
The quick way is to take a particular known value of Stirling numbers of the second kind, and multiply by a suitable factorial to take account of the colours being distinguishable
answered Dec 6 '18 at 22:35
HenryHenry
99.9k480165
99.9k480165
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3028945%2fprobability-of-extracting-k-different-coloured-balls-in-a-sample-of-mk-balls%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
$begingroup$
Well, the first thing to notice is that every possible sequence of colors has the same probability, $6^{-10},$ so the problem is simply to count the sequences that have at least one of each color.
$endgroup$
– saulspatz
Dec 6 '18 at 20:03
$begingroup$
Yes. But that is exactly where I have the problem. I don't know how to find out how many favorable cases are there.
$endgroup$
– Israel Barquín
Dec 6 '18 at 21:35
$begingroup$
There are ten balls. Six of them are of different colors. That leaves only four balls to account for. Try writing down the possibilities.
$endgroup$
– saulspatz
Dec 6 '18 at 22:36