0
$\begingroup$

In the basket lies m   black balls and n   reds. Vasya takes out a random ball from the basket and, if it is black, then replaces it with red, and if it is red, then puts it back. Find the mathematical expectation and variance of the number of red balls in the basket after k   iterations of this procedure. Both answers must be compact expressions (i.e. do not contain summation signs, ellipses, etc.).

I tried to solve this problem in this way. Let X - number of red balls after k iterations. Easy to see that n <= X <= n + m

We should find

$\sum_{i=n}^{n+m} P(X=i) * i$

$P(X = i) = (\frac{n}{n+m}) ^ {i}$ But couldn't find other probabilities. Because the probability of taking black/red ball changes after we take a black ball. How I can solve this ?

$\endgroup$
3
  • 1
    $\begingroup$ Welcome to MSE. Your question is phrased as an isolated problem, without any further information or context. This does not match many users' quality standards, so it may attract downvotes, or closed. To prevent that, please edit the question. This will help you recognise and resolve the issues. Concretely: please provide context, and include your work and thoughts on the problem. These changes can help in formulating more appropriate answers. $\endgroup$ Commented Feb 22, 2020 at 10:06
  • $\begingroup$ I think you meant to write $P(X = k) = (\frac{n}{n+m}) ^ {k}$ $\endgroup$ Commented Feb 22, 2020 at 11:55
  • $\begingroup$ edited. yes, thank you very much $\endgroup$ Commented Feb 22, 2020 at 13:33

1 Answer 1

1
$\begingroup$

I feel sure this question has been asked and answered on this site before, but I can't find it. Anyway, this is one of those problems that's easy enough once you find the right way of looking at it. Suppose that instead of changing the colors of the balls, we just choose with replacement $k$ times, and keep track of which balls have been chosen. Then the number we seek is the number of red balls, plus the number of black balls that have been chosen at least once.

If we let $X_i$, be a random variable which is $0$ if black ball number $i$ has not been chosen, and $1$ if it has been chosen, where $i=1,2,\dots,m$ then $E(X)=n+\sum_{i=1}^mE(X_i)$ by linearity.

Can you take it from here?

EDIT

Here's some more description of the new model. Imagine that the black balls are numbered $1$ to $m$. Instead of changing the colors of the balls, we keep track of which black balls have been chosen. After $k$ iterations we find that black ball $1$ has been chosen once, black ball $3$ has bene chosen once, and black ball $4$ has been chosen $3$ times. No other balls have been chosen.

If we were changing the colors of the balls, black balls $1,3$, and $4$ would have been replaced by red balls, or colored red. But black ball $4$ would only have been replaced by a red ball the first time it was chosen. After that, it would have been colored red, and nothing would have changed when it was picked. So the number of red balls in this scenario would be $n+3$.

In general, we just need to count how many of the black balls have been chosen at least once.

$\endgroup$
4
  • $\begingroup$ No, I couldn't get your idea. Can you describe it in more details $\endgroup$ Commented Feb 22, 2020 at 13:37
  • $\begingroup$ @Maruf What part do you not understand? Do you see that the new model is the old problem in disguise? I'm not sure if you don't grasp the idea or if you just have trouble with the ensuing calculations. $\endgroup$ Commented Feb 22, 2020 at 14:31
  • $\begingroup$ @MarufKaraev I added an example. See if that helps. $\endgroup$ Commented Feb 22, 2020 at 15:11
  • $\begingroup$ thank you, I get your idea. I'll try to apply it $\endgroup$ Commented Feb 22, 2020 at 16:44

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.