IB Applications and Interpretation SL · Discrete random variables and the binomial distribution · Section 2 of 3

Expected value, variance and standard deviation of a discrete variable

3 worked examples · By Álvaro López

Key idea

The expected value is the mean value you expect to obtain from a random variable if you repeat the experiment many times. The variance and the standard deviation measure how far the results lie from that mean. With them you can decide whether a game is worthwhile, calculate the average profit of a business or compare the risk of two options. In the IB exam they are almost always asked from a table of probabilities, and the GDC calculates them in seconds.

Expected value: the long-run mean

A discrete random variable takes the values with probabilities that add up to 1. If you repeat the experiment many times, each value appears with a relative frequency close to its probability. That is why the mean of the results gets closer and closer to a weighted mean of the values, where the weights are the probabilities.

A familiar example: if is the number that comes up when a balanced die is rolled, . The expected value does not have to be a possible value of the variable: a 3.5 will never come up, but it is the long-run average.

Variance and standard deviation

The expected value says where the centre is, but not whether the results cluster around it or spread widely. For that, the average squared distance from is measured.

There is a way of calculating the variance that usually saves work, because it avoids subtracting in each term:

Linear transformations

Often the variable that matters is obtained from another one with a rule of the form : the total cost is a fixed charge plus a price per unit, or the net gain is the prize minus the cost of taking part.

Games and expected gain

To decide whether a game of chance is worthwhile, define the variable = the player's net gain (what they receive minus what they pay) and calculate .

With the GDC

Worked examples

Example 1 Basic

Calls to the technical service

An academy receives each afternoon a number of calls from interested families. The probability distribution of is:

0 1 2 3

a) Calculate the expected number of calls per afternoon.

b) Calculate the variance of .

c) Calculate the standard deviation of , to 3 significant figures.

Solution

The probabilities add up to , so the table is valid.

a) Expected value: On average 1.6 calls are received per afternoon.

b) First : And now:

c) calls.

Example 2 Medium

Breakdowns of a packaging machine

The number of breakdowns suffered by a packaging machine in one week has this distribution:

0 1 2 3
0.1 0.3

Each week there is a fixed maintenance cost of 30 euros, and each breakdown also costs 50 euros in repairs. Let be the total weekly cost.

a) Find the value of .

b) Calculate .

c) Calculate the expected weekly cost, .

d) Calculate the standard deviation of the weekly cost.

Solution

a) The probabilities must add up to 1: The distribution is: , , , .

b)

c) The cost is , a linear transformation of :

d) First the variance of : As , the standard deviation is (The fixed cost of 30 euros does not affect the spread.)

Example 3 Hard

A game of balls at a fair

At a fairground stall there is a bag with 10 balls: 1 gold, 3 red and 6 blue. To play, you pay an amount in euros, a ball is drawn at random and a prize is received: 20 euros if it is gold, 4 euros if it is red and nothing if it is blue. Let be the player's net gain (prize minus the amount paid).

a) If the price is euros, write the distribution of and calculate . Who does the game favour?

b) Find the price that makes the game fair.

c) Calculate the standard deviation of when the game is fair, to 3 significant figures.

d) The owner of the stall wants to make, on average, 1 euro per player. What price should they set?

Solution

a) With , the net gains are , and :

17 1
0.1 0.3 0.6

The probabilities add up to 1. Then: As , the game favours the player: on average they win 0.20 euros per game.

b) Let be the prize. Its expected value does not depend on : As , we have . The game is fair when , that is, euros.

c) Subtracting the constant does not change the variance, so : This is a large deviation compared with the mean: in a single game the result can be far from 0.

d) The owner's gain is . They want their expected gain to be 1: , so euros.

In the exam: in a games problem, marks are given for defining the net gain (subtracting what is paid), writing the table with probabilities that add up to 1, setting up with the numbers substituted, and interpreting the sign in a sentence ("the game favours the player / the organiser"). Do not forget the units, and if the GDC gives and , use .

Common mistakes

Summary

  • Expected value: . It is the long-run mean and may not be a possible value of .
  • Variance: , with . Standard deviation: .
  • Linear transformation: and .
  • Fair game: , with the net gain. If it favours the player, and if , the organiser.
  • With the GDC: values in one list, probabilities as frequencies; the mean is and the correct deviation is the population one, .
Maths classes in Aldaia and online

Want to work on it together?

Free first consultation: we look at your level and your exam, and build a plan. Álvaro replies on WhatsApp.

Message us on WhatsApp