Finding the Mean of a Binomial Distribution | Free Discrete Mathematics Lesson (4 College Credits) | UPI Study

UPI Study › Courses › Discrete Mathematics › Free lessons › Lesson 8.5 Free with a free account

Finding the Mean of a Binomial Distribution

Discrete Mathematics · Chapter 8: Binomial Probability, Recurrence Relations, and Generating FunctionsSection 8.5 · lesson 50 of 87video coming soon

← Using Binomial Probability TablesNext lesson: Measuring Spread in Binomial Distributions →

Earn 4 college credits for Discrete MathematicsRecommended for credit by NCCRS · Math 230 · self-paced · one payment, lifetime access

In this lesson

The np formula, 2 proofs of it, and what it means.

  • Derive the mean np from the definition
  • Interpret the mean as an expected count
  • Explain a mean that isn't a whole number
  • Reprove np with indicator variables

Transcript

Everything said in the video, section by section (1,143 words). Read along, or search it.

Binomial Probability, Recurrence Relations, and Generating Functions

Finding the Mean of a Binomial Distribution

This section finds the mean of a binomial distribution. It comes out as a strikingly simple formula, n times p. We'll prove it twice. Once directly from the definition of expected value, and once with a much shorter argument that makes the connection to chapter six explicit. And we'll be careful about what the number actually means.

The Opening Problem

How Many Reviewers This Hour?

A social media platform's moderation classifier flags each uploaded post for human review. We'll use an illustrative flagging probability of zero point zero three, independently across posts. In a typical hour, about five hundred posts are uploaded. The operations lead doesn't need the probability of any single exact count of flagged posts. She needs to know, on average, how many to expect, so she can schedule reviewers. That average is the mean, or expected value, of the binomial count of flagged posts. How spread out the count is around that mean is the subject of section eight point six.

Recall and Theorem 8.5.1

Expected Value, Applied to a Binomial

Chapter six defined the expected value of a discrete random variable as a probability-weighted average. Each possible value, times its probability, summed. It's often written mu. For a binomial variable, substitute the binomial probabilities. That gives the sum, for k from zero to n, of k times n choose k, times p to the k, times one minus p to the n minus k. The theorem says that whole sum equals n times p. The number of trials, times the success probability. Here's the proof, with no step skipped.

Worked Derivation 8.5.1

Absorb the k Into the Coefficient

First, the k equals zero term contributes nothing, so the sum can start at k equals one. Now simplify k times n choose k. Expand the coefficient, and cancel one factor of k against k factorial, since k over k factorial is one over k minus one factorial. That leaves n factorial, over k minus one factorial times n minus k factorial. Factor a single n out of n factorial. What's left is exactly n minus one choose k minus one. So k times n choose k equals n times n minus one choose k minus one. Substitute that back in, and pull one factor of p out of p to the k. That puts n times p in front of the whole sum.

Worked Derivation 8.5.1

Reindex, and the Sum Is 1

Next, reindex. Let j equal k minus one. As k runs from one to n, j runs from zero to n minus one. And n minus k becomes n minus one, minus j. The remaining sum is n minus one choose j, times p to the j, times one minus p to the n minus one minus j, over every j. That's exactly the total probability of every outcome of a binomial variable with n minus one trials. Total probability is always one. So the expected value is n p times one, which is n p.

Worked Example 8.5.1

15 Flagged Posts an Hour

Back to the moderation queue. With five hundred posts and p of zero point zero three, the mean is five hundred times zero point zero three, which is fifteen. That's a long-run average. Over many hours of five hundred uploads each, the average number of flagged posts settles at fifteen. That's the law of large numbers, from chapter six. It isn't a prediction for any particular hour. Exactly fifteen flagged posts happens only about ten percent of the time. It's the balance point of the whole distribution of hourly counts, and it's the number to staff reviewers against.

Worked Example 8.5.2

A Mean of 3.5 Defective Boards

A subtlety worth making explicit. n p doesn't have to be a whole number, even though every outcome of X is. A quality-control station tests seven circuit boards per batch. Under a stress test, each is independently defective with probability one half. The mean is seven times zero point five, which is three and a half. No single batch can have three and a half defective boards. The possible values are zero through seven. But over a thousand batches, the total number of defective boards will be close to three thousand five hundred. That's an average of three and a half per batch. The mean is an average, not a value X must hit.

Figure 8.5.1

The Mean as a Balance Point

Here's a binomial distribution with twenty trials and p of zero point three. The gold bar marks the mean, n p, which is six. The mean is the distribution's balance point, where the whole probability-weighted distribution would balance. In this case, it also happens to line up with the tallest bar. But that's not guaranteed in general, as the three and a half example shows.

Recall - Linearity of Expectation

A Second Route to np

Chapter six also gave a second tool for expected values. Linearity of expectation. The expected value of a sum of random variables equals the sum of their expected values. And it holds unconditionally, for any random variables on the same sample space, whether they're independent or not. That's what makes it such a powerful shortcut.

Worked Derivation 8.5.2

One Trial at a Time

Here's the second proof. For each trial i, define an indicator variable, X sub i. It's one if trial i succeeds, and zero if it fails. Then the total count X is just the sum of those indicators. Each success adds one, and each failure adds zero. Each indicator's expected value is easy. One times p, plus zero times one minus p. That's just p. Now apply linearity. The expected value of X is the sum of n expected values, each equal to p. That's n p. Notice what made it so short. It never sums over the possible values of X at all, so the binomial coefficient never appears. It works one trial at a time.

2 Routes, 1 Result

What Each Proof Reveals

