Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a problem with the subject of "Expected Probability" (I don't really know what is the right name for it).

This is an example of a question: (I am not looking for the specific answer, just for the idea)

What is the probability to withdraw 2 white balls (without returning) from a bucket, that contain X white balls and 120-X black balls. when X is a random variable.

from what I understand, I should represent the probability as function of X and then to get the expected value of it.

        P(two white)     →    X(X-1)/(120∙199)   →   E(X(X-1)/(120∙199))

is this correct? what am I really doing here? maybe you can forward me to a relevant place that I can read about this subject ?


share|cite|improve this question
up vote 0 down vote accepted

You wrote:

        P(two white)     →    X(X-1)/(120∙199)   →   E(X(X-1)/(120∙199))

It seems hard to talk students out of using arrows in this way. I don't know where they learn to do that.

One could write $$ \Pr(\text{two white}\mid X) = \frac{X(X-1)}{120\cdot199}, $$ i.e. the conditional probability of getting two white balls given the value of the random variable $X$ is $X(X-1)/(200\cdot199)$. Then we'd have $$ \Pr(\text{two white}) = \mathbb E(\Pr(\text{two white}\mid X)) = \mathbb E\left(\frac{X(X-1)}{120\cdot199}\right). $$

That last quantity depends on the probability distribution of the random variable $X$.

share|cite|improve this answer
It's perfectly legitimate in some contexts to use an arrow, as in $A\to B$, to mean "if $A$ then $B$", and it's also legitimate to write things like $\left(\dfrac{n+1}{n}\right)^n\to e$ as $n\to\infty$. But if an arrow is intended merely to direct the reader's eyes to the next step, it's almost always better to rely on either well chosen words or correctly used mathematical notation. – Michael Hardy Jun 18 '13 at 17:24

For any fixed value of $X$, the probability you seek is $$ \frac{\binom{X}{2}}{\binom{120}{2}} = \frac{X (X-1)}{120 \cdot 199} $$ as you write.

However now that $X$ is a random variable, it has some distribution. It is clear that $X$ is an integer in $[0,120]$, let's say that $\mathbb{P}[X=k] = p_k$ for $k \in [0,120]$. In case $k=0,k=1$ it's not possible to draw two white balls... Then,

$$ \mathbb{P}[\text{draw 2 white balls}] = \sum_{k=2}^{120} p_k \frac{k (k-1)}{120 \cdot 199} = \frac{1}{199 \cdot 120} \sum_{k=2}^{120} p_k k (k-1), $$ which depends on the distribution of $X$.

EDIT Further simplification is possible.

Note that $\mathbb{E}[X^n] = \sum_{k=0}^{120}k^n p_k$. Then,

$$ \begin{split} \mathbb{P}[\text{draw 2 white balls}] &= \frac{1}{199 \cdot 120} \sum_{k=2}^{120} p_k k (k-1) \\ &= \frac{1}{199 \cdot 120} \left( \sum_{k=0}^{120} p_k k (k-1) - p_0 \cdot 0 \cdot (-1) - p_1 \cdot 1 \cdot 0 \right) \\ &= \frac{1}{199 \cdot 120} \sum_{k=0}^{120} p_k k (k-1) \\ &= \frac{1}{199 \cdot 120} \left( \sum_{k=0}^{120} k^2 p_k - \sum_{k=0}^{120} k p_k \right) \\ &= \frac{\mathbb{E}[X^2] - \mathbb{E}[X]}{199 \cdot 120} \end{split} $$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.