|
Coin tossing
When you tossed the coin, you most likely found that you were much more
successful at predicting how many heads and tails would turn up for 100
flips than for any individual flip. Most people understand that you
have a 50-50 chance of getting a head or tail when you flip the coin.
This means that for a large number of throws, you will get close to an equal
number of heads and tails, so if you flip 1000 times, you would expect about
500 heads and 500 tails. The coin in this experiment is called a
fair coin because there is an equal chance of getting heads or tails.
|
 |
What is sometimes difficult to understand is that each time you flip the
coin, you have a 50-50 chance of a head or a tail, and it doesn’t matter
what you got in the previous flips. If you flip the coin and you get 15
heads in a row, it is just as likely you will get a head as you will get a
tail on the 16th
try. By flipping the coin, you have actually been using a random number
generator. Computers do not act in a random way, like a coin
flip. Without a random number generator of some sort, a
computer’s version of the coin-flipping experiment would be to get
the same order of heads and tails every time it ran the experiment. |
This behavior is called
deterministic: you know the outcome of every single flip in the
experiment. When we need random numbers in computer programming, we
need clever ways to get the computer to generate
random numbers. Follow the link to find out how this can be done.
Tossing single die
A fair die has six sides, each with the same probability of showing on the
top face when rolled. For a large number of throws, we would expect
1/6 of the time the top face would show one dot, 1/6 of the time it would
show two dots, and so on up to six dots. Notice that 1/6 + 1/6 + 1/6 +
1/6 + 1/6 + 1/6 adds up to the number 1.
|
 |
Probabilities are expressed
in terms of fractions (or decimals) so that when you add up the fractions
for all the things that could possibly happen, you get 1. If an event
is certain to happen, like getting heads when flipping a two-headed coin, it
has a probability of 1. If an event has no chance of happening,
like getting tails while flipping a two-headed coin, it has a probability of
zero.
The complete set of possible
events is known technically as the
sample space. The
sample space for the coin flipping experiment is two events, heads and
tails. The sample space for a single die is six events; the top face
could show one, two, three, four, five or six dots after being rolled. |
In the experiment with two dice, you were encouraged to predict the
frequency of each event. A reasonable way to proceed is to first
figure out your sample space, then predict the probability, what fraction of
throws you expect would occur, for each event.
Tossing two dice
The two top faces of the dice can add up to the numbers 2 through 12, a
total of eleven numbers. If we look at all the combinations of numbers
the top faces could show, we find that 2 and 12 are the least likely to
occur because only one configuration of the dice will yield these numbers.
The most likely number is 7 because it has the most number of combinations
adding up to seven.
|
 |
We can mathematically predict how often a particular number will show up by
combining the probabilities for individual die. To get a total of 2,
each die must show one dot. The probability for each die that it will
show one dot is 1/6. 1/6 x 1/6 = 1/36. We would expect that on average, the
value 2 would show up 1/36th of the time. |
Let’s try this for a total of 3. There are two combinations for this,
1 + 2 or 2 + 1. Each combination has a probability of 1/6 x 1/6, or
1/36. Since it is possible to obtain a sum of 3 in two ways, we have
1/36 + 1/36 = 2/36. A sum of 3 would show up twice as often as a sum
of 2. See if you can work out the probabilities for the other events
from 4 to 12 using this mathematical model. When you get confidence in
your predictive ability, you can extend your predictions to tossing larger
numbers of dice and check your results with the experiment.
If we graph results for a large number of throws, an important shape starts
to appear known as a normal distribution, also called a Gaussian
distribution. For example of such, consider the figure above.
You may know this curve from grades in school. In grading, the tall
central portion would represent a “C”, and the very short portions on the
sides would represent “A” and “F”. In many schools and colleges grades
do not follow a normal distribution because of a phenomenon called grade
inflation, where there are a large number of A’s and B’s assigned and fewer
C’s, D’s and F’s. Such a distribution is said to be
skewed, for example see the picture below. It is important to be aware that
events do not always occur with equal probability or follow a symmetrical normal distribution.
We have been examining processes that are random and unpredictable for
individual events but predictable for a large number of events. These
processes are called
stochastic. The great
thing about using stochastic models in physics, chemistry and biocomplexity
is that we can model a huge number of objects without having to predict the
behavior of each individual object. In fact, it is impossible to know
what each individual will do at every given time, but we can know very well
how the group as a whole will behave. |