 Hi, I'm Zor. Welcome to Unizor Education. This lecture is a continuation of solving combinatorical problems. It's part of the advanced mathematics course for teenagers, which is presented on Unizor.com, and that's exactly where I suggest you to view this lecture, because it contains notes as well as the video itself. And the notes basically contain the same problems which I'm presenting right now with the answer, so you can solve these problems yourself, which is very important, check against the answer, and then there is basically the explanation of how can be derived this particular answer. Alright, so this is not about the playing cards, it's not about poker, as the previous two lectures were in this series. So these are just completely random four different problems on combinatorics, so let's just stop. Alright, so the question is, how many different six-digit numbers exist if three digits are odd and three digits are even? Okay, I suggest we do it in two different ways, and as I said before, if you can approach the problem from two different directions and have the same answer, that's a good checking, because combinatorical problems are very difficult to check. Alright, so I will present it in two different versions. So the version number one, well, let's just think about, we have six digits, right? Now we have three odd, and the odd digits are one, three, five, seven, and nine, five of them, right? And we have three even digits, which is zero, two, four, six, and eight. So if even and odd digits somehow are positioned already among these six, let's say, odd, even, even, odd, odd, even. Okay, this is the position. Place number two and number three and number six are even, and the rest are odd. Okay, so if this distribution among odd and even, even among positions is already set, then basically we can have one of these five different odd digits from these positions, one, two, three, four, sorry, not two, one, three, five, seven, and nine, one, three, five, seven, and nine, one, three, five, seven, and nine, zero, two, four, six, and eight. Zero, two, four, six, and eight. Zero, two, four, six, and eight. So these are the choices. So there are five choices for this, and five choices for this, and five choices for this, etc., etc., right? So basically we have five to one, two, three, to the third degree, four odd, and five to the third degree, four even places, which is basically five to the sixth. Now, that's only if I have already distributed odd and even among six positions, right? Now, how many different distributions of odd and even three digits among six digits is possible? Well, obviously, number of combinations from six by three, right? So I have to choose three places for, let's say, even, all right? Now, if I choose this, it obviously defines already the other places for odd. So if I multiply these, I will get my answer. True, false, and here is a very important detail. Now, among these different distributions, there are obviously distributions when you have the first digit even, like this one. Even, odd, odd, even, even, odd, right? But on the first place, you cannot have zero. So basically we have to exclude from whatever the number of combinations we have, all the different combinations which have zero in front. Okay, that's easy. It's very similar, actually. Let's just think about it. Zero is in front, so the first position is taken and we know which digit actually is there. So we have the five other positions. Now, on five other places, we can have two even, because one is already taken, that's number one, and three odd out of five positions, right? So I have to basically find how many different combinations out of five places if I choose two for the even. Actually, it doesn't matter if I will choose three because number of combinations from five to two is exactly the same as number of combinations from five to three. All right, so if I have chosen any one of these combinations, on any place I can put one of five different even numbers, and there are two places, right? So I have five different even numbers I can put on any of these even places. It doesn't really matter. And three other places for odd, each one has five choices. So it's five times five times five. And I have to subtract from this. I have to subtract this. So all the combinations which have zero in front should be subtracted from this one. And that stands. All right, let's approach this differently. Instead of exclusion, we will use inclusion. You know that in many different cases, the combinatorial problems can be solved in two ways by counting something directly or by counting something bigger and excluding something which we don't really like. That's what we did here. But now let's do it directly, including everything which we need. Okay, on the first place, on the first place, we can have anything but zero, right? So we can have from one to nine. Well, let's just separate odd and even. If my first digit is odd and there are five of them, all right? So I have five choices already. And the first digit is odd. Other five positions can be basically anything and two of them must be odd because one is already here on the first place and three must be even, right? So first of all, I have to choose which one are odd and which one are even. So let's say I choose two positions out of five remaining places for remaining two odd numbers and each one has five different choices. So it's five square. And the remaining three positions, the place of these positions is already determined by choosing the odd positions. So the remaining are even and they can be anything. So we have five different choices for even digits and there are three positions. So I have to multiply five by five by five. So that's my total number of different six digit numbers with three odd and three even with odd in front. Now, how about even in front? Well, you have only four choices, right? I exclude zero, right? So we have directly counting what can be in the first place. Four different choices. So it's four different choices. And then I will do exactly the same. I have two other places for even numbers. One is already taken, right? So out of the remaining five positions, I have to find two for my even numbers and each even number can be chosen among five. So I have to multiply it by five times five. And the remaining three positions are even, so I have this one. And if I will summarize these guys, I better get exactly the same as this number. So you check it. That's it. Next is almost like algebra, basically. I'm asking to solve the following proportion for X and Y. X and Y are natural numbers. Positive and greater than zero, right? So the proportion is CX plus one, Y plus one relates to CX plus one to Y, related to CX plus one to Y minus one, and so five to five to three. Well, basically it's two different equations. One is this one, five to five, and another is this one, five to three. Now, it looks maybe a little scary, but it's not really a scary thing, because all you have to do is to convert these symbolic representations of the number of combinations into their algebraic formula, basically. So I will use the formula mn equals m factorial divided by n factorial and m minus n factorial. Well, that's the formula which I do remember, by the way. It's one of the few formulas which I remember. I don't have to really derive it, but you obviously are welcome to refer to the lecture about the combinations in unizor.com, and you will have it. All right, so that's the formula. And let's just use it. So let's use first these two are related as five to five. Well, five to five means it's actually equals to one, right? So this relates to this equals to one, so CX plus one to Y plus one equals CX plus one to Y plus two Y. So that's what I have. If this relates to this as five to five, then these two are equal to each other. Well, let's just open it up. X plus one factorial divided by Y plus one factorial and Y plus one, so it's X minus one factorial. Equals X plus one factorial divided by Y factorial and X plus Y minus one. X minus Y plus one factorial. X plus one minus one, X plus one minus one, right? Okay, now X and Y are natural numbers. Obviously, we can safely divide both parts by X plus one factorial. Now, let's just think about it. What is M plus one factorial? This is M factorial times M plus one, right? Because this is the product of all numbers from one to M plus one. This is product of all numbers from one to M and then multiply by M plus one. So this is an obvious identity, right? So how we use it in this case? Look, Y factorial and Y plus one factorial. So instead of Y plus one factorial, I can put Y factorial times Y plus one and cancel Y factorial. Same thing here. This is the same as times X minus one factorial, right? And I can cancel X minus one factorial. So what's left? Almost nothing. Basically, I can invert both and I will have Y plus one equals X minus Y plus one. One is also canceling, so X is equal to two Y. That's what I've got from the first proportion. Let me put it here. X equals two Y. All right. Let's do the second proportion and we will have the second equation for X and Y. What's the second proportion? Okay, so it's X plus one factorial, Y factorial and X minus Y plus one factorial. Divided by this guy. X plus one factorial, Y minus one factorial and X minus Y plus two factorial equals to five over three, right? So let's rewrite this instead of this division proportional symbol with one fraction. So X plus one factorial over Y factorial and X minus Y plus one factorial. Now this would go to a denominator, which is X plus one factorial. And these go to a numerator. Y minus one factorial, X minus Y plus two factorial equals five over three. Okay, same thing, canceling this and this. Now Y minus one factorial, now Y factorial is Y times Y minus one factorial, right? So I can divide, replace this and have only Y remaining here. And Y minus one factorial was canceling with this one. Same thing here. This is one greater than this one, which means I can get rid of this and get rid of the factorial here. And what's left? Three times X minus three Y plus six equals five Y, right? So three X equals eight Y minus six, is that right? Okay, let's combine it with this guy. Three X equals eight Y minus six. So we have a system of two linear equations with two variables. And to solve this system, solving this system presents basically no problem with the tool, right? So let's multiply the first one by three and subtract. So what do I have? Zero on the left. And I subtract from this, I subtract this. Eight Y minus six Y, which is two Y minus six. So Y is equal to three and from the first X is equal to six. So that's the solution. That's it. Next. Alright, next is about two basketball teams. Okay, so let's have, you have two basketball teams. One is called green shirts and another is called blue shirts. Now they are playing on some neutral grounds. Some town which is not really the one which is for the greens, not for the blues. So there are a certain number of fans which are initially, well, neutral. Let's put it this way. There are three fans and they are initially neutral. However, they are not exactly neutral. Some of them have certain preferences and the preferences are the M fans out of this K will never be green team fans. And N fans never be blue shirts fans. So they might remain neutral or they might go for blues. And these guys might remain neutral or they will go for greens, but never for blues. And this one never for greens. And the remaining K minus M minus N, they are absolutely open to anything. Depending on their mood, they can go to greens, to blues or stay neutral again. Well, so when the game has ended, well, people have their preferences. They are becoming actually the fans of one or another team. Or they just don't become the fans of anybody. So the question is, how many distribution of fans is possible in this particular situation? Well, for instance, all of these can go to blues. All of these can go to greens. And all the rest can go to blues as well. So you have a certain number of fans for blues, a certain number for greens. Or all of them can stay neutral, for instance. It's available as well because it has never been the green team's fan, but it can stay neutral. So that's another combination. Then there are no fans of any team whatsoever as a result of this game. So the question is, how many different distributions are possible? Okay, let's think about it. How many choices does every person have? Well, the choice can be either he becomes the fan of the green team or the blue team, or stays neutral. So in theory, there are three different choices for every person. But not exactly for every person because we know that these guys cannot be the fans of the green shirts team. So for these guys, there are only two choices. And for these guys also, there are only two choices. But for the remaining K minus M minus N, there are actually three choices. So what do we have right now? We have that. Each one of these M has two choices. So what's the distribution? Well, there are two to the M's. Different distributions of fans among the first team. Two choices for each guy. Either stay neutral or to be a fan of the blue team. Now, similarly, we have only two choices for these guys. Either stay neutral or become the fan of the green team. So this can be never the green, so it can be blue. This is never blue, so it can be green. So both of these guys can have only... I mean, both representatives actually of these groups can have only two choices. So these guys have this type of different choices as a group. And finally, the remaining K minus M minus N people. Each one of them has three choices. So three for the first, three for the second, etc. So we have to actually multiply by three choices that many times. So number of choices for each one of these is two, so it's two times two times two. Number of choices for these guys is also two, so I multiply it by two N times. And number of choices for these guys is this. So if I were to multiply all these numbers, that would give me the total number of different distributions of the fans among the teams. Now, obviously this can be combined into the M plus M. So that's the answer. Now, the last problem I have, well, it requires certain spatial vision. Let me remind you, in one of the lectures, and I do specify which exactly lecture in the notes for this lecture on Unisor.com, I was solving the problem of circles dividing the plane in how many different parts can encircle the maximum to divide the plane. Now I do recommend you actually to return to this problem in Unisor.com just to review how it's solved. Because this one is analogous, but it's in a three-dimension. So let's consider a sphere, and it's cut by different planes, and all these planes go through the center. So this is an equatorial plane, right? Now this can be the meridian plane, or any other plane at any angle to anything, right? But they're all going through the center. So the intersection of the plane and the sphere is actually the great circle, so to speak. It's the circle of the biggest radius, right? Equal to the radius of the sphere. So one plane divides in two parts, right? Two planes, as I have just drawn, divide in four parts. Well, the question is if you have n planes all going through the center of the sphere. Now obviously we need some generalization conditions, so like no three planes go through the same diameter of the sphere. So it's not like a book, so to speak. One plane, then the second plane, and then the third plane from the same diameter. So that's not the case. So they're all different, right? Well, and obviously the question is what's the maximum number of parts the volume of the sphere is divided by n planes? Okay, it's not easy to imagine, right? But it's very important, actually, to try. Here is the consideration which might actually help you in this particular case. Let's function f of n be this maximum number of volume divisions which we have by n planes. Okay, let's just compare it with this number. So what I'm talking about is let's just have n-1 planes and they divide it into some function of n-1. And now let's add to this the nth plane. How many different pieces of volume actually are formed by cutting the nth plane in the most general way through existing picture of a sphere with n-1 plane? I would like to solve this like a recursive dependency. Alright, think about it this way. So if I draw some other plane, let's say this one, generally speaking it should intersect the sphere and this is the intersection. This is the great circle, right? Now this great circle, again in the most general case, should intersect with all other great circles which are formed by intersection of other planes with the sphere. So let's just look at the surface of the sphere. Now this surface has these great circles which are results of intersection of the planes with this sphere. So every new plane introduces a new great circle and what I'm saying is that in the most general case, when we are looking for the most general and maximum number of divisions, it should actually intersect each other great circle formed by previous n-1 planes. So one circle is intersecting with the new circle, the nth circle is intersecting with n-1 circles which were before it. So far so good, right? Now two circles are always intersecting in two points, right? So on this side of the sphere and on that side of the sphere. So basically my new nth circle has two times n-1 points of intersection with previously formed circles, right? We have n-1 previously formed circles, great circles. Now each one has two points with my nth circle so that's number of intersections. Well if this is number of intersections, this is my nth circle and it has certain number of intersections. Well the number of intersections is equal to the number of arcs, right? On the circle. So it has these arcs. But now let's just think about it. What is an arc on this nth circle? Arc is a result of intersection with other circles. And if you are going back to the planes picture, every arc actually together with the two radiuses to the center of the, let's say this is intersection. So this arc together with these radiuses, it represents actually something which this particular plane cuts. So the number of these arcs actually corresponds to the number of cuts to one of the previous pieces of volume which we had. So what I'm saying is that each arc on this great circle actually is a result of dividing one of the previous pieces into two parts. Which means the number of arcs corresponds to the number of new parts we are introducing with this nth plane. And that's why I can write this recursive equation. So since nth plane intersects with all previous n minus one, and if you look at the arcs where the great circles are intersecting, each arc actually represents some kind of a section which we are making. The cut, if you wish, of one of the previous pieces. So for the previous pieces we should add the number of cuts basically because that's so many different new pieces we introduce. Okay, so we have this. It's basically sufficient to get the answer because we know that f of one is equal to two. One plane cuts in two pieces, our sphere. So for one we can go to two, to three, etc. But it would be interesting to get the formula. Alright, so let's get the formula. If you have such a recursive equation, the formula can be obtained quite easily. Right? That's the same recursive for instead of n I put n minus one. Look at this. Let's just add them together. What do I have? This is on the left, this is on the right. And what's remaining? On the left I have f of n. On the right I have two plus two times one, two, three, four, n minus one. Well, we know what this is. This is a arithmetic progression. I don't want actually to go through derivation, but this is a very simple thing. And that's the answer. Actually considering it's very simple, let me just do it this way. I will derive it for you. This is exactly the same sum as here, right? Just reverse. Now add them together. You have two s on the left. And on the right you have one and n minus one, n. Two and n minus n, n, etc. n minus one and one, n. And how many times? n minus one times. That's why it's n times n minus one divided by two. That was the last problem for today's lecture. I think it would be very good if you will go to theunisor.com, go through these problems again and try to solve them again, check against the answer and make sure you get the right results. That would be the very good exercise and you will remember the techniques, etc. Well, that's it for today. Thank you very much and good luck.