Discrete random variables and the binomial distribution AA SL
A discrete random variable lists the values an outcome can take and the probability of each, and the binomial distribution is the special case that counts successes in a fixed number of independent trials. This page shows how to complete a probability table, find an expected value and decide whether a game is fair, then how to recognise a binomial situation, find its probabilities with the calculator and use its mean and variance, with worked examples and exam-style questions.
Formulas at a glance
The expected value formula, and the mean and variance of a binomial distribution, are in the formula booklet. The rule that the probabilities add up to 1 and the four conditions for a binomial model are not, so learn them. Binomial probabilities are found with the calculator, so there is no probability formula to memorise.
Expected value of a discrete random variable
In the bookletBinomial distribution and its mean
,
In the bookletWhich method to use
Decide first whether you have a probability table or a binomial situation, then choose the calculation from what the question asks for.
| The question asks for | Use | Notes |
|---|---|---|
| An unknown probability in a table | The probabilities add up to 1 | Write the equation, solve it, then check that every probability is between 0 and 1 |
| The expected value of a discrete variable | Multiply each value by its own probability, then add. The result need not be a value that can take | |
| Whether a game is fair | Check whether , where is the gain of the player | Put the cost of playing inside the values of , as a negative gain |
| Whether a situation is binomial | A fixed number of trials, two outcomes, constant probability, independent trials | All four must hold. Then write and say what counts as a success |
| Binomial probability (exactly ) on the calculator | Enter the number of trials, then the probability, then | |
| or | Binomial cumulative probability, with or | The cumulative function includes the value you enter, so |
| or | or | "At least one" is . The most common slip is using instead of |
| Subtract the cumulative probability just below | ||
| The mean and variance of a binomial variable | and | Both are in the formula booklet. The standard deviation is the square root of the variance |
| An unknown or given the mean and variance | Divide the variance by the mean to get , then find from | Check that is a whole number and is between 0 and 1 |
Section 1 of 2 SL4.7
Discrete random variables and expected value
A discrete random variable takes separate values, each with a probability, and the probabilities in its distribution add up to . The expected value is the long-run mean, found by multiplying each value by its probability and adding the results. Use the table to find missing probabilities and to decide whether a game is fair.
The key formula
Valid distributions
Every entry in a probability table must lie between 0 and 1, and the whole row must sum to exactly 1 - this is often how you find an unknown .
Key terms
What is a random variable?
A random variable is a quantity whose value depends on the outcome of a random process, written with a capital letter such as . A particular value it can take is written with a lower case letter such as .
e.g. If is the score on one roll of a fair die, then can take the values to and .
What is a probability distribution?
A probability distribution lists every value that can take with its probability , usually in a table. The probabilities must add up to .
e.g. If , and , then , so .
What does expected value represent?
The expected value is the mean of the distribution: the average result over a very large number of repeats. It need not be a value that can actually take.
e.g. For and , , even though is never .
What is a fair game?
A game is fair if the expected gain for the player is . A positive value favours the player and a negative value favours the organiser.
e.g. Winning dollars with probability or losing dollar with probability gives , so the game is fair.
Worked example, step by step
The question No calculator needed [5 marks]
A game is played once. The random variable is the gain, in dollars, of a player, and its probability distribution is given in the table.
(a) Find the value of .
(b) Find .
(c) Determine whether the game is fair. Give a reason for your answer.
Worked solution: worked example
Answer: (a) . (b) . (c) The game is not fair, because ; the player loses per game on average.
Step 1 - Use the fact that the probabilities add up to 1.
The table lists every value that can take, so This simplifies to . M1 - Sum of the probabilities equal to :
Why? Every probability distribution has total probability 1. That is the only piece of information that links the unknown to the numbers in the table, so it is always the first equation to write.
Step 2 - Solve for k and find every probability.
, so . Then and . The probabilities are . A1 -
Why? Substitute back into the table. Each probability should lie between 0 and 1 and the four should add to 1, which is a quick check that is right.
Step 3 - Write the expected value sum.
Multiply each value of by its own probability: M1 - Use with the values and probabilities
Why? The expected value is a weighted mean, so each outcome is weighted by how likely it is. Keep the negative gain inside the sum with its sign, rather than adding it on at the end.
Step 4 - Evaluate.
A1 -
Why? Take care with the signs when adding. The negative term outweighs the positive terms, so the total is negative, and a slip here would change the conclusion in part (c).
Step 5 - Interpret the answer.
A game is fair when . Here , which is not , so the game is not fair. On average the player loses per game, so the game favours the organiser. R1 - , so the game is not fair
Why? Say both the comparison with and what it means in context. A negative expected gain means that, over many plays, the player loses money on average.
M1 Sum of the probabilities equal to :
A1
M1 Use with the values and probabilities
A1
R1 , so the game is not fair
Now you try: enter your answers to be marked
These are real practice questions. Type your answer in each box and press Mark it. The worked solution and mark scheme appear straight away, and your first attempt is the one that counts. Use the keyboard for powers, roots and trig, and the working box for your notes.
| 1 | 2 | 3 | |
| 0.2 | 0.5 |
Worked solution: practice question 1
| 1 | 2 | 3 | 4 | |
Worked solution: practice question 2
Find the expected profit per game.
Worked solution: practice question 3
Your score so far: 0 out of 11 marks
Common mistakes
- Forgetting the probabilities must sum to 1. If a table has an unknown , the very first step is almost always - skipping this leaves unfound and every later part wrong.
- Averaging the outcomes instead of weighting them. is not the plain mean of the -values - each outcome must be multiplied by its own probability before adding.
- Missing negative payoffs in a game context. When a question involves a cost as well as a prize, the cost is a negative value of , not something to subtract at the end - it belongs inside the sum.
Section 2 of 2 SL4.8
The binomial distribution
The binomial distribution models the number of successes in independent trials, each with the same probability of success. Its mean is and its variance is , and its probabilities are found using technology. Check that the situation fits before writing .
Setup and formula
In examinations, binomial probabilities should be found using technology.
Key terms
What do and stand for in ?
is the fixed number of trials and is the probability of success on each trial. The variable counts the number of successes.
e.g. Guessing questions with a chance of success on each gives .
What counts as a success?
A success is the outcome you are counting, even if it is not good news, and a failure is everything else, with probability .
e.g. If a component is defective with probability and defects are being counted, a defective component is a success, and a working one is a failure with probability .
How do you find the mean and variance of a binomial variable?
Use and . The standard deviation is the square root of the variance.
e.g. For , and .
How do you write 'at least' and 'at most' probabilities?
'At most ' is , 'fewer than ' is , and 'at least ' is .
e.g. For , 'at least ' is .
Worked example, step by step
The question Calculator needed (binomial probability) [6 marks]
A factory makes light bulbs. Each bulb is faulty with probability , independently of the other bulbs. A box contains bulbs. Let be the number of faulty bulbs in the box.
(a) Write down the distribution of , and state one assumption that is needed for this model.
(b) Find the probability that the box contains at least faulty bulbs.
(c) Find the mean and the variance of .
Worked solution: worked example
Answer: (a) , with the bulbs independent and the probability of a fault constant. (b) . (c) Mean , variance .
Step 1 - Identify the distribution.
There is a fixed number of trials, bulbs, each either faulty or not faulty, with the same probability of being faulty. Counting faulty bulbs gives A1 -
Why? A faulty bulb is a success because it is the outcome being counted, even though it is bad news. The two parameters are the number of trials and the probability of success .
Step 2 - State the assumption.
The bulbs are independent of each other and the probability is the same for every bulb. The question tells you this, so the model is valid. R1 - Independent trials with constant probability of a fault
Why? The binomial model needs independent trials with a constant probability of success. In a context question, say what the assumption means for the situation, not just its name.
Step 3 - Rewrite the probability in terms of a cumulative probability.
The calculator gives the probability of at most a value, so use the complement: M1 - Use the complement:
Why? "At least " covers . It is quicker to subtract the cases that are not allowed, which are , from . The value you enter in the cumulative function is , not .
Step 4 - Use the calculator.
Use the binomial cumulative probability function with , and : So A1 -
Why? Enter the number of trials first, then the probability, then the value. Keep the unrounded value of on the calculator and round only your final answer.
Step 5 - Find the mean and variance.
and . A1 - Mean A1 - Variance
Why? Both formulas are in the formula booklet. The variance has the factor because it measures the spread caused by the chance of a success or a failure on each trial.
A1
R1 Independent trials with constant probability of a fault
M1 Use the complement:
A1
A1 Mean
A1 Variance
Now you try: enter your answers to be marked
Find
Worked solution: practice question 1
Worked solution: practice question 2
Worked solution: practice question 3
Your score so far: 0 out of 11 marks
Calculator steps: Binomial distribution
Common mistakes
- Not checking the four binomial conditions. A situation is only binomial if trials are fixed in number, independent, and have a constant probability of success - sampling without replacement from a small population breaks this.
- Using binompdf when a range is needed. or call for the cumulative function binomcdf (with a complement where needed), not binompdf, which only gives one exact value.
- Confusing and in the GDC entry. The number of trials always goes first and the probability second - swapping them silently produces a completely different (and wrong) distribution.
Using your GDC
The exact key presses for the TI-84 Plus CE, Casio fx-CG50, Casio fx-CG100 and TI-Nspire CX, with what the screen shows. Pick your calculator.
Binomial distribution
Used in: The binomial distribution
How to find a binomial probability on a TI-84 Plus CE
binompdf and binomcdf | |
For exactly 8 (), press 2nd vars (DISTR) and choose A:binompdf(. With the Stat Wizards on, a screen asks for each value in turn: type it and press enter each time. Enter the number of trials 20, the probability of success 0.4 and the value of x, 8, then press enter on Paste. |
binompdf( trials:20 p:0.4 x value:8 |
Press enter to run it. If the Stat Wizards are off, type to 3 significant figures. |
binompdf(20,0.4,8) 0.1797058 |
For at most 8 (), press 2nd vars (DISTR) and choose B:binomcdf(. It adds the probabilities from 0 up to x. to 3 significant figures. |
binomcdf(20,0.4,8) 0.5955987 |
For at least 10 (), the calculator only adds up from 0, so find and subtract it from 1: type to 3 significant figures. |
1-binomcdf(20,0.4,9) 0.2446628 |
"At least 10" is 1 minus the cumulative probability up to 9, not up to 10. For "fewer than 10" use binomcdf at 9.
The full guide: Binomial distribution
See the full list of GDC guides for every calculator task.
Syllabus content covered
| Code | Syllabus content |
|---|---|
| SL4.7 | Concept of discrete random variables and their probability distributions. Expected value (mean) for discrete data. Applications. indicates a fair game where represents the gain of a player. |
| SL4.8 | Binomial distribution. Mean and variance of the binomial distribution. In examinations, binomial probabilities should be found using available technology. |
Official IB source: Mathematics: analysis and approaches subject brief (PDF, ibo.org).
Quick questions
How do you find the expected value of a discrete random variable?
Multiply each possible value by its probability , then add the results: .
What are the conditions for a binomial distribution?
A fixed number of trials , exactly two outcomes per trial, a constant probability of success , and independent trials. All four must hold before you can write .
How do you know a probability distribution table is valid?
All the probabilities must lie between 0 and 1, and the whole set of probabilities in the table must add up to exactly 1.
How do you calculate binomial probabilities on the GDC?
Use for an exact value , or for a cumulative probability . IB exams expect these to be found using technology.
How do I find a missing probability in a table?
Add the known probabilities and subtract the total from . If the known probabilities are , and , the missing one is .
Why is 'at least one' easier to find using the complement?
'At least one' is every outcome except none, so . This avoids adding many separate probabilities.
Can the expected value be negative?
Yes. A negative means the average result is a loss. If takes with probability and with probability , then .
Why is drawing cards without replacement not binomial?
Each draw changes the probability of success for the next draw, so the probability is not constant and the trials are not independent. Both conditions for a binomial model fail.
What is the difference between the expected value and the plain average of the values?
The plain average treats every value equally, but weights each value by its probability. For and with probabilities and , the plain average is but .
What values can X take in a binomial distribution?
can take the whole numbers from to . For , the possible values are .
Ready to practise properly?
Practice questions on every section, marked instantly like the real exam.