Skip to content
Part IA Easter Term

Probability Mass Functions

Definition

For a discrete random variable XX, the probability mass function (PMF) gives the probability of each possible value:

p(x)=P(X=x)p(x) = P(X = x)

The function pp completely describes the distribution of XX.

Properties

A valid PMF satisfies:

  1. Non-negativity: p(x)0p(x) \geq 0 for all xx

  2. Sums to 1: xp(x)=1\sum_{x} p(x) = 1 (over all possible values)

  3. Probability computation: For any event EE:

P(XE)=xEp(x)P(X \in E) = \sum_{x \in E} p(x)

Example: Fair Die

For a fair six-sided die:

xxp(x)p(x)
11/61/6
21/61/6
31/61/6
41/61/6
51/61/6
61/61/6

p(x)=16 for x{1,2,3,4,5,6}p(x) = \frac{1}{6} \text{ for } x \in \{1, 2, 3, 4, 5, 6\}

Example: Biased Coin

A biased coin shows heads with probability pp. Let XX = number of heads in one flip.

xxP(X=x)P(X = x)
01p1 - p
1pp

The PMF: p(0)=1pp(0) = 1 - p, p(1)=pp(1) = p.

Example: Two Dice Sum

Roll two fair dice. Let XX = sum of the dice. Values range from 2 to 12.

xxOutcomesp(x)p(x)
2(1,1)1/361/36
3(1,2), (2,1)2/362/36
4(1,3), (2,2), (3,1)3/363/36
5(1,4), (2,3), (3,2), (4,1)4/364/36
65/365/36
76/366/36
85/365/36
94/364/36
103/363/36
112/362/36
121/361/36

Notice the symmetry around 7.

PMF for sum of two dice

Computing with PMFs

To find P(Xa)P(X \leq a):

P(Xa)=xap(x)P(X \leq a) = \sum_{x \leq a} p(x)

To find P(aXb)P(a \leq X \leq b):

P(aXb)=x=abp(x)P(a \leq X \leq b) = \sum_{x=a}^{b} p(x)

Example

For the dice sum: P(X10)=P(X=10)+P(X=11)+P(X=12)=336+236+136=636=16P(X \geq 10) = P(X = 10) + P(X = 11) + P(X = 12) = \frac{3}{36} + \frac{2}{36} + \frac{1}{36} = \frac{6}{36} = \frac{1}{6}.

Support

The support of XX is the set of values where p(x)>0p(x) > 0:

supp(X)={x:p(x)>0}\text{supp}(X) = \{x : p(x) > 0\}

For a fair die: supp(X)={1,2,3,4,5,6}\text{supp}(X) = \{1, 2, 3, 4, 5, 6\}.

Visualising PMFs

PMFs are often shown as bar charts, with bar heights representing probabilities. The total height of all bars equals 1.

PMF visualisation

Joint PMFs

For two discrete random variables XX and YY, the joint PMF is:

p(x,y)=P(X=x,Y=y)p(x, y) = P(X = x, Y = y)

It satisfies:

xyp(x,y)=1\sum_{x} \sum_{y} p(x, y) = 1

The marginal PMF of XX is:

pX(x)=yp(x,y)p_X(x) = \sum_{y} p(x, y)

Summary

ConceptFormula
PMF definitionp(x)=P(X=x)p(x) = P(X = x)
Normalisationxp(x)=1\sum_x p(x) = 1
Event probabilityP(XE)=xEp(x)P(X \in E) = \sum_{x \in E} p(x)
Support{x:p(x)>0}\{x : p(x) > 0\}