DISCRETE RANDOM VARIABLES
1. Probability Distributions
Consider an experiment in which a fair dice is thrown and the score is noted. The table below shows the probability distribution.
x / 1 / 2 / 3 / 4 / 5 / 6We use X (although it can be any capital letter) to denote the score. We say the score is a discrete random variable : discrete because it can only take certain integer values, random because there is no pattern in the sequence of scores the dice produces, and variable because it can take different values.
We use the corresponding lower case italic letter to represent particular values x can take.
Note that the probability distribution takes the form of a comprehensive table. We can summarise this as the probability function.
Finally, note that all the probabilities add up to 1, as we would expect.
Example1:Two fair dice are thrown and the difference between the two scores is recorded. Find the probability distribution for D, the difference between the two scores.
We first draw up a sample space diagram.
1 / 2 / 3 / 4 / 5 / 61 / 0 / 1 / 2 / 3 / 4 / 5
2 / 1 / 0 / 1 / 2 / 3 / 4
3 / 2 / 1 / 0 / 1 / 2 / 3
4 / 3 / 2 / 1 / 0 / 1 / 2
5 / 4 / 3 / 2 / 1 / 0 / 1
6 / 5 / 4 / 3 / 2 / 1 / 0
The probability distribution is therefore
d / 0 / 1 / 2 / 3 / 4 / 5Example2:Let X be the discrete variable ‘the number of fours obtained when two dice are rolled’. Find the probability distribution.
The probability distribution is therefore
x / 0 / 1 / 2Example3:Two tetrahedral dice, each with faces labelled 1, 2, 3 and 4, are thrown and their scores noted. If S is the random variable ‘the sum of the scores on the two dice’, find the probability distribution of S.
We first draw up a sample space diagram.
1 / 2 / 3 / 41 / 2 / 3 / 4 / 5
2 / 3 / 4 / 5 / 6
3 / 4 / 5 / 6 / 7
4 / 5 / 6 / 7 / 8
The probability distribution is therefore
s / 2 / 3 / 4 / 5 / 6 / 7 / 8The probability function can be written as
Example4:The probability function a discrete random variable Y is given by for . Given that c is a constant, calculate the value of c.
We can draw up the probability distribution;
y / 0 / 1 / 2 / 3 / 4/ 0 / c / / /
The probabilities must add up to 1.
Example5:The probability function of the discrete random variable X is given by
Find the value of the constant k.
The probability function consists of a convergent GP. We can use the formula from unit C2 for the sum of a convergent GP with first term a and common ratio r.
2. The Cumulative Distribution Function
The cumulative distribution function of x is the probability that a discrete random variable takes a value less than or equal to x. We write
Example1:Two fair tetrahedral dice, each with faces labelled 1, 2, 3 and 4, are thrown and their scores noted. If G is the random variable ‘the greater of the scores on the two dice’,
a) find the probability distribution of G,
b) find the values of F(2) and F(3.9).
a)We first draw up a sample space diagram.
1 / 2 / 3 / 41 / 1 / 2 / 3 / 4
2 / 2 / 2 / 3 / 4
3 / 3 / 3 / 3 / 4
4 / 4 / 4 / 4 / 4
The probability distribution is therefore
g / 1 / 2 / 3 / 4b) / /
p150 Ex 8A
3. Expectation and Variance of a Discrete Random Variable
There are clear similarities between the theoretical probability distribution and a frequency distribution and so there are similarities between some of the statistical measures we use for frequency distributions and the equivalent statistics for a probability distribution. For a probability distribution we concentrate on the expectation of X (or the expected value of X which corresponds to the mean), and the variance of X.
Consider the probability distribution for example 1 in the previous section.
g / 1 / 2 / 3 / 4Notice that we expect to get one-sixteenth of the time, three-sixteenths of the time, and so on. So the expected value of G is given by
This value seems reasonable. It is in fact the value that the mean of G would tend to if the experiment were carried out many, many times.
We generalise to the formula
To find the variance, let us return to our formula for the variance of a data set,
Notice that the first term in the RHS is the mean of the squares, which translates to the expectation of the square of X. The second term of the RHS is the square of the mean, which translates to the square of the expectation of X. So we have
So to find the variance of our distribution,
We can square root this to find the standard deviation, which comes out at 0.927, to three decimal places, which again seems reasonable for our distribution.
Example1:A discrete random variable X has the probability function;
Find the values of k, and .
We first set up the probability distribution.
x / 0 / 1 / 2 / 3/ 0 / k / /
The probabilities must add up to 1, and so
Rewriting the probability distribution,
x / 0 / 1 / 2 / 3/ 0 / / /
Example2:Three coins are tossed. Find the expectation and variance for the number of heads.
Let H represent the number of heads. Some simple probability work gives us this distribution.
h / 0 / 1 / 2 / 3By symmetry (an important shortcut in mathematics!),
p157 Ex 8B
4. Linear Functions of Discrete Random Variables
Recall these results from the Measures of Dispersiontopic.
data / mean / standard deviationWe can translate these results for use with probability distributions.
The arises because the variance is the square of the standard deviation.
Example1:The discrete random variable X has and . Find the expectation and variance of
a) b) c)
Example2:For the probability distribution below, find
a) b) c) d) .
/ 0.3 / 0.2 / 0.05 / 0.45
a) / / c) /
b) / / d) /
p160 Ex 8C
5. The Discrete Uniform Distribution
We began this topic by looking at the probability distribution when a dice is thrown.
x / 1 / 2 / 3 / 4 / 5 / 6This is an example of a discrete uniform distribution, one in which each possible outcome has the same probability as every other. Calculations of the expectation and variance for discrete uniform distributions are slightly simpler than for other distributions.
Example1:Find the expectation and variance for the score on a dice.
Example2:A bag contains four Russian banknotes, worth 5, 10, 20 and 50 roubles respectively. An experiment consists of repeatedly taking a note from the bag at random. Find the expectation and variance for the probability distribution.
x / 5 / 10 / 20 / 50If the possible outcomes are {1, 2, 3, ..., n}, each with a probability of (such as scores on a dice, or choosing an integer at random from 1 to 10, then we have the following standard formulas, which must be learned as they do not appear in the formula booklet.
Checking these formulas with example 1 above,
Note that these formulas will not work with example 2 as the possible outcomes are not of the form {1, 2, 3, ..., n}.
Example3:A spinner in the form of a regular octagon has sections numbered from 1 to 8. Assuming the spinner is fair, find
a) b) c) d) .
a) / / c) /b) / / d) /
Example4:The random variable X has the discrete uniform distribution on the set {1, 2, 3, ..., n}. Find n given that
a) b) c) d) .
a) / / b) / / c) / / d) /p165 Ex 8D Topic Review : Discrete Random Variables