
Advanced Statistics Advanced Probability and Statistics Math Forum 
 LinkBack  Thread Tools  Display Modes 
April 2nd, 2018, 06:58 PM  #1 
Member Joined: Feb 2018 From: Canada Posts: 34 Thanks: 2  Expected value
I had this question today in my midterm but I was not able to figure it out during the test. Can someone help me out? There are n boxes numbered 1 to n and n balls numbered 1 to n. The balls are to be randomly placed in a box (not necessarily different boxes). What is the expected number of empty boxes? Thank you. 
April 2nd, 2018, 10:25 PM  #2 
Senior Member Joined: Sep 2015 From: USA Posts: 2,123 Thanks: 1102 
through listing the possible assignments and grinding out expectations I'm seeing the answer is $E[\text{# empty boxes}] = \dfrac{(n1)^n}{n^{n1}}$ This is in very good agreement with sims for various $n$. The assignments of boxes are uniform, each assignment having $p=\left(\dfrac 1 n\right)^n$ The key is to transform the list of assignments into a count of empty boxes. I don't yet recognize a simple formula that fits the data I generate for the individual probabilities of empty box counts. Nevertheless using those to compute the expected value for various $n$ reveals the formula noted above. I'm clearly missing something or this is just an impossible test question. I'm sure the Peanut gallery will chime in. 
April 3rd, 2018, 09:43 PM  #3  
Member Joined: Feb 2018 From: Canada Posts: 34 Thanks: 2  Quote:
I think the $p=\left(\dfrac 1 n\right)^n$ is the probability a box is not empty after all balls are thrown. This is how I try to do, let me know if I have done it wrong. Here, for each $i=1,2,\cdots,n$ define the random variable \[ X_i=\begin{cases} 1 &\text{if the $i^{\rm th}$ box is empty} \\ 0 &\text{otherwise} \\ \end{cases} \] Now let $X$ be the total number of empty boxes. Then the number of empty boxes is $X=\sum\limits_{i=1}^n X_i=X_1+X_2+\cdots+X_n$ and the expected number is $E(X)=\sum\limits_{i=1}^{n}E(X_i)=E(X_1) + E(X_2) + \cdots + E(X_n)$ (Using the linearity of expectation). Each time a ball is thrown, the probability a ball lands in that one box is $\dfrac{1}{n}$ so there is a $\dfrac{n1}{n}$ chance that it will not land in that box. So the probability that particular box remains empty after all the balls are thrown is $\left(\dfrac{n1}{n}\right)^n$, since this event must occur n times as we have n balls. Hence, $E(X_i)=P(X_i=1)=\left(\dfrac{n1}{n}\right)^n$. \[ E[\text{number of empty boxes}]=\sum\limits_{i=1}^{n} E(X_i)=n\cdot E(X_i)=n\cdot \left(\dfrac{n1}{n}\right)^n = \dfrac{(n1)^n}{n^{n1}} \]  
April 3rd, 2018, 10:58 PM  #4  
Senior Member Joined: Sep 2015 From: USA Posts: 2,123 Thanks: 1102  Quote:
 
April 8th, 2018, 03:31 PM  #5 
Member Joined: Feb 2018 From: Canada Posts: 34 Thanks: 2  

Tags 
expected, expected value 
Thread Tools  
Display Modes  

Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Expected Value  jbergin  Probability and Statistics  1  January 2nd, 2015 08:56 AM 
Expected Value  jbergin  Advanced Statistics  3  December 27th, 2014 07:03 PM 
Expected Value  jbergin  Probability and Statistics  1  December 23rd, 2014 08:14 AM 
Expected Value  asd  Advanced Statistics  5  March 19th, 2012 02:29 PM 
Expected value  kahalla  Advanced Statistics  0  March 9th, 2010 12:53 AM 