James Ashton MathsFREE MATHEMATICS. OPEN TO EVERYONE.
HomeIB DiplomaA levelAbout

Binomial distribution

When to use the binomial distribution, finding binomial probabilities on your calculator, and its mean and variance.

Stats 4.1Year 1≈ 45 min to work through
Before you start: discrete random variables and nCr. See Discrete random variables and Binomial theorem.

1What you need to know

Tick these off as you go. By the end of the page you should be able to do all of them without notes.

  • Know the conditions for a binomial distributionY1
  • Use the notation X~B(n,p)Y1
  • Find P(X=r), P(X≤r) and P(X≥r) with your calculatorY1
  • Use E(X)=np and Var(X)=np(1−p)Y1
  • Solve problems such as finding the number of trials neededY1

2Notes & worked examples

Each idea is followed by a worked example. Try the question yourself first, then reveal the solution one step at a time.

2.1 What the binomial distribution models

The big idea

You do the same thing n times. Each time it either works or it does not, and the chance of it working is always p. The binomial distribution tells you how likely each possible number of successes is.

Situations like this come up everywhere: the number of heads in 10 coin flips, the number of faulty phones in a box of 20, the number of questions a student gets right by guessing on a multiple-choice test. In each case a random variable X counts the successes, so it can take the values 0,1,2,…,n.

"Success" just means the outcome you are counting. It does not have to be a good thing: if you are counting seeds that fail to grow, a seed failing is a "success".

We write X~B(n,p), read as "X follows a binomial distribution with n trials and probability of success p". The model only works when all four of these are true:

  • A fixed number of trials, n. You know in advance how many times you will do it.
  • Two outcomes per trial: success or failure.
  • The same probability of success, p, on every trial.
  • Independent trials: one result does not affect the next.

Is each of these binomial?

  • The number of sixes in 20 rolls of a fair die. Yes: X~B(20,16).
  • The number of rolls until the first six. No: the number of trials is not fixed.
  • The number of red cards when 3 cards are taken, without replacement, from 10 cards of which 4 are red. No: the probability of red changes after each card is taken.
  • The number of left-handed students in a class of 25, if 10% of people are left-handed. Yes, as a model: X~B(25, 0.1), assuming students are independent of each other.

2.2 Where the formula comes from

A basketball player scores a free throw with probability 0.7. She takes 3 shots. What is the probability she scores exactly 2?

Write S for a score and F for a miss. There are three ways to get exactly 2 scores: SSF, SFS and FSS. Because the shots are independent, each of these has probability 0.7×0.7×0.3=0.147. So

P(X=2)=3×0.147=0.441

The same thinking works in general. Any one particular order with r successes and n−r failures has probability pr(1−p)n−r. The number of different orders is the number of ways of choosing which r of the n trials are the successes, which is nCr.

Binomial probability
X~B(n,p):P(X=r)=nCrpr(1−p)n−r,r=0,1,…,n
Link: why is it called "binomial"?

The probabilities P(X=0),P(X=1),…,P(X=n) are exactly the terms of the binomial expansion of [(1−p)+p]n. That is where the name comes from. Since (1−p)+p=1, the expansion equals 1n=1, so the probabilities add up to 1, as they must. See Binomial theorem.

Worked example 1 (faded)No calculator
X~B(4, 0.5). Find P(X=2) without a calculator.
4C2(0.5)2(0.5)2=6× 1/16  ← you work this out
= 3/8  ← you work this out

2.3 Single values and cumulative probabilities

P(X=r) is the probability of exactly r successes: one bar on the bar chart in the Explore it section. Many questions ask about several values at once, such as "at most 3" or "at least 5". You then add up several bars. This is called a cumulative probability.

The words matter. Since X only takes whole-number values, "fewer than 3" means 0, 1 or 2:

In wordsIn symbolsOn the calculator
exactly 3X=3Binomial Pdf
at most 3, no more than 3X≤3Binomial Cdf from 0 to 3
fewer than 3, less than 3X≤2Binomial Cdf from 0 to 2
at least 3, 3 or moreX≥3Binomial Cdf from 3 to n
more than 3X≥4Binomial Cdf from 4 to n

For "at least" questions, it is often quicker to use the complement: everything that is not included. For example P(X≥3)=1−P(X≤2), because the values 0, 1, 2 are the only ones left out.

On your Casio ClassWiz Calculator tricks →

Open the Distribution app. Binomial PD gives P(X=r); Binomial CD gives P(X≤r). For P(X≥r), use 1−P(X≤r−1). Enter N (the number of trials) and p. The Edexcel formulae booklet also has cumulative binomial tables.

Worked example 2Calculator
X~B(10, 0.3). Find (a) P(X=4) (b) P(X≤2) (c) P(X≥3).
(a) Binomial Pdf with n=10, p=0.3, x=4: 0.200
(b) Binomial Cdf from 0 to 2: 0.383
(c) P(X≥3)=1−P(X≤2)=1−0.383=0.617
Or Binomial Cdf from 3 to 10.

2.4 Mean and variance

If you flip a fair coin 10 times, you expect about 5 heads. If a seed fails with probability 0.15 and you plant 20, you expect about 20×0.15=3 to fail. In general, the expected number of successes is np.

The expected value does not have to be a whole number. If X~B(50, 0.25), then E(X)=12.5. You will never get 12.5 successes, but over many repetitions the average number of successes will be close to 12.5.

