# Taking a ball from an urn after passing a randomly chosen ball from another urm

An urn contains four blue balls and three white balls. A second urn contains five blue and four white balls. Pass up a ball from the first to the second urn and then extracted a ball second urn.

I already know how likely it is that the selected ball is white. Real question

If the result is blue ball, what is the probability that the first removed resulted white ball?

I know that the probability of being white in the second one is $\frac {31}{70}$.

The probability of being blue is $\frac {39}{70}$ because it is $1-\frac {31}{70}=\frac {39}{70}$. If the first is white the probability is $\frac 37$. So If the result is blue ball, the probability that the first removed resulted white ball is $\frac {39}{70}\cdot \frac 37$?

Use Bayes' theorem:

• $A$... the event "the first removed ball was white"
• $B$... the event "the result is a blue ball"

all you need is the equation:

$$P(A|B) = \frac{P(A)}{P(B)}P(B|A)$$

You already know $P(B)$ (you already calculated it). $P(A)$ is simple. $P(B|A)$ is also not hard, it is

The probability that a blue ball was selected from the second urn after a white ball was placed from the first to the second urn

This is a classical problem where the total probability formula should be used. You know that a blue ball was drawn. The total probability formula tells us that the probability for drawing a blue ball is $P(B)=P(B)\cdot P(B|B) + P(W)\cdot P(B|W)$. Where $P(B)=\frac{4}{7}$ is the probability to draw a blue ball, form the first urn and put it in the second urn. $P(B|B) = \frac{6}{10}$ is the probability to draw blue ball from the second urn if you have passed a blue ball form the first urn (Blue balls become 6 in the second urn for a total of 10 balls).

Ditto for $P(W)=\frac{3}{7}$ and $P(B|W)=\frac{5}{10}$. Here the white balls in the second urn increase by one.

You are interested in the probability to have drawn a white ball from the first urn if you got a blue ball from the second urn i.e. $P(W|B)$. Here we know $P(B)$ and hence use the formula

$P(W)\cdot P(B|W) = P(B) \cdot P(W|B)$

$P(W|B)=\frac{P(W)\cdot P(B|W)}{P(B)}$

You can insert the numbers and check the result.