When Counting Where The Bombs Fell Became A Math Problem
During the 1944 flying-bomb attacks, London was split into 576 equal squares to count hits per square. Each square held a whole number of hits (0, 1, 2, or 3), never 2.7 of a hit. That count is a discrete random variable: a number that depends on chance and that you can only ever land on in whole, separated steps. Statistician R. D. Clarke checked whether the hits clustered (a targeted weapon) or scattered at random, and the counting variable is what let him answer it.
A discrete random variable is the simplest bridge between "an experiment happened" and "here is a number we can do algebra on." Once each outcome carries a number, averages, spread, and prediction all become arithmetic.
What Is A Discrete Random Variable?
A random variable is a rule that assigns a single real number to every outcome of a random experiment. A discrete random variable is a random variable whose set of possible values is countable - either finite (like the six faces of a die) or countably infinite (like "how many times you flip until the first head," which could be 1, 2, 3, and so on without end).
The word "discrete" means the values sit apart from each other with gaps between them, the way whole numbers do. Between the value 2 and the value 3 there is no allowed value for a die count. That is the exact opposite of a continuous random variable, whose values fill an unbroken interval - a person's exact height could be 170 cm, 170.4 cm, or 170.41 cm, with no gaps.
We usually write a random variable with a capital letter such as $X$, and a specific value it takes with a lowercase letter such as $x$. So $P(X = x)$ reads "the probability that the variable $X$ takes the particular value $x$."
What Is The Probability Mass Function (PMF)?
The behaviour of a discrete random variable is described by its probability mass function, written $p(x) = P(X = x)$. The PMF is simply a list: every value the variable can take, paired with the probability of that value. Some sources call the same list a probability distribution table.
A function $p(x)$ is a valid PMF exactly when it obeys two rules:
Each probability is between 0 and 1: $0 \le p(x) \le 1$ for every value $x$.
The probabilities add up to 1: $\sum_{x} p(x) = 1$, because one of the outcomes is certain to happen.
For a fair six-sided die, the PMF is $p(x) = \tfrac{1}{6}$ for each $x$ in the set ${1, 2, 3, 4, 5, 6}$, and those six sixths sum to 1. The name "mass" is deliberate: each value carries a lump of probability, like a weight sitting at a point on the number line.
Closely related is the cumulative distribution function (CDF), $F(x) = P(X \le x)$, which adds up the PMF from the smallest value up to $x$. The CDF answers "what is the chance of getting at most $x$," and it never decreases as $x$ grows.
What Are The Types Of Discrete Random Variables?
Most school and early-university problems reduce to a handful of named families. Each is a discrete random variable with a known PMF:
Bernoulli. A single trial with two outcomes, success (1) or failure (0), with success probability $p$. The count of heads in one coin flip is Bernoulli.
Binomial. The number of successes in $n$ independent Bernoulli trials, such as the number of heads in 10 flips. Its PMF uses the binomial theorem coefficients.
Geometric. The number of trials up to and including the first success, such as "how many rolls until the first six." This one is countably infinite.
Poisson. The number of rare events in a fixed window of time or space, such as the flying-bomb hits per square, or calls arriving at a help line in a minute.
You do not need every formula memorised to work with a discrete random variable - you need the PMF, and the two rules that make it valid.
How Do You Find The Expected Value Of A Discrete Random Variable?
The expected value (also called the mean or $E(X)$) is the long-run average value of the variable over many repeats of the experiment. You weight each value by its probability and add:
$$E(X) = \mu = \sum_{x} x , p(x).$$
Read that as "multiply each value by its own probability, then total the results." Here $x$ is a value the variable can take and $p(x)$ is the probability of that value. The expected value is the balance point of the PMF — the spot where the probability weights would sit level on a see-saw.
For the fair die, the expected value is $$E(X) = 1\cdot\tfrac{1}{6} + 2\cdot\tfrac{1}{6} + 3\cdot\tfrac{1}{6} + 4\cdot\tfrac{1}{6} + 5\cdot\tfrac{1}{6} + 6\cdot\tfrac{1}{6}$$ $$E(X) = \frac{1+2+3+4+5+6}{6}$$ $$E(X) = \frac{21}{6}$$ $$E(X) = 3.5.$$
Notice the mean is 3.5, a value the die can never actually show. The expected value is an average, not a prediction of any single roll - and that gap is where a lot of first mistakes live.
How Do You Find The Variance And Standard Deviation?
The variance, $\text{Var}(X) = \sigma^2$, measures how far the values spread from the mean. Its definition is the expected squared distance from $\mu$:
$$\sigma^2 = \sum_{x} (x - \mu)^2 , p(x).$$
Expanding the square gives a shortcut that is faster to compute by hand:
$$\sigma^2 = \sum_{x} x^2 , p(x) - \mu^2 = E(X^2) - [E(X)]^2.$$
The standard deviation is $\sigma = \sqrt{\sigma^2}$, which brings the spread back into the same units as the variable itself. A large $\sigma$ means the outcomes swing widely around the mean; a small $\sigma$ means they huddle close to it.
Where Are Discrete Random Variables Used?
"Chance is countable more often than the world admits."
A discrete random variable is the working tool wherever outcomes arrive in whole units:
Insurance and actuarial work. The number of claims a company sees in a year is a discrete count; premiums are priced from its expected value and variance.
Quality control. The number of defective parts in a batch of 100 is binomial, and factories set accept-or-reject rules from its PMF.
Queues and staffing. Calls per minute to a help line, or patients arriving at an emergency room, are modelled as Poisson counts to plan capacity.
Genetics and epidemiology. The number of offspring with a trait, or new infections in a day, are discrete counts driving real decisions.
The flying-bomb study is the honest version of this: R. D. Clarke's 1946 analysis tested the hit-counts against a Poisson model and found the bombs fell at random, not on targets - a life-or-death conclusion drawn entirely from a discrete random variable.
Examples Of Discrete Random Variables
The set runs from writing a basic PMF, through the most common probability-assignment mistake, to expected value, variance, and a decision problem.
Example 1
Write the probability mass function for $X$ = the number shown when rolling one fair six-sided die.
Each face is equally likely, and there are six faces:
$$p(x) = \frac{1}{6}, \quad x \in {1, 2, 3, 4, 5, 6}.$$
Check the two rules. Every probability is $\tfrac{1}{6}$, which lies between 0 and 1. The sum is $6 \times \tfrac{1}{6} = 1$.
Final answer: the PMF is $p(x) = \tfrac{1}{6}$ for each value in ${1, 2, 3, 4, 5, 6}$.
Example 2
Find the probability mass function for $X$ = the number of heads in three fair coin flips.
Wrong attempt. A student reasons that $X$ can be 0, 1, 2, or 3 - four values - so each must have probability $\tfrac{1}{4}$. Take a moment with that. It would mean three heads is exactly as likely as one head, which feels off, and the only way to get zero heads is TTT while there are several ways to get one head.
Where it breaks. The four values are not equally likely, so equal probabilities are the wrong instinct. The equally likely things are the eight ordered outcomes, from HHH to TTT.
Correct. List the eight outcomes and count heads in each:
$$0 \text{ heads}: \text{TTT} \quad (1 \text{ way})$$ $$1 \text{ head}: \text{HTT, THT, TTH} \quad (3 \text{ ways})$$ $$2 \text{ heads}: \text{HHT, HTH, THH} \quad (3 \text{ ways})$$ $$3 \text{ heads}: \text{HHH} \quad (1 \text{ way})$$
Divide each count by 8:
$$p(0) = \tfrac{1}{8}, \quad p(1) = \tfrac{3}{8}, \quad p(2) = \tfrac{3}{8}, \quad p(3) = \tfrac{1}{8}.$$
Final answer: the PMF is $\left{\tfrac{1}{8}, \tfrac{3}{8}, \tfrac{3}{8}, \tfrac{1}{8}\right}$ for $X = 0, 1, 2, 3$. The probabilities still sum to 1.
Example 3
A discrete random variable has $p(1) = 0.2$, $p(2) = 0.3$, $p(3) = k$, and $p(4) = 0.1$. Find $k$.
The probabilities of all values must total 1:
$$0.2 + 0.3 + k + 0.1 = 1$$ $$0.6 + k = 1$$ $$k = 0.4.$$
Final answer: $k = 0.4$. Each probability is now between 0 and 1, so the PMF is valid.
Example 4
Find the expected value of the variable in Example 3.
Weight each value by its probability and add:
$$E(X) = (1)(0.2) + (2)(0.3) + (3)(0.4) + (4)(0.1)$$ $$E(X) = 0.2 + 0.6 + 1.2 + 0.4$$ $$E(X) = 2.4.$$
Final answer: $E(X) = 2.4$.
Example 5
Find the variance and standard deviation of the variable in Example 3, using $\mu = 2.4$.
First compute $E(X^2)$ by weighting each squared value:
$$E(X^2) = (1)(0.2) + (4)(0.3) + (9)(0.4) + (16)(0.1)$$ $$E(X^2) = 0.2 + 1.2 + 3.6 + 1.6$$ $$E(X^2) = 6.6.$$
Now apply the shortcut $\sigma^2 = E(X^2) - \mu^2$:
$$\sigma^2 = 6.6 - (2.4)^2$$ $$\sigma^2 = 6.6 - 5.76$$ $$\sigma^2 = 0.84.$$
Take the square root for the standard deviation:
$$\sigma = \sqrt{0.84} \approx 0.917.$$
Final answer: variance $= 0.84$, standard deviation $\approx 0.92$.
Example 6
A raffle sells 100 tickets at 2 dollars each. One ticket wins a 120-dollar prize. If you buy one ticket, what is the expected net gain?
Let $X$ be your net gain. Winning nets $120 - 2 = 118$ dollars with probability $\tfrac{1}{100}$; losing nets $-2$ dollars with probability $\tfrac{99}{100}$. Build the expected value:
$$E(X) = (118)\left(\tfrac{1}{100}\right) + (-2)\left(\tfrac{99}{100}\right)$$ $$E(X) = \frac{118}{100} - \frac{198}{100}$$ $$E(X) = \frac{-80}{100}$$ $$E(X) = -0.80.$$
Final answer: the expected net gain is $-0.80$ dollars, an average loss of 80 cents per ticket. No single play returns exactly this, but over many raffles it is what the ticket is worth.
Common Mistakes With Discrete Random Variables
Mistake 1: Assuming every value is equally likely
Where it slips in: Building a PMF by counting how many values the variable can take, then splitting probability evenly among them.
Don't do this: Give the four head-counts in three flips a flat $\tfrac{1}{4}$ each just because there are four of them.
The correct way: Equal probability only holds when the underlying outcomes are equally likely. The reliable habit is to list the equally likely outcomes first, then group them by the value of $X$. The learner who reaches for the flat split almost always does it under time pressure, and re-listing the sample space is the fix that catches it every time.
Mistake 2: Expecting the expected value to be an attainable outcome
Where it slips in: Reading $E(X) = 3.5$ for a die and marking it wrong because a die cannot show 3.5.
Don't do this: Treat the expected value as a prediction of one trial.
The correct way: The expected value is a long-run average across many trials, so it need not be a value the variable can actually take. A balance point can sit between the weights; that is exactly what 3.5 is for the die.
Mistake 3: Confusing discrete with continuous
Where it slips in: Choosing a PMF for something that is really measured on a continuous scale, or vice versa.
Don't do this: Model an exact waiting time in seconds, which can be any value in an interval, as if it were a countable list.
The correct way: Ask whether the values can be listed with gaps between them (discrete) or fill an unbroken range (continuous). Counts are discrete; measurements like length, weight, and time are continuous.
Conclusion
A discrete random variable assigns a number to each outcome of a random experiment, and its possible values are countable with gaps between them.
Its probability mass function lists every value with its probability, and those probabilities must lie between 0 and 1 and sum to 1.
The expected value $E(X) = \sum x,p(x)$ is the long-run average and need not be an attainable value.
The variance $\sigma^2 = E(X^2) - \mu^2$ measures spread, and its square root is the standard deviation.
The common families are Bernoulli, binomial, geometric, and Poisson.
To work through probability distributions with a teacher, explore Bhanzu's high school math tutor sessions or structured math classes online.
Want a live trainer to walk your child through PMFs, expected value, and variance? Book a free demo class.
Read More
Was this article helpful?
Your feedback helps us write better content
