0

Suppose that $n$ balls are randomly thrown into $N$ bins. We can compute the expected number of bins that contain at least one ball as $E(X) = N(1 - (1 - 1/N)^n)$.

Now, suppose that instead we are asked for the expected number $E(Y)$ of bins that contain more than one ball. Can we recover this from $n$ and $E(X)$? My intuition is suggesting that this ought to be $E(Y) = n - E(X)$, but I'm not sure one way or the other.

My intuition is coming from the pigeon hole principle, I think. If $E(X)$ bins are occupied, and there are $n$ balls, then $n - E(X)$ balls are in a bin with at least one more ball in it. Granted, that doesn't tell me how the $n - E(X)$ balls are distributed in the bins.

I am trying to compute the expected number of bins with exactly one ball directly. Let $N_i$ be the number of balls in the $i$th bin, and let $Z_i = 1$ if $N_i = 1$, and $Z_i = 0$ otherwise.

Each $N_i$ is binomial with parameters $n$ and $p = 1/N$. Then $E(Z_i) = P(Z_i = 1) = P(N_i = 1) = \frac{n}{N} \left(\frac{N-1}{N}\right)^{n-1}$. So $E(Z) = n\left(\frac{N-1}{N}\right)^{n-1}$.

MJD
  • 65,394
  • 39
  • 298
  • 580
nomen
  • 2,707

1 Answers1

3

The expected number of bins with at least one ball is

$$ E(\geq 1) = N(1-(1-1/N)^n) $$

and the expected number with precisely one ball is (from the binomial distribution)

$$ E(1)=N(1-1/N)^{n-1} $$

so

$$ E(>1)=E(\geq 1)-E(1) = N(1-(1-1/N)^{n-1}(2-1/N)) $$

which doesn't seem to equal $n-E(\geq 1)$.

lemon
  • 3,548
  • Thanks, I didn't notice the '1' case is binomial. – nomen Jul 26 '14 at 23:48
  • 1
    Your expression goes to $- N$ as $N \rightarrow \infty$, while surely it should go to zero? – Rudyard Feb 03 '19 at 09:28
  • @Rudyard That's not how limits work. There is an N factor outside. You cannot just plug the limit in the later term and ignore the outer $N$. – AspiringMat Jul 29 '21 at 22:15
  • Shouldn't E(1) be n * (1 - 1/N)^(n-1)? This is because the binomial term in the PMF gives n while the N from summing over the bins is cancelled out. – PythonNut Feb 14 '23 at 00:34