 Hi, I'm Zor. Welcome to Unisor Education. This lecture is part of Advanced Mathematics for high school students, presented on Unisor.com website. I do suggest you actually to watch this lecture from this website because it contains notes for the lecture. And well, in addition, basically you can enroll into an entire course with tests, exercises, etc. Alright, now this particular lecture is we're talking about geometric probabilistic distribution. Distribution of probabilities, if you wish. And I would like to illustrate this with a couple of problems. So right now we will just solve a couple of problems. Alright. Problem number one, very simple. Okay. You're playing a roulette and you are betting on one particular number. Whatever the number is, 25. Now, let's consider that the bet is some unit of currency. One, let's say, call it Bitcoin. Not to be dependent on any particular currency. All right, so the bet is one Bitcoin. You have in your pocket 10 Bitcoins. Now, you are looking for the following scenario. You would like to win on the last Bitcoin which you have in your pocket, which means you will lose nine times in a row and the tenth time you will win. All right. Now question is, what's the probability of this event? Now, you know that the number of experiments until the first success in case of geometric distribution can be, basically, it's a random variable and the probability of this random variable to take certain values is very easy to calculate if the probability of success P and you are looking for the value of the number of experiments to be equal to N. What does it mean? It means until the first success, right? So it means that the first N minus 1 experiments should be failure. The probability of failure is 1 minus P, obviously. And since all experiments are independent, the probability of N minus 1 failure in a row will be N minus the power of N minus 1 minus P to the power of N minus 1. And the nth experiment should be a success and the probability is P. So that's basically the formula which I was talking about in the previous lectures. All right. So using this formula what is the probability of 9 failure and 1 success in this particular case? Well, the probability of success in the game of roulette, if you are betting on one particular number, like 25, is equal to 138th, because there are 36 numbers plus two black, whatever, black squares, which are resulting in a loss. So the probability of success is 138th. That's our P. And number of experiments is 10. So N is equal to 10 and according to this formula I will have 3738th to the power of 9 times 138. That's the probability of losing nine games in a row and winning on the tenths. And by the way, I calculated the value is approximately 0.02. So it's like 150th approximately. So that's the probability to win exactly on the ninth, on tenths, sorry, game. So that's the problem number one. Now the problem number two is just the continuation of the problem number one and in this case, I'm interested not only in the win on the tenth number, but just to win. How can I win? I can win either on the first, or on the second, or at the third game, etc., or on the tenth game. If I don't win on the tenth game, I'm bankrupt. I have only 10 bitcoins. So if I lose 10 times in a row, no more games, I'm completely at loss. So if the question is to win, just to win, what's the probability to win? Well, that's the probability of N being equal to 1 or N being equal to 2 or N being equal to 3, etc., or N being equal to 10. Right? Right. Now, in this particular case, we can calculate it in two different ways. There is a very easy way to calculate it. Instead of probability to win on the first, on the second, on the third, etc., on the tenths game, and then adding them up together, I would rather calculate one single probability of losing 10 games in a row, because if I'm losing 10 games in a row, that's it. The game is over, and that's very easy to calculate. If the probability of losing is 1 minus p, the probability of losing N games in a row is 1 minus p to the power of N. So in my case, the probability of winning is 138, the probability of losing is 37, 38, right? So I have to raise it to the power of 10, and that would be my probability of losing. So the probability of winning will be the opposite. The probability of winning will be 1 minus 37, 38 to the power of 10. That's the easy solution. Basically, all normal people would be completely satisfied with this solution. Well, but since I'm not exactly the normal person in this particular case, I would like to convey certain other interesting properties. I would like to use a more difficult way to solve this problem, and hopefully, we'll come up with the same result. So a more difficult way is really to calculate, using the formula for geometric distribution, what's the probability of winning in the first, what's the probability of winning in the second game, etc., up to 10, and then add them up together. And well, if I will get exactly the same result, that's great. But it would be a little bit educational, I would say, to use this particular thing. So it's morally geometric distribution will be used. All right, so how can we do it? Well, the probability again to win on the nth game would be 1 minus p to the power of n minus 1 times p, right? Okay, with n equals to 1, this is n minus 1, this is 0, so this is 1. So I have only 1, 38. With n is equal to 2, I have 37, 38 times 1, 38. With n equal to 3, I have 37, 38 squared times 1, 38. Okay, next, the last one is n is equal to 10, it's 37, 38 to the power of 9 times 1, 38. Now I have to add them up together and see if I will get this. Well, look at this. This is a geometric progression, right? It's not coincidental that the whole distribution is called geometric and this is a geometric progression, by the way. That's the reason, actually. So how can we calculate the sum of this geometric progression? Well, let's basically go back to algebra. We have a geometric progression if we have some kind of a first member and we have the factor d. So the sequence is a, a times d, a times d squared, etc. And the last one is a times d to the power of n minus 1 if I am looking for n members of my geometric progression, right? Now, let's just do a very short trip to the land of algebra and geometric progression. How can I calculate this sum? Well, obviously there is a formula which obviously I don't remember and obviously I know the way how to derive this formula and that's exactly what I will do. If I will multiply by the factor s times d, I will have a d plus a d squared plus, etc. plus a d n minus 1 plus a d to the nth degree, right? So if I will subtract from one to another s minus s d, it's equal to my, these guys will all go down and the only thing which I will have, I will have a minus a d to the n which means s is equal to a minus a d to the n divided by 1 minus d, right? That's how I derived the formula. Now, let's use this in our case. What's our first member a and what's our factor d? The first member is 138 and d, the factor is equal to 3738, right? Every time I'm multiplying by this. And what's my n? n is number of members in my sum. That's from 1 to 10, that's 10. So n is equal to 10. Alright, let's just put it in. So what I have is a, well a can be outside, so it's 138. Now 1 minus d to the nth, which is 3738 to the 10th degree and here I have 1 minus d which is 1 minus 3738. Now this is 138, right? This is 138, so they know if I each other and I have 1 minus 3738 to the 10th degree. It's exactly the same as I had in the beginning as using the short method, alright? Okay, it's just a little exercise. Obviously, again, normal people use the first way to calculate this sum. And by the way, I have the, I think I had the number somewhere. Yes, this number is equal to 0.2341. So you remember if I want to win on the 10th game, the probability was about 150, 0.02. In this case, it's about like 1, between 1 fifth and 1 quarter. Significantly more, because I'm opening up more choices to win, right? Okay, fine. Problem number three, different. No more the game of the left. Now we are playing with dice. Okay, now we have two dice and we sum the numbers. On two dice, we have sum of two numbers. Now, let's choose a particular number N as their sum. And I will play as many times, I will make experiment as many times with two dice, as I need to have sum equal to N. That's my success. So the success is to get exactly the sum equals to N. Now, here is the condition of this particular problem. I know through the experiment, let's put it this way, you have two people. One is thinking about a particular N and I am rolling the dice and the person just tells me, did I succeed or not? Now, after experimenting with 100 million times, I have come up with an average number of experiments to succeed. I mean, in some cases I got more rollings to make to get to this number the person has thought about sometimes less, but as the result of the 100 million experiments or infinite number of experiments, I came to a conclusion that I need approximately an average six experiments, six rolls of the two dice to succeed, to have the sum equals to N. And now I can guess the number N. The question is how? So again, one person thinks about number N, I am rolling two dice and if the sum hits that number which the person has thought about, that's a success. If not, it's a failure. So he tells me, succeed or fail, succeed or fail. And I know that average six attempts I need to succeed. The question is what is the number N? Okay. Now, let's think about, as long as N is given, I know the probability to hit this number. Let's say the probability is equal to P. Now, we certainly have a geometric distribution of the number of attempts to succeed. So if the probability of success is P, then we are talking about this geometric distribution and in the previous lecture, I was talking very easily to prove that the average or mathematical expectation, if you wish, of this particular random variable is equal to 1 over P. That's the average number of experiments to succeed or average value of this random variable which is number of attempts to succeed. Now, if you don't remember this, go to the previous lecture where I basically explain why it happens. Basically, I proved it. So what I know right now is I know that this is equal to six, which means P is equal to 1,6. Now, the question is, what is N if P is equal to 1,6? That's basically the answer to our problem, right? All right, let's just think about it. What can N be? Obviously, the minimum number is 2 when you have 1 and 1, right? Then for the number 3, you have either this or this. One dice equals to one another two or one is equal to two and another is one. So here we have only one combination of the two dice. Here we have two combinations. With N is equal to 4, I have 1 plus 2, sorry, 1 plus 3, 2 plus 2 and 3 plus 1. Three combinations. With 5, I have 1 plus 4, 2 plus 3, 3 plus 2, 4 plus 1. Four combinations. With 6, 1 plus 5, 2 plus 4, 3 plus 3, 4 plus 2 and 5 plus 1. That's five combinations. With 7, I have 1 plus 6 or 2 plus 5 or 3 plus 4 or 4 plus 3 or 3, sorry, 5 plus 2 or 6 plus 1. And this is six combinations. Now, how many combinations altogether when I'm throwing two dice? Well, six and one, six and another, independent, so it's 6 times 6, it's 36. Right? So the probability of having only number 2 as a sum of two numbers on two dice is only one case out of 36. So the probability is 136. Probability to hit number 3 as a sum, since I have two different combinations out of 36, it would be 236, right? Probability of this is 336. Probability of this is 636, which is 16, which is what we actually need. Now, if I will go further, 8, the number of cases would be lower, so it would be again 5, 4, 3, 2, 1, etc. So the probability would be less than... So this is the only case with a 7 when the number of different variations of two dice to get the number 7 as a sum is equal to 6, so the probability of hitting number 7 is 636 or 16. That's the only way. So my number n, which I was thinking about in the very beginning, must be equal to 7 because only if it's 7, the average number of experiments to get the sum of two dice equal to 7 would be equal to 6 because it's a geometric progression and the probability of success is 16. Okay, so let me just continue this. For 8 I can have 2 plus 6, 3 plus 5, 4 plus 4, 5 plus 3, sorry, and 6 plus 2. 1, 2, 3, 4, 5. You see? It goes down. Obviously it goes down. For the 9 it would be 3 plus 6, 4 plus 5, 5 plus 4, 6 plus 3. That's number 4, etc. Up to 12, only 6 plus 6, which is only one case. So the probability to hit 12 is 136. By the way, the same as 2. Alright, so basically that ends up this particular problem. If I have the number, an average number of the attempts to get a success, that actually gives me the probability of success. They are the same, basically, together. If p is probability of success, 1 over p is the mathematical expectation of the number of attempts to succeed. And that basically ends this particular lecture. I encourage you to go to the website to Unisor.com and not only you will find the whole course, which contains many different lectures, which you can actually study in the sequence, but also there are some exams, which are always very, very helpful to self-evaluate yourself. Thank you very much and good luck.