WEBVTT mathematics/probability/murray
00:00:00.000 --> 00:00:04.200
Hi and welcome back to the probability lectures here on www.educator.com.
00:00:04.200 --> 00:00:08.500
My name is Will Murray, and today, we are going to talk about random variables.
00:00:08.500 --> 00:00:12.600
The idea that goes along with that is the probability distribution.
00:00:12.600 --> 00:00:17.300
We are going to learn what those terms mean, let us jump right into it.
00:00:17.300 --> 00:00:20.900
I'm going to start with the intuition for random variable
00:00:20.900 --> 00:00:26.300
because a formal definition of random variable is not really that illuminating.
00:00:26.300 --> 00:00:29.900
We will start out with the intuition, try to give you an idea of roughly what they mean,
00:00:29.900 --> 00:00:32.300
then I will give you the formal definition.
00:00:32.300 --> 00:00:39.800
The intuition for a random variable is it is a quantity you keep track of during an experiment.
00:00:39.800 --> 00:00:44.900
We are going to use Y for random variable.
00:00:44.900 --> 00:00:48.300
I want to start out with an example right away.
00:00:48.300 --> 00:00:53.700
Let us say we are going to play the World Series and the Yankees are going to play the Giants for 7 games.
00:00:53.700 --> 00:00:56.600
That is not quite how the actual world series run.
00:00:56.600 --> 00:00:59.800
Before I get a bunch of angry comments from a bunch of sports fans,
00:00:59.800 --> 00:01:07.700
I know that some× in the World Series, one team wins all four games right away.
00:01:07.700 --> 00:01:09.900
It does not actually run for 7 games.
00:01:09.900 --> 00:01:11.700
We are not playing under those rules.
00:01:11.700 --> 00:01:18.300
We are going to play 7 games, all 7 games no matter what, no matter who wins the first 2 games.
00:01:18.300 --> 00:01:21.900
What can happen there is, there are7 different games,
00:01:21.900 --> 00:01:26.100
each one can have 2 possible outcomes because the Yankees can win and the Giants can win.
00:01:26.100 --> 00:01:29.000
There are really 2⁷ possible outcomes.
00:01:29.000 --> 00:01:34.700
There are 128 possible sequences of events in the World Series.
00:01:34.700 --> 00:01:41.400
Honestly, what we have been really only care about is the number of games that one team wins vs.
00:01:41.400 --> 00:01:43.900
the number of games that the other team wins.
00:01:43.900 --> 00:01:50.900
We could say, for example, that Y is going to be the number of games that the Yankees win.
00:01:50.900 --> 00:01:54.500
What we are really care about is whether Y is more or less than 4
00:01:54.500 --> 00:01:58.100
because whichever team wins 4 more games wins the world series.
00:01:58.100 --> 00:02:03.300
We certainly do not really care who wins the first game vs. the second game,
00:02:03.300 --> 00:02:08.400
what we care about is the total number of games that each team wins.
00:02:08.400 --> 00:02:13.600
For example, one possible way the World Series can go would be,
00:02:13.600 --> 00:02:23.100
if you are keeping track of the Yankees, you can have win-win, lose-lose, win-lose-win.
00:02:23.100 --> 00:02:26.200
That is the possible outcome of the World Series.
00:02:26.200 --> 00:02:32.500
What we would keep track of their though is that there are 4 wins.
00:02:32.500 --> 00:02:35.200
We would say Y of that outcome would be 4.
00:02:35.200 --> 00:02:40.200
That is really all that matters, it does not matter the order in which the wins occur.
00:02:40.200 --> 00:02:47.600
That is the intuition for random variable is you are keeping track of a certain number during an experiment.
00:02:47.600 --> 00:02:51.400
At the end, your outcome gives you a certain value.
00:02:51.400 --> 00:02:59.600
Let us do another example to try to understand that intuition a little more before I give you the formal definition.
00:02:59.600 --> 00:03:05.600
Another way to think about random variables is to think about a payoff on an experiment.
00:03:05.600 --> 00:03:10.100
Meaning depending on what happens, you get paid a certain amount of money.
00:03:10.100 --> 00:03:14.200
This is often useful if you are thinking about gambling games in a casino.
00:03:14.200 --> 00:03:19.600
Depending on how the cards come out, the dice come out, whatever, you get paid a certain amount.
00:03:19.600 --> 00:03:22.800
For example, here is a very simple gambling game.
00:03:22.800 --> 00:03:28.800
You are going to draw a card from a 52 card deck, if you drawn an ace then I will pay you $1.00.
00:03:28.800 --> 00:03:37.200
If you draw a 2 then I will pay you $2.00, all the way up to I you draw a 9 then I will pay you $9.00.
00:03:37.200 --> 00:03:41.400
If it is a 10, you have to pay me $10.00.
00:03:41.400 --> 00:03:51.800
If it is a jack, queen, king, those are called face cards then you have to pay me $10.00 for any of those cards as well.
00:03:51.800 --> 00:03:58.300
The quantity we can keep track of here is the amount of money that you stand to make on this experiment.
00:03:58.300 --> 00:04:02.600
Notice here that this Y could be positive or negative.
00:04:02.600 --> 00:04:12.000
For example, Y if you draw an ace then you stand to make a $1.00 off this experiment, that is a positive outcome for you.
00:04:12.000 --> 00:04:23.700
Y if you draw a 2, would be $2.00, all the way up to Y of 9, if you draw a 9, you get $9.00.
00:04:23.700 --> 00:04:29.600
But if you draw 10 then you have to pay me $10.00.
00:04:29.600 --> 00:04:32.800
From your perspective, that is -$10.00 for you.
00:04:32.800 --> 00:04:42.200
Y of 10 would be -10 and Y of a jack would be -10, and so on.
00:04:42.200 --> 00:04:44.900
Any face card, you have to pay me $10.00.
00:04:44.900 --> 00:04:51.400
We think of the payoff and from your perspective that is a negative payoff for you.
00:04:51.400 --> 00:04:59.100
The way you want to think about this random variable is it is the amount of money that you make from this experiment
00:04:59.100 --> 00:05:06.100
which could be positive or negative, depending on whether you go away richer or whether you have to pay me and you walk away poor.
00:05:06.100 --> 00:05:14.200
Those are some rough, intuitive ideas to keep in mind as we get to the formal definition of random variable,
00:05:14.200 --> 00:05:19.600
which is that it is a function from the sample space to R.
00:05:19.600 --> 00:05:22.100
R is the set of real numbers here.
00:05:22.100 --> 00:05:40.100
Remember, the sample space is the set of outcomes for an experiment.
00:05:40.100 --> 00:05:46.300
The random variable number, if you want to think about it as a payoff then for each outcome there is some kind of payoff.
00:05:46.300 --> 00:05:48.800
There is a real numbers worth a payoff.
00:05:48.800 --> 00:05:58.900
It is a function that takes in an outcome and it gives you back a number which you can think of is the amount you get paid.
00:05:58.900 --> 00:06:04.200
Or it is the quantity that you are keeping track of during the experiment.
00:06:04.200 --> 00:06:10.000
To return to our first example there which was the World Series, how many games do the Yankees win?
00:06:10.000 --> 00:06:13.900
I have listed some different possible outcomes of the World Series.
00:06:13.900 --> 00:06:18.400
We are assuming that we are going to play all 7 games in the World Series,
00:06:18.400 --> 00:06:23.600
even if somebody has already wrapped up the best of 7 early.
00:06:23.600 --> 00:06:25.600
We are going to play all 7 games, no matter what.
00:06:25.600 --> 00:06:35.700
If we are kind of looking at it from the perspective of the Yankees, if it is win-win-win, lose-lose-win-lose, there are 4 wins there.
00:06:35.700 --> 00:06:39.600
The Y of that outcome is 4.
00:06:39.600 --> 00:06:45.900
If we lose the first 6 games and we win the last game, the Y of that outcome is 1.
00:06:45.900 --> 00:06:52.200
If we alternate winning and losing, win-lose, win-lose, win-lose-win, that is also 4.
00:06:52.200 --> 00:06:59.200
In the sense of comparing that to the first outcome there, they are the same as far as Y is concerned
00:06:59.200 --> 00:07:03.000
because the Y is going to be the same number either way.
00:07:03.000 --> 00:07:07.300
Remember, there is 2⁷ possible ways that the World Series could go.
00:07:07.300 --> 00:07:09.100
I’m not going to write them all down.
00:07:09.100 --> 00:07:19.000
Each one of them has a number associated to it, from 0 to 7 depending on how many games the Yankees win there.
00:07:19.000 --> 00:07:23.200
I want to move on to my next definition which is the probability distribution.
00:07:23.200 --> 00:07:29.500
The notation gets a little confusing here because there is a lowercase letters and capital letters.
00:07:29.500 --> 00:07:38.100
Here you want to think of y here as a number, that is a possible value of the random variable.
00:07:38.100 --> 00:07:48.200
The Y here is the actual random variable.
00:07:48.200 --> 00:07:52.500
This is what gets a little confusing because we will say Y=y.
00:07:52.500 --> 00:08:02.600
What we are really asking there is when is the random variable going to take on that particular number or that particular value?
00:08:02.600 --> 00:08:08.200
You think of the y as being the value and Y is the actual variable.
00:08:08.200 --> 00:08:14.300
What is the probability that the random variable has a particular value?
00:08:14.300 --> 00:08:24.900
This P is the probability that the random variable takes on a particular number or takes on a particular value.
00:08:24.900 --> 00:08:32.800
We try to find that probability and we add up all those probabilities over all the outcomes that lead to that value.
00:08:32.800 --> 00:08:36.400
We say that that is the probability of that value.
00:08:36.400 --> 00:08:39.300
This problem will make more sense after we do some examples.
00:08:39.300 --> 00:08:42.700
Stick around for examples, if it is a little confusing to you right now.
00:08:42.700 --> 00:08:50.800
What we are doing here, what this notation means is now the sample space is the set of all the outcomes.
00:08:50.800 --> 00:08:58.400
We look at all the outcomes in the sample space for which the random variable has that particular value
00:08:58.400 --> 00:09:01.800
and then we add up the probabilities of all those outcomes.
00:09:01.800 --> 00:09:03.600
That is what this formula means.
00:09:03.600 --> 00:09:08.100
It will make more sense after we do some examples.
00:09:08.100 --> 00:09:12.200
This function, we think of this as being a function P of y.
00:09:12.200 --> 00:09:16.400
It is the probability distribution of the random variable Y.
00:09:16.400 --> 00:09:20.500
We will talk about calculating P of different numbers.
00:09:20.500 --> 00:09:25.700
I think that will make some sense after you see some of these examples.
00:09:25.700 --> 00:09:31.100
Let us jump in and do some examples in all of these notations to make a little more sense.
00:09:31.100 --> 00:09:36.000
In our first example, we are going back to the one that I mentioned earlier in the lecture
00:09:36.000 --> 00:09:40.100
where you draw a card from a standard 52 card deck.
00:09:40.100 --> 00:09:43.000
If it is an ace -9, I will pay you that amount.
00:09:43.000 --> 00:09:45.200
If you draw an ace, I’m going to pay you $1.00.
00:09:45.200 --> 00:09:47.400
If you draw a 2, I will pay $2.00.
00:09:47.400 --> 00:09:51.000
All the way up to, if you draw a 9 I will pay $9.00.
00:09:51.000 --> 00:09:56.700
If it is a 10 then all of a sudden the tables are turned and you have to pay me $10.00.
00:09:56.700 --> 00:09:59.400
From your perspective, that is -$10.00.
00:09:59.400 --> 00:10:05.000
If it is a jack, queen, king, those are called face cards, then you still have to pay me $10.00.
00:10:05.000 --> 00:10:12.000
The question here is what is the probability distribution for this random variable?
00:10:12.000 --> 00:10:16.500
What I'm really asking here, what this kind of question is asking is
00:10:16.500 --> 00:10:23.800
what is the probability of getting different possible values for the random variable?
00:10:23.800 --> 00:10:31.000
What is the probability that you will collect exactly $0.00 from this experiment?
00:10:31.000 --> 00:10:34.600
The probability that this random variable will take the value 0.
00:10:34.600 --> 00:10:41.400
In this case, there is no way that it is going to be exactly 0 because if you get a certain set of cards,
00:10:41.400 --> 00:10:43.200
you are going to have to pay me.
00:10:43.200 --> 00:10:47.000
If we get a different set of cards, I'm going to have to pay you.
00:10:47.000 --> 00:10:52.000
There is no way that this experiment can wind up being worth $0.00 from you.
00:10:52.000 --> 00:10:56.900
You are going to win something, you are going to lose something, you are not going to break even on this experiment.
00:10:56.900 --> 00:11:01.000
Let us look at the probability of 1.
00:11:01.000 --> 00:11:09.500
P of 1 is the probability that our random variable takes the value 1.
00:11:09.500 --> 00:11:16.100
Let us think about all the ways that you can make exactly $1.00 on this, that means you have to draw an ace.
00:11:16.100 --> 00:11:28.900
There are 4 aces in a 52 card deck and the probability that you are going to make exactly $1.00 on this is exactly 1/13.
00:11:28.900 --> 00:11:37.700
The probability that you make $2.00, that is the probability that the random variable takes the value 2.
00:11:37.700 --> 00:11:48.000
There are four 2s in the deck, you have a 4/52 chance which simplifies again down to 1/13.
00:11:48.000 --> 00:12:00.400
It is similar to that all the way up through 3, 4, 5, 6, up to 9, the probability of 9, again it is the probability that Y is equal to 9.
00:12:00.400 --> 00:12:10.100
There are four 9 in a 52 cards and that is 1/13.
00:12:10.100 --> 00:12:19.300
It suddenly changes, there is no way you can get 10 because if you draw a 10 from the deck then you have to pay me.
00:12:19.300 --> 00:12:22.700
That does not count as getting $10.00 for you.
00:12:22.700 --> 00:12:32.100
That would be the probability that Y is equal to 10 and there is no way that you can get $10.00 out of this game, that is 0.
00:12:32.100 --> 00:12:39.600
The probability, there is one more possible value that this game can take for you know which is -10.
00:12:39.600 --> 00:12:53.500
That happens when you draw a 10 or you draw a face card, any of those, the result in you having to pay me $10.00.
00:12:53.500 --> 00:12:54.800
How many different cards are there?
00:12:54.800 --> 00:13:07.900
There are four 10, jacks, queens, kings, there are 16 cards here that will give you a net loss of $10.00
00:13:07.900 --> 00:13:12.800
That simplifies down to 4/13.
00:13:12.800 --> 00:13:21.400
That is your probability of getting -$10.00 out of this game, if you are losing $10.00 as you play this game.
00:13:21.400 --> 00:13:31.500
That is our full probability distribution, I will put a box around the whole thing here because really that whole thing is our answer.
00:13:31.500 --> 00:13:37.800
The probability distribution means you are thinking of all the different possible values of y and
00:13:37.800 --> 00:13:41.900
you are calculating the probability of Y, of each one of those values.
00:13:41.900 --> 00:13:44.100
And that is what we did here.
00:13:44.100 --> 00:13:48.200
To recap that, the possible values of y, I threw in 0.
00:13:48.200 --> 00:13:53.100
It turned out that there is no way that you can make exactly $0.00 out of this game.
00:13:53.100 --> 00:13:57.400
The probability of getting 0 is 0.
00:13:57.400 --> 00:14:00.600
Then, I calculated the probability of 1 through 9.
00:14:00.600 --> 00:14:07.600
For each one of those, there were 4 cards that can give you that particular payoff and
00:14:07.600 --> 00:14:15.200
that is 4/52 giving us 1/13 for each one of those.
00:14:15.200 --> 00:14:17.900
There are really 9 different possibilities there.
00:14:17.900 --> 00:14:20.600
They all have probability 1/13.
00:14:20.600 --> 00:14:28.300
And then, I went ahead and included the probability of 10 although there is no way that you can get $10.00 out of this game.
00:14:28.300 --> 00:14:30.300
That is why we got 0 there.
00:14:30.300 --> 00:14:37.300
I also had to include -10 because there is a possibility that you might lose $10.00 off this game.
00:14:37.300 --> 00:14:41.100
There are 16 cards in the deck that will give you a loss of $10.00.
00:14:41.100 --> 00:14:46.100
When I simplify 16/52, I get 4 out of 13.
00:14:46.100 --> 00:14:53.700
That is the probability distribution for that random variable on that experiment.
00:14:53.700 --> 00:14:57.500
In our second example here, we are going to flip a fair coin 10 ×.
00:14:57.500 --> 00:15:05.900
Y is going to be the number of heads and I want to find the probability distribution for this random variable.
00:15:05.900 --> 00:15:15.300
We are going to calculate P of y, where y is all the possible values that Y could be.
00:15:15.300 --> 00:15:22.800
It is the probability that Y could be equal to that particular value y.
00:15:22.800 --> 00:15:31.100
Let me note before we start, the possible values that y could be, that is the number of heads that we can see here.
00:15:31.100 --> 00:15:33.800
And the fewest heads, we could possibly get be 0.
00:15:33.800 --> 00:15:39.600
The most heads we can possibly get would be 10, if all 10 flips come out to be heads.
00:15:39.600 --> 00:15:48.200
Let us think of on the probability of any particular value.
00:15:48.200 --> 00:15:58.800
Let me think about that, to get exactly y heads we must,
00:15:58.800 --> 00:16:24.000
Here is how you can think about that, we must fill in 10 blanks 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 with tails and heads.
00:16:24.000 --> 00:16:33.000
We know how many of the each because we would have to fill in y heads, yh.
00:16:33.000 --> 00:16:41.800
That would mean that the remaining 10 - y blanks, 10 – yt would all have to be tails.
00:16:41.800 --> 00:16:51.700
Let us think about that, we are choosing y of those 10 blanks to be heads.
00:16:51.700 --> 00:17:01.800
We must choose y blanks to be heads.
00:17:01.800 --> 00:17:13.500
Once we made that choice, there is nothing more to decide because automatically then, all the remaining blanks would have to be tails.
00:17:13.500 --> 00:17:19.100
Let us think about how many ways there are to do that.
00:17:19.100 --> 00:17:29.900
There are 10 choose y ways to do that.
00:17:29.900 --> 00:17:35.800
This is something we learn earlier on in the probability lecture series here on www.educator.com.
00:17:35.800 --> 00:17:39.300
We had a chapter on making choices.
00:17:39.300 --> 00:17:45.900
Probably, that chapter was on ordered vs. unordered, with replacement vs. without replacement.
00:17:45.900 --> 00:17:54.900
This is really an unordered, without replacement selection.
00:17:54.900 --> 00:18:01.200
The formula that you use for that kind of choice is 10 choose y.
00:18:01.200 --> 00:18:06.100
You can look that up on the earlier lectures, if you do not remember how to do that.
00:18:06.100 --> 00:18:09.500
But there is 10 choose y ways to do that.
00:18:09.500 --> 00:18:22.300
Suppose you have a particular way of doing that, each particular way of filling in the blanks,
00:18:22.300 --> 00:18:28.200
let us say for example 1, 2, 3, 4, 5, 6, 7, 8, 9, 10.
00:18:28.200 --> 00:18:30.700
Let us say, for example y =3.
00:18:30.700 --> 00:18:35.600
You choose 3 places, head-head and head.
00:18:35.600 --> 00:18:39.000
You choose 3 places that mean all the others have to be tails.
00:18:39.000 --> 00:18:47.100
What is the probability of that exact arrangement of heads and tails coming up in 10 flips?
00:18:47.100 --> 00:18:53.200
It means you got to get a tail the first flip then a tail, then a head, then tail-tail, head-head, tail-tail-tail.
00:18:53.200 --> 00:18:56.300
Each one of those has ½ chance of occurring.
00:18:56.300 --> 00:19:11.300
To get that entire sequence, that exact sequence, each one has a ½ ⁺10 or 1/2 ⁺10 chance.
00:19:11.300 --> 00:19:20.800
Any particular exact sequence has a 1/2 ⁺10 chance of occurring.
00:19:20.800 --> 00:19:33.400
The probability of getting all those sequences is 10 choose y × 1/2 ⁺10.
00:19:33.400 --> 00:19:40.100
10 choose y, these are combinations, that is the notation for combinations that I'm using there.
00:19:40.100 --> 00:19:47.800
You could also use the notation C of 10 choose y, if you prefer that notation.
00:19:47.800 --> 00:19:53.400
We use that also in the earlier lecture here on www.educator.com.
00:19:53.400 --> 00:20:02.700
10 choose y divided by 2 ⁺10, that is the total probability that we are going to get exactly y heads.
00:20:02.700 --> 00:20:05.400
Let me remind you the range here.
00:20:05.400 --> 00:20:11.000
This is for all possible values of y from 0 up to 10.
00:20:11.000 --> 00:20:24.300
That is our probability distribution, that is our probability of getting any particular value of y, as y ranges from 0 to 10.
00:20:24.300 --> 00:20:27.900
Let me go back over that and make sure that everything is still clear.
00:20:27.900 --> 00:20:32.400
We are trying to find the probability of any particular value of y, which means
00:20:32.400 --> 00:20:38.300
the probability that our random variable will take the value exactly y,
00:20:38.300 --> 00:20:44.400
which means it will get exactly y heads when we flip the coin 10 ×.
00:20:44.400 --> 00:20:53.200
When we think about that, it means that you are filling in 10 blanks with y heads and 10 - y tails.
00:20:53.200 --> 00:21:02.800
If you think about the number of ways to do that, there are 10 choose y ways to fill in exactly y heads.
00:21:02.800 --> 00:21:09.800
Once you fill in the heads then you have to fill in all the remaining places with tails.
00:21:09.800 --> 00:21:12.800
That was an unordered choice, that was without replacement.
00:21:12.800 --> 00:21:19.700
If you do not remember what those words mean, there is an earlier video here on the educator series on probability.
00:21:19.700 --> 00:21:23.600
You can just go back and look those up and you will see that this is what we are talking about.
00:21:23.600 --> 00:21:29.900
Each one of those ways, each one of those exact sequences has a 1/ 2 ⁺10
00:21:29.900 --> 00:21:33.700
probability of coming up when you flip a coin 10 ×.
00:21:33.700 --> 00:21:42.500
The total probability is 10 choose y divided by 2 ⁺10 or 10 choose y × 1/ 2 ⁺10.
00:21:42.500 --> 00:21:54.200
That is our probability distribution, that is our probability of getting exactly y heads for any number y between 0 and 10.
00:21:54.200 --> 00:21:59.800
In our third example here, we are going to roll a dice repeatedly until we get a 6 showing.
00:21:59.800 --> 00:22:05.700
We want to let y be the number of rolls that it takes for us to see our first 6.
00:22:05.700 --> 00:22:09.700
We want to find the probability distribution for this random variable.
00:22:09.700 --> 00:22:12.000
Let us go ahead and calculate.
00:22:12.000 --> 00:22:16.700
First of all, the range that we can get then different values.
00:22:16.700 --> 00:22:22.100
It could be that we get very lucky that we get a 6 right away.
00:22:22.100 --> 00:22:29.700
Let me write this in that form because our y could be 1, if we get 6 right away.
00:22:29.700 --> 00:22:36.700
If we miss the 6 in the first roll, we get it on the second roll, then it could be 2, it could be 3.
00:22:36.700 --> 00:22:42.800
Actually, this could go on indefinitely because we really do not know how many rolls it might take.
00:22:42.800 --> 00:22:48.900
If we are very unlucky, it could take as 150 rolls before we see the first 6.
00:22:48.900 --> 00:22:55.200
Another way to say this is, 1 is less than or equal to y less than infinity.
00:22:55.200 --> 00:22:59.400
Y could be potentially any positive integer here.
00:22:59.400 --> 00:23:04.400
We are going to have to investigate the probability of each one of those values.
00:23:04.400 --> 00:23:07.100
Let us think about what those probabilities are.
00:23:07.100 --> 00:23:12.500
The probability of getting 1, let me write that in P notation.
00:23:12.500 --> 00:23:16.100
The probability that the random variable is equal to 1.
00:23:16.100 --> 00:23:20.200
That means you get a 6 on your very first roll.
00:23:20.200 --> 00:23:25.600
There is a 1/6 chance that you get a 6 on your very first roll.
00:23:25.600 --> 00:23:29.200
What about the probability that you get 2?
00:23:29.200 --> 00:23:33.000
That is the probability that Y is equal to 2.
00:23:33.000 --> 00:23:35.700
That means you get a 6 on the second roll.
00:23:35.700 --> 00:23:41.100
Think about that, that means you must not have gotten the 6 on the first roll
00:23:41.100 --> 00:23:44.000
because if you got a 6 on the first roll, you would have stop.
00:23:44.000 --> 00:23:52.100
In order to get a 6 exactly on the second roll then you must get a 6 on the first roll,
00:23:52.100 --> 00:23:56.200
there is a 5/6 chance that you are going to fail on that first roll.
00:23:56.200 --> 00:24:04.500
And then, you must get a 6 on the second roll which means there is a 1/6 chance of getting that.
00:24:04.500 --> 00:24:12.600
The probability of taking exactly 2 rolls here is 5/6 × 1/6.
00:24:12.600 --> 00:24:16.400
Or about the probability of getting exactly 3 rolls.
00:24:16.400 --> 00:24:21.900
The probability that our random variable takes the value 3.
00:24:21.900 --> 00:24:25.500
To get 3 rolls that mean you missed getting a 6 on the first 2 rolls.
00:24:25.500 --> 00:24:29.500
It is 5/6 to miss it on the first roll.
00:24:29.500 --> 00:24:35.100
It is 5/6 again, to miss it on the second roll because if we get it on the first and second roll,
00:24:35.100 --> 00:24:44.600
you are not going to get on to 3 rolls, × you have to get it in the 3rd roll so there is 1/6 there.
00:24:44.600 --> 00:24:56.700
This continues here, the probability of taking exactly y rolls which is the probability that Y is equal to the number of y.
00:24:56.700 --> 00:25:09.300
You are going to multiply together a bunch of 5/6 and how many you are going to multiply that, represents losing not getting a 6 on the first y -1 rolls
00:25:09.300 --> 00:25:14.800
because you want to get a 6 exactly on the last roll, on the yth roll.
00:25:14.800 --> 00:25:22.900
It is 5/6 ⁺y -1 × 1/6.
00:25:22.900 --> 00:25:45.400
This represents failing on the first y -1 rolls and this represents succeeding on the yth roll.
00:25:45.400 --> 00:25:51.000
That is what it takes, in order to get exactly y rolls.
00:25:51.000 --> 00:25:56.200
That is our generic formula and let me go ahead and remind you that
00:25:56.200 --> 00:26:05.600
the range for y was any number bigger than or equal to 1 and less than infinity.
00:26:05.600 --> 00:26:16.100
It could be arbitrarily big, it could take thousands and thousands of rolls, if you are very unlucky to get our first 6 here.
00:26:16.100 --> 00:26:17.900
Let me remind you of the steps there.
00:26:17.900 --> 00:26:25.100
We want the probability that is going to take exactly y rolls to get a 6.
00:26:25.100 --> 00:26:33.000
For example, to get exactly one roll, to get a 6, there is a 1/6 chance that we are going to get a 6 on the very first roll.
00:26:33.000 --> 00:26:41.800
2 rolls, we have to get one of the other five numbers for the first roll and then get a 6 for the last roll, for the second roll.
00:26:41.800 --> 00:26:47.200
Three rolls, twice in a row we have to get one of the other five numbers.
00:26:47.200 --> 00:26:50.500
On the third roll, we have to get our 6.
00:26:50.500 --> 00:26:57.500
In general, to get exactly y rolls, we would have to get one of the other five numbers,
00:26:57.500 --> 00:27:02.000
in other words fail to get a 6 on the first y -1 rolls.
00:27:02.000 --> 00:27:08.300
On the very last roll, the yth roll, we have to get a 6, there is a 1/6 chance.
00:27:08.300 --> 00:27:14.600
We put those together as 5/6 ⁺y-1 × 1/6.
00:27:14.600 --> 00:27:27.000
Our range there is from 1 up to potentially as large positive integer as you can imagine there.
00:27:27.000 --> 00:27:29.700
In example 4, we are going to keep track of a soccer match here,
00:27:29.700 --> 00:27:36.700
actually 3 soccer matches between Manchester United and Liverpool football club.
00:27:36.700 --> 00:27:41.900
In any given match, it tells us Liverpool is the stronger team this season.
00:27:41.900 --> 00:27:48.600
They are twice as likely to win as Manchester, I hope I’m not upsetting a huge range of football fans here.
00:27:48.600 --> 00:27:52.200
There are no ties, I’m eliminating ties here.
00:27:52.200 --> 00:27:57.000
We are going to play penalty kicks or something, until we have a winner of every match.
00:27:57.000 --> 00:27:59.900
Let y be the number of matches that Liverpool wins.
00:27:59.900 --> 00:28:03.300
We are going to look at things from Liverpool’s perspective.
00:28:03.300 --> 00:28:08.700
We want to know what is the probability distribution for this random variable?
00:28:08.700 --> 00:28:15.200
The first thing to notice here is that, since Liverpool is twice as likely to win as Manchester,
00:28:15.200 --> 00:28:36.100
in any given match, the probability in each particular match, Liverpool wins with probability,
00:28:36.100 --> 00:28:42.200
If Liverpool is twice as likely to win, they must have a 2/3 chance of winning
00:28:42.200 --> 00:28:45.400
because that would give Manchester 1/3 chance of winning.
00:28:45.400 --> 00:28:50.600
The 2/3 is twice as likely as 1/3.
00:28:50.600 --> 00:28:54.800
Manchester wins with probability is 1/3.
00:28:54.800 --> 00:29:02.300
That is for any particular match, let us try to figure out the probabilities that Liverpool will win a certain number of matches.
00:29:02.300 --> 00:29:10.800
If they are playing three matches then Liverpool might lose all 3, it might win 1, it might win 2, it might win all 3.
00:29:10.800 --> 00:29:15.100
We are going to have to calculate the value 0, 1, 2, and 3.
00:29:15.100 --> 00:29:25.000
The probability of 0, P of 0, that is the probability that Liverpool wins exactly 0 matches.
00:29:25.000 --> 00:29:31.100
In order to win 0 matches, they are going to have to lose all three matches.
00:29:31.100 --> 00:29:33.500
Any given match, they lose a probability 1/3.
00:29:33.500 --> 00:29:41.600
The odds of them losing 3 in a row is 1/3³ which is 1/27.
00:29:41.600 --> 00:29:46.800
That is the probability that Liverpool walks away from three matches without a single win.
00:29:46.800 --> 00:29:56.100
The probability of 1, that is the probability that their total winnings are one match.
00:29:56.100 --> 00:29:59.200
Let us think about that, how can Liverpool win one match?
00:29:59.200 --> 00:30:04.400
One way to do it would be if they win the first one and then lose twice.
00:30:04.400 --> 00:30:13.600
They could lose-win-lose, they could lose-lose and win the final match.
00:30:13.600 --> 00:30:21.500
There are three different possibilities there but each one of those has Liverpool winning one match and losing 2.
00:30:21.500 --> 00:30:32.100
In each one of those three possibilities, there is a 1/3 chance that they will win their relevant match.
00:30:32.100 --> 00:30:37.300
There is a 1/3² chance that they will lose the 2 relevant matches.
00:30:37.300 --> 00:30:44.000
A 2/3 chance that they will win the match that they are supposed to win.
00:30:44.000 --> 00:30:57.700
If we multiply those all together, the 3 and 2/3 give us just 2 × 1/3 × 1/3 that is 2/9.
00:30:57.700 --> 00:31:03.600
2/9 is the total probability that Liverpool will win exactly one match there.
00:31:03.600 --> 00:31:08.800
How about the probability that they will win exactly two matches?
00:31:08.800 --> 00:31:12.600
What is the probability that y is equal 2?
00:31:12.600 --> 00:31:14.700
How can we win two matches?
00:31:14.700 --> 00:31:26.600
They could win the first 2 and then lose, they could win-lose-win, they could lose and then come back and win 2 in a row.
00:31:26.600 --> 00:31:28.800
There are 3 ways that can happen.
00:31:28.800 --> 00:31:35.400
Any particular one of those ways, the likelihood that I have to win 2 particular matches,
00:31:35.400 --> 00:31:38.400
there is a 2/3 chance for each one of those.
00:31:38.400 --> 00:31:45.600
We have to lose a particular match, there is 1/3 chance that they will lose whichever match they are supposed to lose.
00:31:45.600 --> 00:31:49.800
If we multiply those together, the 3 and 1/3 cancel each other out.
00:31:49.800 --> 00:32:01.300
We get 4/9 there, that is the probability that Liverpool will win exactly 2 matches out of their 3 match series there.
00:32:01.300 --> 00:32:06.700
Finally, what is the probability that Liverpool is going to win all three of them?
00:32:06.700 --> 00:32:11.700
Probability that y=3?
00:32:11.700 --> 00:32:16.900
To do that, Liverpool would just have to win-win-win.
00:32:16.900 --> 00:32:20.000
The only way to do that is to win three matches in a row.
00:32:20.000 --> 00:32:32.200
Each one, they have a 2/3 chance, 2/3³ is 8/27.
00:32:32.200 --> 00:32:40.900
8/27, we have our whole probability distribution here.
00:32:40.900 --> 00:32:47.700
We have got the 4 values, y goes from 0 to 3, the four numbers of matches that Liverpool might win.
00:32:47.700 --> 00:32:52.400
We have our probabilities for each one.
00:32:52.400 --> 00:32:54.700
Let me remind you how we figure that out.
00:32:54.700 --> 00:32:59.800
First of all, we know that Liverpool is twice as likely to win as Manchester,
00:32:59.800 --> 00:33:06.100
which means that Liverpool is going to win with probability 2/3, Manchester with probability 1/3.
00:33:06.100 --> 00:33:11.800
We said there are no ties here, we are not allowing ties, that would just make it too complicated.
00:33:11.800 --> 00:33:18.100
We figure out the probability that Liverpool is going to win 0 matches that means they have to lose 3 × in a row.
00:33:18.100 --> 00:33:20.800
There is a 1/27 chance of that.
00:33:20.800 --> 00:33:22.800
How can Liverpool win exactly one match?
00:33:22.800 --> 00:33:25.300
There is three different ways they can do that.
00:33:25.300 --> 00:33:35.400
For each one of those ways, the probability is 1/3 × 1/3 × 2/3, and some of ordering of that.
00:33:35.400 --> 00:33:38.700
You multiply those together, that is where the 2/9 comes from.
00:33:38.700 --> 00:33:40.800
How can we win exactly 2 matches?
00:33:40.800 --> 00:33:43.700
There is three ways they can win exactly 2 matches.
00:33:43.700 --> 00:33:50.700
For any one of those configurations, the probability is 2/3 × 2/3 × 1/3.
00:33:50.700 --> 00:33:53.400
That is where we get the 4/9.
00:33:53.400 --> 00:34:01.300
Finally, the probability that they will win all three matches is they would have to win all three in a row.
00:34:01.300 --> 00:34:06.400
There is a 2/3 × 2/3 × 2/3 chance that they will win all 3.
00:34:06.400 --> 00:34:14.500
That gives us 8/27 for the last value in our probability distribution their.
00:34:14.500 --> 00:34:17.500
In the last example here, you are going to play a game with a friend.
00:34:17.500 --> 00:34:19.500
You are going to do a little gambling with your friend.
00:34:19.500 --> 00:34:24.700
You and your friend are each going to flip a coin, you flip your coin and your friend flips his coin.
00:34:24.700 --> 00:34:29.400
If both the flips come out heads, then your friend has to pay your $10.00.
00:34:29.400 --> 00:34:33.500
If they are both tails then he pays you $5.00.
00:34:33.500 --> 00:34:37.300
If the coins match each other then your friend is going to pay you.
00:34:37.300 --> 00:34:39.300
That is a good thing for you.
00:34:39.300 --> 00:34:45.400
If the coins do not match each other, meaning you get a tail and he gets a head, or you get ahead and he is a tail,
00:34:45.400 --> 00:34:48.300
then he wins and you have to pay him $5.00.
00:34:48.300 --> 00:34:50.800
We are going to look at this from your perspective.
00:34:50.800 --> 00:34:58.700
Let y be the amount you win, we want to find the probability distribution for this random variable.
00:34:58.700 --> 00:35:03.400
I think of all the possible values that y can take and we want to find the probability of each one.
00:35:03.400 --> 00:35:07.200
I’m going to start with just 0 because I like to include it.
00:35:07.200 --> 00:35:18.300
In this case, there is no way that the random variable can come out to be exactly 0 here.
00:35:18.300 --> 00:35:24.100
Depending on what the coins show up, either your friend is going to pay you or you are going to pay your friend.
00:35:24.100 --> 00:35:28.400
There is no outcome that leads to a 0 exchange of money, the probability there is 0.
00:35:28.400 --> 00:35:36.500
The probability that you are going to make $5.00.
00:35:36.500 --> 00:35:42.400
To make $5.00, we have to get both coins being tails.
00:35:42.400 --> 00:35:51.800
What is the probability of tail-tail and the chance of both coins showing tails is ½ × ½ is ¼.
00:35:51.800 --> 00:35:55.700
That is your chance of making $5.00 out of this experiment.
00:35:55.700 --> 00:36:02.600
The probability of you making $10.00 out of this experiment, for that to happen both flips have to be head.
00:36:02.600 --> 00:36:05.800
You got to see 2 heads there.
00:36:05.800 --> 00:36:11.200
The probability of 2 heads is ½ × ½ = ¼.
00:36:11.200 --> 00:36:16.100
If the coins do not match then you have to pay your friend $5.00.
00:36:16.100 --> 00:36:26.500
From your perspective, we got to win -$5.00 but you are really losing $5.00.
00:36:26.500 --> 00:36:35.500
The way that happens is, if you show a tail and he flips a head, or if you flip a head and your friend flips a tail.
00:36:35.500 --> 00:36:40.900
There are 2 possibilities there but each one of those has probability ¼.
00:36:40.900 --> 00:36:49.200
¼ + ¼ is ½.
00:36:49.200 --> 00:36:56.200
Those are all the different outcomes that can happen and those are all the different values of the random variable.
00:36:56.200 --> 00:36:59.600
Those are all the different payoffs that can happen in this experiment.
00:36:59.600 --> 00:37:03.400
I listed 0 even though it is not really a legitimate outcome here.
00:37:03.400 --> 00:37:09.900
I just want to calculate it through, there is a 0 probability that no money is going to change hands here.
00:37:09.900 --> 00:37:15.300
The probability of getting $5.00, we are looking at this from your perspective.
00:37:15.300 --> 00:37:19.800
$5.00 win for you would happen if there are 2 tails.
00:37:19.800 --> 00:37:26.400
To get 2 tails in a row or to get both your coins to come up tails, there is a ¼ chance of that.
00:37:26.400 --> 00:37:32.400
To get 2 heads in a row which is what you need to make $10.00, there is also ¼ chance.
00:37:32.400 --> 00:37:39.200
The probability of getting -$5.00 that means that your friend takes $5.00 from you,
00:37:39.200 --> 00:37:44.800
that has to happen if you flip a head and he flips a tail, or vice versa.
00:37:44.800 --> 00:37:54.700
Each one of those combinations has a 1/4 chance meaning that there is a ½ chance that you are going to end up paying him $5.00.
00:37:54.700 --> 00:38:00.600
That is how we calculated each one of those probabilities for each one of those payoffs.
00:38:00.600 --> 00:38:06.900
That is considered to be the probability distribution for this random variable.
00:38:06.900 --> 00:38:15.200
That is the last example and that wraps up this lecture on random variables and probability distributions.
00:38:15.200 --> 00:38:19.500
This is part of the larger probability series here on www.educator.com.
00:38:19.500 --> 00:38:21.000
My name is Will Murray, thank you for watching, bye.