Both proofs reach n p, but they're not just a long version and a shortcut. They reveal different things. The direct summation needs a coefficient identity, and the fact that total probability is one. It takes more effort, but it shows mechanically where n p comes from, inside the formula itself. The indicator proof only needs to see X as a sum of zero-one variables. It's much less work. And it shows why n p holds even without independence between trials. It also extends readily to trials with different success probabilities.

Takeaways

np, 2 Ways

To summarize. For a binomial random variable, the mean is n times p. It can be proved by direct summation, or by linearity of expectation on indicator variables. It's a long-run average, not a claim about any single run, so it doesn't have to be a whole number. And linearity of expectation holds unconditionally. Independence is never required. Here's something to think about. Suppose someone claims the same freedom for variance. The variance of a sum always equals the sum of the variances. Test a simple case. Let X two be an exact copy of X one, so they're certainly not independent. Does doubling a single random quantity spread its outcomes as much as adding two genuinely separate, independent copies would? What extra condition might section eight point six need, to make its version of that identity true?

About Discrete Mathematics at UPI Study

Discrete Mathematics (Math 230) is a self-paced online course of 87 video lessons in 13 chapters, from logic and proof to counting, probability, graph theory and trees. It carries a NCCRS credit recommendation for 4 semester credits.

Every lesson transcript is free on pages like this one, and the videos are free with a free UPI Study account. Enrolling adds a practice quiz after each lesson, the graded work and final exam that earn the credit, lifetime access, and an official transcript on completion. UPI Study has helped over 130,000 students with college credits. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.

Why take it here

Why students take Discrete Mathematics with UPI Study

The math behind computer scienceDiscrete Mathematics is the mathematics of computer science: logic, proofs, sets, counting, probability and graphs underpin algorithms, data structures, cryptography and databases. Completing it now lets you qualify for those courses at your university.
Credit at a fraction of the priceThe same 4 credits can cost $750 or more at a US college. Here it is one payment, self-paced, with lifetime access.
Finish your degree soonerTransfer credits reduce the courses you still owe, so you can graduate earlier or lighten a heavy semester.
Strengthen an applicationA completed college-level course on an official transcript shows admissions and scholarship committees you can do the work.
Study on your own scheduleNo start dates, no deadlines. Watch the lessons, practice, and take the final when you are ready.
130,000+students helped with college creditsACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.

Where the credit goes

Universities that work with NCCRS

Discrete Mathematics carries a NCCRS credit recommendation. These universities work with NCCRS; some are UPI Study's signed partners. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.

Find my college → Not listed? Ask Athena in the corner of this page, or book a 15-minute call.

FAQ

Questions students ask us

About Finding the Mean of a Binomial Distribution

What is the mean of a binomial distribution, and what does it tell you?
The mean of a binomial distribution with n trials and success probability p is \mu = np, the expected number of successes. It is a long-run average count, not a prediction for any one run. For example, if each of 500 posts is flagged independently with probability 0.03, the mean is 500(0.03)=15 flagged posts per hour on average.
How do you derive np directly from the definition of expected value?
Start with E[X]=\sum_{k=0}^{n} k\binom{n}{k}p^k(1-p)^{n-k}. The k=0 term is zero, and k\binom{n}{k}=n\binom{n-1}{k-1}, so n and one factor of p pull out front. Reindexing with j=k-1 leaves \sum_{j=0}^{n-1}\binom{n-1}{j}p^j(1-p)^{n-1-j}. That is the total probability of a binomial with n-1 trials, which equals 1. So E[X]=np.
Why can the mean of a binomial distribution be a non-whole number like 3.5?
The mean can be a non-whole number because it is an average over many repetitions, not a value X must take. With n=7 boards, each defective with probability 0.5, the mean is np=3.5, yet any single batch has between 0 and 7 defective boards. Over 1000 batches, the total number of defective boards would be close to 3500, or 3.5 per batch.
How do you prove E[X]=np using indicator variables?
Define X_i=1 if trial i succeeds and X_i=0 otherwise, so X=X_1+\cdots+X_n. Each indicator has E[X_i]=1\cdot p+0\cdot(1-p)=p. Linearity of expectation then gives E[X]=p+\cdots+p=np. This is shorter because it never sums over the values of X, so no binomial coefficient or reindexing is needed. Linearity also holds without independence.

About the Discrete Mathematics course

How many college credits is Discrete Mathematics?
Discrete Mathematics (Math 230) carries a NCCRS credit recommendation for 4 semester credits. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.
How much does Discrete Mathematics cost and what is included?
$250, paid once, with lifetime access: all 87 video lessons, a practice quiz after each, the graded work and final exam, and an official transcript when you finish. Students who want several courses choose UPI Study PRO instead.
Which universities accept UPI Study credits?
UPI Study has signed partner agreements with universities such as Thomas Edison State University, University of the People and Charter Oak State College, and works with universities such as Penn State, SNHU and SUNY. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities. Use "Find my college" on this page to check yours.
How long does Discrete Mathematics take?
It is self-paced with no deadlines. The 87 lessons total about 13 hours of video; most students add reading and practice time and finish in a few weeks to a few months, on their own schedule.
How are the exams done?
Quizzes and assignments are online in the course. The final exam is taken online with proctoring; a person on the UPI Study team checks assignments, usually within two days.
How do my credits reach my college?
When the course shows 100% complete, request the official transcript from your dashboard. It is sent to the college you name, and you can send it to more than one. Check your college first with "Find my college" on this page, or ask Athena.

Ready for the full course? Earn 4 credits in Discrete Mathematics.

87 video lessons, a quiz after each one, and the graded work that earns the credit. Recommended for credit by NCCRS.

Discrete Mathematics
4 credits · NCCRS
Enroll →