WhatsApp us
IB DP Maths29 Nov 2026

IB Maths Discrete Random Variables and Expected Value: Tables, Unknowns and Fair Games (AA)

A discrete random variable lists outcomes with probabilities that add to 1, and E(X) is the probability-weighted average. Four original worked examples (finding k, two unknowns from E(X), a fair game, building a table from an experiment), the HL variance extension, common slips and a self-check.

IB Maths Discrete Random Variables and Expected Value: Tables, Unknowns and Fair Games (AA)

A discrete random variable X takes separate values, such as 0, 1, 2 or 3, each with a probability. Two facts drive almost every question: the probabilities must add up to 1, and the expected value is E(X) = Σ x P(X = x), the long-run average if the experiment were repeated many times. With those two equations you can find unknown probabilities, decide whether a game is fair, and check your own working.

This is one of the shorter parts of the AA statistics and probability topic, which the IB guide gives 27 hours at SL and 33 at HL. It is also one of the friendliest places to bank marks on Paper 1, because the arithmetic is usually fractions or one-decimal probabilities, and the same ideas reappear on Paper 2 with a calculator. If probability questions still feel like guesswork, a tutor for IB Maths AA SL can give the topic structure quickly.

The two rules, and one check

For any discrete probability distribution:

  1. Each probability is between 0 and 1, and Σ P(X = x) = 1.
  2. E(X) = Σ x P(X = x). Multiply each value by its probability and add.

The check: E(X) must lie between the smallest and largest values of X. If X takes values 1 to 4 and you get E(X) = 5.2, something has gone wrong.

E(X) does not have to be a value X can take. A fair die has E(X) = 3.5, which no single roll can show.

Worked example 1: find k, then E(X)

The random variable X has P(X = x) = kx for x = 1, 2, 3, 4.

(a) Find k.

The probabilities are k, 2k, 3k and 4k. They add to 1, so 10k = 1 and k = 1/10.

(b) Find P(X ≥ 3).

P(X = 3) + P(X = 4) = 3/10 + 4/10 = 7/10.

(c) Find E(X).

E(X) = 1(1/10) + 2(2/10) + 3(3/10) + 4(4/10) = (1 + 4 + 9 + 16)/10 = 3.

Writing the table out in full, even when the formula is given, prevents the common slip of including an x value the question excludes.

Worked example 2: two unknowns from E(X)

The table shows the distribution of X, and E(X) = 1.6.

x0123
P(X = x)0.1ab0.2

Sum rule: 0.1 + a + b + 0.2 = 1, so a + b = 0.7.

Expected value: 0(0.1) + 1(a) + 2(b) + 3(0.2) = 1.6, so a + 2b = 1.

Subtract the first equation from the second: b = 0.3, so a = 0.4.

a = 0.4 and b = 0.3. Both are between 0 and 1, which is a check worth writing down.

This type is popular because it joins probability to simultaneous equations. Two unknowns need two equations, and the question always gives you exactly enough information for the second one.

Worked example 3: is the game fair?

A player rolls a fair six-sided die. A 6 wins 10 tokens, a 4 or a 5 wins 3 tokens, and anything else wins nothing. It costs c tokens to play.

(a) Find the expected winnings per game, before paying.

Let W be the number of tokens won.

w1030
P(W = w)1/62/63/6

E(W) = 10(1/6) + 3(2/6) + 0 = 16/6 = 8/3 tokens.

(b) Find c for the game to be fair.

A game is fair when the expected gain is zero. The gain is W − c, so E(W) − c = 0 and c = 8/3 tokens (about 2.67).

(c) The game actually costs 3 tokens. Find the expected gain over 30 games.

Expected gain per game = 8/3 − 3 = −1/3. Over 30 games: 30 × (−1/3) = −10 tokens. The player expects to lose 10 tokens.

The trap in fair-game questions is the cost. Decide whether the prize includes the returned stake or not, and define your variable as the gain if the question talks about profit. Setting out a table with the net amounts avoids the confusion.

Worked example 4: building the distribution yourself

A bag holds 3 red and 2 blue counters. Two are taken out without replacement. Let X be the number of red counters taken.

