# calculating expected value

• September 30th 2010, 06:41 AM
sta1987
calculating expected value
Hi again, back with another question! Here goes:

148 students ride in 4 buses, which transport 25, 33, 40 and 50 students respectively. A student is chosen at random. Let X be the number of student on the bus she's riding. Also, one of the 4 busdrivers are chosen at random. Let Y be the number of students on his bus.

Calculate expected values E[X] and E[Y].

(I've calculated expected value before but this question seems different and I'm really at a loss as to where to start.) Would really love some help with this!
• September 30th 2010, 11:05 AM
coatesdr
Remember: $E(X)=\sum\limits_{all x}xf(x)$, where f(x) is the probability function.

Now, here your X takes on the values 25, 33, 40, and 50, with probabilities 25/148, &c.

Your Y takes on the same values, with probabilities all being 1/4.

After that it should be a straightforward calculation.
• September 30th 2010, 11:29 AM
sta1987
Hi, thanks a million for helping me!

Yes, been working some more on this with a friend and we decided E(X)= (40^2)/148 + (33^2)/148 + (25^2) + (50^2)/148 = 39,28

The number seems reasonable. However, I personally don't understand why we square the numbers, could you explain this for me? (Is it even correct to do so?)

For the busdriver we simply calculated E(Y)= 40/4 + 33/4 + 25/4 + 50/4 = 37
• September 30th 2010, 12:02 PM
coatesdr
Well, the fact that you square the numbers is coincidental, it's just because of the way the question is set up. There's no special significance to it. Try working through it one step at a time:

$E(X)=\sum\limits_{all x}xf_X(x)=\sum\limits_{x \epsilon \{25,33,40,50\}}xf_X(x)$

$=25*f_X(25)+33*f_X(33)+40*f_X(40)+50*f_X(50)$

Now, $f_X(25)=P(X=25)$ is the probability that a randomly chosen student is on the bus with 25 passengers, which is clearly $\frac{25}{148}$, and so on. Thus

$=25*\frac{25}{148}+33*\frac{33}{148}+40*\frac{40}{ 148}+50*\frac{50}{148}$

$=\frac{25^2+33^2+40^2+50^2}{148}=\frac{5814}{148}= 39.28...$
• September 30th 2010, 12:15 PM
coatesdr
Just for comparison, it's exactly the same process for finding E(Y):

$E(Y)=\sum\limits_{all y}yf_Y(y)=\sum\limits_{y\epsilon\{25,33,40,50\}}yf _Y(y)$

$=25*f_Y(25)+33*f_Y(33)+40*f_Y(40)+50*f_Y(50)$

But here, $f_Y(25)=P(Y=25)$ is the probability that a randomly chosen bus driver is on the bus with 25 passengers, which is $\frac{1}{4}$, and is the same for all the buses. Thus

$=25*\frac{1}{4}+33*\frac{1}{4}+40*\frac{1}{4}+50*\ frac{1}{4}=37$
• September 30th 2010, 12:58 PM
sta1987
coatsder, thank you so much for this!! Finally I understand what it is I am doing :) Will try to find some similar problems to work on now so as to really "hammer it into my head" :)

Again, you've been a great help! TY!