Two tasks produce random counts and , and the question is how their total is distributed. The mean of the total is the sum of the two means whenever those are finite, but the distribution asks for more. It asks which pairs of counts produce each total and how likely those pairs are. This lesson builds the distribution of a sum from ordered pairs, writes the collecting step as one formula, and shows exactly where independence enters, first in the pair probabilities and then in the variance.
Key terms
Ordered-pair table
Definition Let and be discrete random variables on the same sample space, each with finitely many possible values. Their ordered-pair table has one row for each possible value of and one column for each possible value of . The cell in row and column stands for the event and holds its probability , together with the total . Different cells are disjoint events, and their probabilities add to . If and are independent, every cell probability is the product .
In plain words The table records which task produced which count before anything is added. The pair with and and the pair with and give the same total, but they are different outcomes and can have different probabilities.
Example In a constructed model, let equal , or with probabilities , and , and let equal or with probabilities and , independently of . Each cell below shows its probability and its total.
| , total | , total | |
| , total | , total | |
| , total | , total |
For instance, the top left cell has probability . The six cell probabilities add to .
Distribution of a sum
Definition Let and be discrete random variables on the same sample space. Their sum is a discrete random variable, and its PMF is
where the sum runs over all pairs with a possible value of , a possible value of and . The events for different pairs are disjoint, so their probabilities add. The formula uses the joint probabilities of the pairs. In general the two separate distributions of and do not determine , and more must be known about how the variables are related, for example that they are independent.
In plain words Group the cells of the table by their total and add the probabilities inside each group. Counting the cells in a group instead of adding their probabilities works when all cells are equally likely, and it can mislead otherwise.
Example In the table above, the total comes from the cells and , so . Collecting every total gives the PMF of .
The numerators add to , as they must when every cell is used exactly once. Two cells give the total , but the total is more likely, since its one cell has probability .
Discrete convolution
Definition If and are independent discrete random variables, the PMF of is
where runs over the possible values of , and whenever is not a possible value of . This operation on two PMFs is called discrete convolution, and is the convolution of and . Once and the total are fixed, the partner value is forced, so each compatible pair is counted exactly once.
In plain words For each possible value of the first variable, find the value of the second that completes the total, multiply the two probabilities and add over the first variable. It is the table calculation written as one formula, and the product inside it relies on independence.
Example For the variables of the table, takes only the values and , so
The middle term is because never equals , and the result matches the two cells collected from the table.
Variance of an independent sum
Definition Let and be random variables on the same sample space with finite variances. Then , with or without independence. If in addition and are independent, then
For independent and the standard deviation of the sum is therefore , which is at most and is strictly smaller unless one of the two variances is .
In plain words Means add for any two variables with finite means. Variances add for independent variables, because for them the cross term in the next card averages to zero. To combine standard deviations, add the variances first and take the square root at the end.
Example For the independent variables of the table, and , so . The deviations of are , and , so , and , so the rule gives . The PMF of confirms this, since , and . The standard deviation of is , smaller than .
Cross term
Definition Let and have finite variances, and write and for their deviations from their means. The deviation of the sum is , and
Taking expectations gives
The term is the cross term. If and are independent, then , and the variances add. Without independence the cross term can be positive, negative or zero. The average product is the covariance of and , the subject of the lesson Covariance, Correlation and Sums.
In plain words The cross term is twice the average product of the two deviations. A product is positive when both variables fall on the same side of their means and negative when they fall on opposite sides. When the positive products outweigh the negative ones on average, the deviations reinforce each other and the sum spreads more than the two variances alone suggest. When the negative products outweigh the positive ones, the deviations partly cancel and the sum spreads less.
Example Keep as before, but now let exactly when , and otherwise. Then and , the same distribution of as before, but now and are dependent. The sum equals , or with probabilities , and . Its mean is still , but , so instead of . The difference is the cross term. Directly, with and , the product equals when , when and when , so and the cross term is . The two separate distributions are unchanged, yet the distribution and the variance of the sum are different.
Check yourself
- Two independent selections are each uniform on , and is their sum. Find the PMF of , its mean and its variance.
Show the answer
The nine ordered pairs are equally likely, each with probability , so here counting cells is valid. The totals , , , and come from , , , and pairs, so takes these values with probabilities , , , and . The mean is by symmetry, or by linearity. One selection has second moment and variance , so independence gives . As a check from the PMF, and .
- A count equals or with probabilities and , and an independent count equals , or with probabilities , and . Use discrete convolution to find the PMF of , say which total is most likely, and check that .
Show the answer
For each total, add over and . This gives , , and , which add to . The most likely total is . For the variances, gives , and with gives . From the PMF, , which equals , and , so .
- Let equal or with probability each, so . In each case below has the same distribution as . Find when is independent of , when , and when . What does the comparison show?
Show the answer
With independence, the variances add to . With , the sum is , whose variance is , so the cross term is . With , the sum is with probability , whose variance is , so the cross term is . In all three cases and have the same separate distributions, yet the variance of the sum is , or . The variance of a sum depends on how the variables are related. The variances add exactly when the cross term is zero, and independence is one condition that guarantees this.