Here nobody gives you a table; you build it with a tree or by listing.

  • P(X = 0) = P(blue, blue) = (2/5)(1/4) = 1/10
  • P(X = 2) = P(red, red) = (3/5)(2/4) = 3/10
  • P(X = 1) = 1 − 1/10 − 3/10 = 6/10. As a check: P(red, blue) + P(blue, red) = (3/5)(2/4) + (2/5)(3/4) = 6/20 + 6/20 = 6/10.
x012
P(X = x)1/106/103/10

E(X) = 0 + 6/10 + 6/10 = 6/5 = 1.2.

A sense check: 3/5 of the counters are red and you take 2, so on average 2 × 3/5 = 1.2 red counters. The answers agree. The without-replacement branches are the same skill as in our sibling guide to conditional probability, Venn and tree diagrams.

The HL extension: variance

AA HL students also find the variance of a discrete random variable:

Var(X) = E(X²) − [E(X)]², where E(X²) = Σ x² P(X = x).

For worked example 4: E(X²) = 0 + 1(6/10) + 4(3/10) = 18/10 = 1.8, so Var(X) = 1.8 − 1.2² = 0.36, and the standard deviation is 0.6.

The common error is squaring the probabilities instead of the values. Only x is squared. HL also uses E(aX + b) = aE(X) + b and Var(aX + b) = a²Var(X); our HL guide to Bayes' theorem and continuous random variables works through those rules.

A table or a named distribution?

SituationModelE(X)
Probabilities given in a table or by a formula such as kxGeneral discrete distributionΣ x P(X = x)
Fixed number of independent trials, same success probabilityBinomial B(n, p)np
A continuous measurement, symmetric about a meanNormal (not discrete)μ

If the situation is binomial, E(X) = np is far quicker than building a table. Our overview of binomial, normal and other IB distributions helps you recognise each one, and the sibling post on normal distribution questions and the inverse normal covers the continuous case.

Mistakes our tutors see

  1. Probabilities that do not add to 1. Always check the sum before using a table.
  2. Accepting a negative probability when solving for k or a. Reject it, or recheck your algebra.
  3. Forgetting the cost in a fair-game question, or subtracting it twice.
  4. Squaring the probabilities instead of the values when finding E(X²).
  5. Treating "without replacement" as independent, so the second branch keeps the old denominator.
  6. Rounding decimals early in a long Paper 2 question.

Exam technique

  • Draw the table with x on the top row, even when the question does not ask for it.
  • Show the equation for Σ P = 1 as a line of working. It is often worth a method mark on its own.
  • Use fractions on Paper 1. Keep thirds and sixths exact until the last line.
  • Interpret E(X) in context when asked: "on average, the player loses one third of a token per game".
  • For mixed practice across the probability unit, use our guide to building a topic-by-topic question bank.

Self-check

  1. A spinner gives 1, 2 or 5 with probabilities 0.5, 0.3 and 0.2. Find E(X).
  2. P(X = x) = c(x² + 1) for x = 0, 1, 2. Find c and E(X).
  3. A game costs 5 tokens. You toss two fair coins and win 12 tokens for two heads, 4 tokens for exactly one head, and nothing otherwise. Is the game fair?
  4. Explain why P(X = x) = (x − 1)/6 for x = 0, 1, 2, 3, 4 cannot be a probability distribution.

Answers.

1: 0.5 + 0.6 + 1.0 = 2.1.

2: c(1 + 2 + 5) = 1, so c = 1/8. E(X) = 0 + 1(2/8) + 2(5/8) = 12/8 = 3/2.

3: E(winnings) = 12(1/4) + 4(1/2) = 3 + 2 = 5 tokens, equal to the cost, so the expected gain is 0 and the game is fair.

4: P(X = 0) = −1/6, which is negative, and the probabilities add to 5/6, not 1. Both rules fail.

How Maths Bodhi helps

Tutors build the habit of writing the table and the two equations before any calculation, then add exam-style twists such as costs and without-replacement draws. For extra help across the probability unit, see our probability tutoring. Students who want the senior tutor can read about Ajay Vatsyayan's Analysis and Approaches SL classes.

