Our life is full of unpredictability. Whether you are thinking about sports competitions, tomorrow's unstable train schedule, or next week's weather forecast, you often do not know exactly how it is going to end. Everything you can do is to guess and sometimes hope it ends the way you need.
Probability provides precise mathematical rules for understanding and analyzing problems. It does not tell you the winner of competitions, does not ask the train station worker about transport routes, and does not make the sky clear. Instead, it gives you an understanding and a couple of skills to make decisions based on what you should and should not do in different situations. If there is a 95% chance that the train will not come, you can plan your route from home to the office differently.
This topic is going to talk about outcomes of different but simple and clear examples. It will help you to understand the main concept of probability theory and introduce commonly used concepts from combinatorics.
Flipping coin
Imagine you are flipping a fair two-sided coin. Which side will it land on? Well, there are only two options: heads or tails. The number of all options you can get is the number of outcomes, and one flip gives us two different outcomes. As you can see, it is a 50/50 chance of getting heads or tails.
Let's say you flip a coin twice in a row. If the first flip results in heads, there are still only options for the second flip: heads or tails. If the first flip lands on tails, again, there are only options for the second flip: heads or tails. In each of the possible outcomes from the first flip, there are possible outcomes for the second flip. Therefore, you have a total of possible outcomes. Check out the table below for a visual representation:
| Tail second | Head second | |
| Tail first | TT | TH |
| Head first | HT | HH |
It also can be illustrated by a binary tree:
Okay, what if you flip the coin times? A binary tree describes the situation clearer:
The last row is all possible outcomes, and if you count them, you can see that the total is . Although it may not always be possible in a probabilistic problem to calculate all outcomes, there is no reason to not do that when you can.
How could you get this number without a picture? Let's break it down. For each possible outcome of the first coin flip, there are a certain number of possible outcomes for the second flip, and then for the third flip.Thus, coin flipped times gives possible outcomes.
Ready to count all outcomes of flipping a coin times? It is like you have already flipped it times (getting possible outcomes) and now want to flip one more time (as you already know, it is going to be heads or tails). So there are possible outcomes — and you do not need to make a binary tree to confirm it!
Now you are ready to formulate the first conclusion.
A two-sided coin flipped times gives possible outcomes
For example, a coin flipped times gives possible outcomes, and there are outcomes if you flip the coin times. Imagine drawing such a binary tree! It would take a lot of space and would be tedious to do by hand. Thankfully the formula helps us to avoid manual calculations.
When considering the flips and number of total outcomes, you don't care about the particular order. But what if you need to be more specific and want to investigate particular combinations? In this case, you have to work with permutations.
Permutations
Suppose you bought named concert tickets for yourself and two friends. Before the staff checks everyone's ticket, you randomly give one ticket to one friend. Is there any chance that all of you are holding your own named ticket now? And how lucky are you if it is?
Let's name all persons as and give them tickets (first ticket belongs to , second one is to and third one is to ). Now describe all possible outcomes and check your luckiness:
There are no other ways to rearrange tickets, so if everyone got their own ticket, there is only chance of possible outcomes.
In other words, we have just described and calculated all possible permutations of items.
Order is very important when it comes to permutations. How to calculate it without naming all outcomes? First, you have three choices for the first ticket for person (let it be ticket number for example). Then you have two available options for (as number is unavailable now, there are tickets number or , let it be ). And finally, there is only one ticket left for — ticket number . Thus, three tickets can be permutated different ways: for each of possible outcomes to give the first ticket, there are possible outcomes to give the second one and only possible outcome to give the third one.
What about tickets for persons? It is better to draw a tree when every branch from the top to the bottom is an outcome. For example, the colored path indicates the order . Take a look:
Having all possible branches in the tree, you are able to count all outcomes now: to get all paths from the top to the bottom is the same as counting the number of terminal points of the tree! A set of terminal points gives you possible ways to permutate items, and it is equal to .
Now you are ready to define the permutation's formula.
The number of all permutations of items is
The sign"" after the number is called factorial of number . Factorial of zero is equal to : there is only one way to permutate a set with no elements.
Five books on a bookshelf can be permutated in ways, and there are ways to define the queue of people at the cash desk.
A permutation of items is also called a permutation of length . Since writing out exclamation marks or direct explicit multiplication takes too much space (and sometimes you need the context that it is indeed permutations and not just a factorial), the common notation for the number of permutations is denoted as .
Combinations of a match-making
Let's say we want to know some possibilities but we don't care about the order inside the subset. For this let's turn to throwing dice. Suppose we roll two six-sided dices. There are possible outcomes for each dice: . Let's calculate all possible outcomes filling the following table:
Since each dice has possible outcomes, this is referred to the multiplicational principle again: for each of the possible outcomes first dice gave there are possible outcomes second dice gave. Therefore, six-sided dice rolled twice outcomes different ways. It also can be illustrated by a tree:
Now what if you roll one six-sided dice and another one with only odd numbers going twice on its sides? How to count all the different pairs? First, let's make a table the way you did before, but this time the green dice would only have values of 1, 3, and 5 (it still has six sides, though):
You got pairs again since you throw two six-sided dice. The key point is that every second column of the table is a copy of the previous one. Half of all cells are not unique because only of second dice's sides are different. Thus, there are only different pairs.
Dice's research leads to the multiplication formula of making a pair.
All elements of both sets are different, and all pairs are different as well: you can make two-words phrases "adjective+noun" using sets "red, green, blue, yellow" and "cup, hat, pillow", all words and pairs are unique and different.
Picking marbles
The cases above used all the items you are working with. If you permutate tickets, you choose the owner for each of them. If you make pairs, you match every first possible item with the second possible one. Now you are going to look at selection — a situation when you pick only a few items, not all of them.
Imagine there is an urn with marbles: red, green, blue, yellow, and violet. You pick two marbles at random. Order does not matter: pairs "red+green" and "green+red" are equivalent. Given this, how many outcomes will you get?
Let's make a table. You will use the first letter to mark colors: pair "red+green" will be described as "RG". Since there are only marbles, a combination "RR" or any other "same-color-twice" pair does not exist: picking red marble as the first one, there is no option to pick it twice.
Now look at all combinations we get:
| 1st \ 2nd | Red | Green | Blue | Yellow | Violet |
| Red | - | RG | RB | RY | RV |
| Green | GR | - | GB | GY | GV |
| Blue | BR | BG | - | BY | BV |
| Yellow | YR | YG | YB | - | YV |
| Violet | VR | VG | VB | VY | - |
Counting all color pairs for this, you get possible outcomes. Since order does not matter and you are looking for unique sets, half of the cells are unnecessary: pairs GR and RG mean the same. Therefore, there are only ways to pick marbles out of , not . To be more formal, you count all combinations of size that can you can form from items.
Combinations are the number of possible subsets length in a set of items length
The order of selection is not important. All that matters is which marbles you pick.
Making combinations of marbles from a set of marbles is a bit complicated. Fortunately, there is a way to calculate all of them. And you are just only one step away from it!
You can pick the first marble in ways: all marbles are available now. There are marbles available after the first pick, therefore now you can pick the second one in different ways. Next only marbles left, so you can pick the third marble in ways. For each of the possible outcomes of the first pick, there are possible outcomes of the second one and possible outcomes of the third one. The multiplicational principle gives you possible ways to make a marble trio. However, outcomes "red+green+blue" and "red+blue+green" are not different: order does not matter. So to get the final answer, you need to exclude all undifferent outcomes — to count permutations of marbles. Three marbles give permutations. This means that getting as an answer is times greater than it is actually needed. Therefore, the number of all different combinations of marbles from a set of marbles is .
This was tedious, but there is good news: a number of combinations has its special formula that allows you to calculate them for any number of outcomes!
The number of all combinations of size that can be formed from items is
The number of all combinations is denoted as or a binomial coefficient , that depends on the traditions of the particular field. Usually, in probability, we use notation, the lower number is always greater than the upper one, so it may help you to not get confused. Take into account that subscript and superscript in changed places for and , in this case, the upper number is greater than the lower one.
Let's use the formula to out of marble's case and check the answer:
Surprisingly picking up marbles out of leads to the same result — and it is totally logical since if you pick marbles, there would be marbles staying in the bag. The formula proves it mathematically:
Let's mark it as a symmetrical conclusion.
There are other combinatorial formulas for other cases, but we covered the most commonly used ones, and now you are ready to continue applying them to study probability.
Conclusion
The main concept of probability theory is based on counting outcomes — all desired and possible ones. To calculate it wisely, here are some conclusions:
- A two-sided coin flipped times gives possible outcomes
- The number of permutation of items is equal to
- There are possible outcomes for six-sided dice rolled twice
-
The number of ways to make a pair is for two sets of and different elements
-
The number of all combinations of size that can be formed from items is . Item's order (in subset of size ) is not taken into account in this formula
-
The number of all combinations is symmetrical: