There are 3 red sticks, 4 yellow sticks, and 2 blue sticks in a bag. Sticks are picked one by one. If the stick is red then it goes back in the bag, but if it is not red, then it is kept out of the bag. You stop picking after 3 such picks. Y is the random variables that counts the # yellow sticks - #red sticks. Find the expected value of Y.
@jim_thompson5910
first we need all possible values of Y, then we need the probability of each value. i believe this will take a couple minutes, although there might be a short cut
Isn't the number of yellow sticks just 4 and red sticks 3?
it seems like Y can take on the values \[\{-3,-2,-1,0,1,2\}\]
How did you get those?
Y is the number of yellow sticks selected, minus the number of red sticks selected, out of the total of 3 sticks selected
so for example, if you select no yellow stick and all red sticks, then \(Y=0-3=-3\)
But, in order to get 2 it would be 5-3, but there aren't 5 yellow sticks
now for each of these you need the associated probability and for that you need to figure out exactly what would give you each number to answer your last question, if you select 2 yellow and no red, then \(Y=2-0=2\) or if you select 3 yellow and 1 red then \(Y=3-1=2\)
i interpret the statement "Y is the random variables that counts the # yellow sticks - #red sticks. " to mean out of the three selected
our next job is to figure out each of the associated probabilities. i.e. \(P(Y=-3),P(Y=-2), P(Y=-1)...\)
Alright, so if I picked 3 yellow sticks and 1 red, would that be 4*3*2*2?
lets start at the bottom \(P(Y=-3)\) means all 3 are red that probability is \(\frac{1}{3}\times \frac{1}{3}\times \frac{1}{3}=\frac{1}{27}\)
is that ok?
Yep, that looks right
how about \(PY=-2\) that means either no yellow and two red or one yellow and 3 red
no i don't think so this problem is a real pain because of the different conditions replacement and non replacement lets compute the probability of no yellow and two red.
no yellow and two red would be 1/3 * 1/3 right?
i think no yellow and two red is \[3\times \frac{1}{3}\times \frac{1}{3}\times \frac{2}{9}\]
r r b r b r b r r
I get the (1/3)*(1/3)*(2/9) for blue, but where did the 3 come from?
three ways to get it
That makes sense!
ok i think that is the only way for \(Y=-2\) because we can't have one yellow and 3 red if we only pick 3
now on to \(Y=-1\) and this is going to be a pain i think. 1 yellow 2 red or no yellow 1 red
no yellow one red is \(3\times \frac{2}{9}\times \frac{1}{8}\times \frac{1}{3}\) i think but i could be wrong
b b r b r b r b b
no it is wrong damn
b b r: \(\frac{2}{9}\times \frac{1}{8}\times \frac{3}{7}\)
b r b: \(\frac{2}{9}\times \frac{3}{8}\times \frac{1}{8}\)
this is really a pain ok finally r b b: \(\frac{3}{9}\times \frac{2}{9}\times \frac{1}{8}\)
reason being if you pick a red first you replace it, so there are still 9 sticks in the bag
So, I would add those up to get the probability of Y=-1?
well believe it or not, no, because that was only for two blue and one red you also have to do 1 yellow 2 red then add them i have to run, but i hope it is clear what you have to do btw ignore \(Y=0\) since this has nothing to do with the expected value, as when you multiply by 0 you get 0
I drew out a tree diagram and for 1Y 2R I got: (1/3)*(4/9)*(3/8) ...RYR (1/3)*(1/3)*(4/9) ...RRY (4/9)*(3/8)*(3/8)... YRR So I would multiply and add these right?
RBB=(1/108) BRB=(1/96) BBR=(1/84) RYR=(1/18) RRY=(4/81) YRR=(1/16) Would I just add all these up?
If I just add up the values, then... P(Y=-3)=(1/27) P(Y=-2)=(2/27) P(Y=-1)=(.199) P(Y=0)=0 you said? P(Y=1)=(238/1008) P(Y=2)=(1/7) What would I do now?
assuming those probabiities are correct, and i didn't check them, you multiply and add
\[-3\times P(Y=-3)-2P(Y=-2)-1P(Y=-1)\] \[+P(Y=1)+2P(Y=2)+3P(Y=3)\]
So, I went back to make sure everything was right and for Y=-2 I got (1/3*)(1/3)*(2/9)= RRB (1/3)*(2/9)*(3/8)=RBR (2/9)*(3/8)*(3/8)=BRR But that's not what you got. Could you just check just that part really quickly since I want to make sure I didn't mess everything up
that looks correct
two reds, one blue
Thanks! Also, do you know how to find the density function? I'm not sure what that is
this is a pain this problem but what you wrote looks good
this is exactly what you are doing. you are finding the probability density function for this random variable \(Y\)
I thought I was finding the expected value?
this random variable takes on the values \(\{-3,-2,-1,1,2,3\}\) and finding the probability for each of these values is exactly the probability density function it is not the expected value, but you need this first
the expected value is what you get when you multiply and add
Alright, so {−3,−2,−1,1,2,3} is the density function?
i wrote it a few posts above
no the density function is not the possible values of \(Y\) it is this \(f(x)=P(Y=x)\) it only has 6 elements in the domain of the function
so for example \(f(-2)=P(Y=-2)\) which is what you computed above
So, it is the probabilities of each of the Y=...?
yes
Thank you so much!
\(f(-1)=P(Y=-1)\) etc
yw you still have to multiply and add right?
Wait, is it the probability of Y * the number? Like -1*P(Y=-1) or 3*P(Y=3)?
\[-3\times P(Y=-3)-2\times P(Y=-2)-P(Y=-1)+P(Y=1)+2P(y=2)+3P(y=3)\]
multiply and add over all possible values of \(Y\)
do you have these probabilities?
Yep, I finished the problem awhile ago. I just needed to know what the density function is for a different problem.
discrete or continuous?
It just find the density function. I'm a bit confused though. You said it was just P(Y=..), but then you posted ...*P(Y=...). Is the density function the probabilities of Y * the number in from like -1*P(Y=-1) or 3*P(Y=3)?
*says *front
ok it is the expected value that you multiply and add
So, the density function is just the table of Y=... without multiplying Y=... by the number in front, right?
not the density function. but if you rewrite \(P(Y=x)\) as \(f(x)\) then the expected value is \[\sum_{x}xf(x)\]
Thank you!
yes, the density function is the the values \(f(x)=P(Y=x)\) just the values the expected value is what you get when you multiply and add yw
Join our real-time social learning platform and learn together with your friends!