Home tuition is available in Gurgaon (Gurugram). Students elsewhere in India and abroad learn with us online. You can book a free demo class.

Written and checked by the Maths Bodhi team. Facts checked against official IB sources, November 2026.

Frequently asked questions

What is a discrete random variable in IB maths?
A variable that takes separate, countable values, each with a probability, where all the probabilities are between 0 and 1 and add up to 1.
How do you calculate expected value in IB maths?
Multiply each value of X by its probability and add the results: E(X) = Σ x P(X = x). For a binomial distribution you can use E(X) = np instead.
What makes a game fair in IB maths?
A game is fair when the expected gain for the player is zero, so the expected winnings equal the cost of playing.
How do I find two unknown probabilities in a table?
Use two equations: the probabilities add to 1, and the given expected value equals Σ x P(X = x). Solve them simultaneously and check that both answers lie between 0 and 1.
Is the variance of a discrete random variable in AA SL?
Expected value is the main focus at SL. The variance of a discrete random variable, Var(X) = E(X²) − [E(X)]², is part of the AA HL content, so HL students should practise it.
IB maths discrete random variablesexpected valuefair gamesIB maths AA SL probabilityIB tutor Gurgaon

Related guides

Keep exploring this maths topic

IB DP Maths18 Oct 2026

IB Maths Probability Distributions: Binomial, Normal and Beyond (SL and HL)

Binomial and normal distributions appear in every IB maths course, and HL adds more. How to recognise which distribution a question needs, how to set out working so you earn the method marks, and the GDC steps and traps to know.

IB maths probabilityIB math probability distributionsbinomial distribution IBnormal distribution IB

By Maths Bodhi Team

Read guide

IB DP Maths29 Nov 2026

IB Maths AA Normal Distribution Questions: Inverse Normal, Unknown Mean and Standard Deviation

The four types of normal distribution question in IB Maths AA, from a straight probability to finding an unknown mean and standard deviation with z-values, each with an original worked example, plus the calculator-free symmetry type and a self-check.

IB maths AA normal distributioninverse normalz-valuesIB maths AA SL statistics

By Maths Bodhi Team

Read guide

IB DP Maths18 Oct 2026

GDC Skills for IB Maths: The Calculator Features That Win Marks in Paper 2

Owning a graphic display calculator is not the same as using it well. The GDC features every IB maths student should master, how to write GDC working so the markscheme rewards it, the settings that cause silent errors, and how to practise.

IB maths GDCIB maths calculator skillsTI-84 IB mathsCasio fx-CG50 IB maths

By Maths Bodhi Team

Read guide

IB DP Maths17 Nov 2026

IB Maths AA SL Probability Questions: Conditional Probability, Independent Events, Venn and Tree Diagrams

AA SL probability questions turn on two ideas, conditional probability and independence, shown through Venn diagrams, tables and tree diagrams. The formulae, four original worked examples including a "without replacement" tree and a test-result question, the traps, and a self-check set.

IB maths AA SL probabilityconditional probability IBindependent eventstree diagrams IB maths

By Maths Bodhi Team

Read guide

IB DP Maths25 Nov 2026

IB Maths Problem-Solving Strategies: 7 Ways to Crack Unfamiliar Questions

Seven problem-solving strategies for the unfamiliar parts of IB maths questions, each with a fully worked AA or AI example: breaking a question into parts, small cases, changing the representation, symmetry, invariants, boundary cases and spotting hidden structure.

IB maths problem solvingunfamiliar IB maths questionsIB maths Paper 3 strategiesIB maths AA HL

By Maths Bodhi Team

Read guide

IB DP Maths25 Nov 2026

IB Maths for Economics, Business, Data Science and Engineering: The Skills Each Degree Uses

Which IB maths topics economics, business, data science and engineering degrees actually build on, shown with worked examples from AA and AI: marginal cost, compound growth, expected value, regression, matrices, conditional probability, kinematics and differential equations. Plus a Year 1 plan and the mistakes families make.

IB maths for economicsIB maths for engineeringIB maths for data scienceis IB maths useful

By Maths Bodhi Team

Read guide