Mean and variance
E(X)=npVar(X)=np(1−p)

The variance measures how spread out the results are. The standard deviation is np(1−p). For a fixed n, the spread is largest when p=0.5, because then the outcome is hardest to predict. When p is close to 0 or 1, almost every trial goes the same way, so the results are tightly bunched. Try this in the Explore it section.

Why does this work?

Think of one trial on its own. It gives 1 success with probability p and 0 with probability 1−p, so its mean is 1×p+0×(1−p)=p. Its variance works out to be p(1−p). A binomial variable is the total of n of these independent trials, and for independent trials both the means and the variances add up. That gives np and np(1−p).

Worked example 3No calculator
X~B(20, 0.15). Find E(X) and the standard deviation of X.
E(X)=20×0.15=3
Var(X)=20×0.15×0.85=2.55
Standard deviation =2.55=1.60
Give 3 significant figures.

2.5 At least one

"At least one" questions are very common. The quick way is the complement: the opposite of "at least one success" is "no successes at all".

P(X≥1)=1−P(X=0)=1−(1−p)n

This also lets you work backwards and find how many trials are needed. You get an inequality with n in the power. Solve it with logarithms or a table of values on the calculator, then round up, because n must be a whole number and the condition must be met.

Worked example 4Calculator
A light bulb fails with probability 0.2. How many bulbs are needed so that the probability that at least one fails is more than 0.95?
P(at least one)=1−0.8n>0.95
0.8n<0.05⇒n>ln0.05ln0.8=13.4
n=14
Round up, and check: 1−0.813=0.945, 1−0.814=0.956.

The inequality sign flips when dividing by ln0.8, because ln0.8 is negative. Checking the two whole numbers either side, as above, avoids this trap.

3Explore it

Change n and p. Choose whether to shade P(X=r), P(X≤r) or P(X≥r).

4Common mistakes & exam tips

Common mistakes

  • Using Binomial Pdf when the question needs a cumulative probability ("at most", "fewer than").
  • Treating "fewer than 3" as X≤3: it is X≤2.
  • Calculating P(X≥3) as 1−P(X≤3): it is 1−P(X≤2).
  • Using a binomial model when trials are not independent (e.g. without replacement from a small group).

Exam tips

  • Write the distribution and the probability statement, e.g. X~B(20,0.15), P(X≥5)=0.170.
  • Translate the words: "at most 3" X≤3; "more than 3" X≥4; "at least 3" X≥3.
  • The standard deviation is np(1−p).

5Practice

Fluency questions build the basics. Problem-solving questions make you think about which method to use.

FluencyP1
X~B(8, 0.25). Find P(X=2).
0.311
FluencyP2
X~B(8, 0.25). Find P(X≥1).
1−0.758=0.900
FluencyP3
X~B(8, 0.25). Find P(X≤3).
0.886
FluencyP4
Find E(X) for X~B(50, 0.2).
10
Problem solvingP5
A fair die is rolled 12 times. Find the probability of exactly two sixes, and of at least two sixes.
X~B(12,16): P(X=2)=0.296; P(X≥2)=0.619.
Problem solvingP6
Each item is faulty with probability 0.2. Find the smallest sample size for which the probability of at least one faulty item exceeds 0.95.
1−0.8n>0.95⇒n=14

6Exam-style questions

Original exam-style questions with full markschemes. Edexcel papers allow a calculator throughout, but questions labelled “No calculator” practise exact working. Allow about 1.2 minutes per mark.

Question 1Calculator[8 marks]

15% of seeds of a certain type fail to grow. 20 seeds are planted. Let X be the number that fail.

  • (a)Write down the distribution of X.[1]
  • (b)Find P(X=3).[2]
  • (c)Find the probability that at most 2 seeds fail.[2]
  • (d)Find the probability that at least 5 seeds fail.[2]
  • (e)Find the expected number of seeds that fail.[1]
(a)
X~B(20, 0.15)A1
(b)
Binomial PdfM1
0.243A1
(c)
P(X≤2)M1
0.405A1
(d)
1−P(X≤4)M1
0.170A1
(e)
3A1
Question 2Calculator[4 marks]

A fair die is rolled n times. Find the least value of n for which the probability of at least one six is greater than 0.9.

1−(56)n>0.9M1 A1
n>12.6A1
n=13A1
Question 3No calculator[4 marks]

X~B(4, 0.5).

  • (a)Find P(X=2).[2]
  • (b)Write down E(X).[1]
  • (c)Find Var(X).[1]
(a)
4C2(0.5)4M1
38A1
(b)
2A1
(c)
1A1

7Check yourself

Six quick questions, marked instantly. Aim for 6/6 before moving on. Fractions like 3/2 are accepted.

8Past-paper practice

Once you're scoring well above, try real Edexcel A level questions. Past papers and markschemes are on the Pearson website.

PaperQuestionFocusDifficulty
June 2023 · Paper 31Q2Binomial model for prizes in packets, then a hypothesis test★☆☆
June 2018 · Paper 3Q3Assumptions and probabilities for B(10, 0.1)★★☆
June 2022 · Paper 31Q3Days without rain: a binomial model and its limits★★☆
Spotted a mistake on this page?Tell me and I'll fix it. The button opens an email with this page already named, or write to jamesashtonmaths@gmail.com.
Report a mistake