Solved Exercises on Binomial Random Variables Intro

Master binomial random variables: probability, expected value, variance, and applications through these 5 detailed exercises.

Solution: Exercises 1 to 3
1 Basic Binomial Probability
Exercise 1
A fair coin is flipped 5 times. Find the probability of getting exactly 3 heads.
Definition:

Binomial Distribution: A discrete probability distribution that models the number of successes in a fixed number of independent Bernoulli trials, each with the same probability of success. X ~ B(n,p) where n is the number of trials and p is the probability of success.

Binomial probability method:
  1. Identify n (number of trials) and p (probability of success)
  2. Determine k (number of successes desired)
  3. Apply the binomial probability formula: P(X=k) = C(n,k)p^k(1-p)^(n-k)
  4. Calculate the result
Parameters
n=5, p=0.5
Desired
k=3
Formula
C(5,3)×(0.5)³×(0.5)²
Result
0.3125
Step 1: Identify parameters

n = 5 (number of coin flips), p = 0.5 (probability of getting heads on each flip), k = 3 (number of heads desired).

Step 2: Apply binomial probability formula

P(X = 3) = C(5,3)(0.5)³(1-0.5)^(5-3) = C(5,3)(0.5)³(0.5)²

Step 3: Calculate

C(5,3) = 5!/(3!2!) = (5×4×3!)/(3!×2!) = (5×4)/2 = 10. P(X = 3) = 10 × (0.125) × (0.25) = 0.3125.

P(X = 3) = 0.3125
Final answer:

The probability of getting exactly 3 heads in 5 flips is 0.3125 or 31.25%.

Applied rules:

• Binomial probability: P(X = k) = C(n,k)p^k(1-p)^(n-k)

• Combination formula: C(n,k) = n!/[k!(n-k)!]

• Independence: Each coin flip is independent of others

2 Expected Value and Variance
Exercise 2
For the coin flip scenario in Exercise 1, find the expected number of heads and the variance.
Definition:

Binomial Expected Value: For X ~ B(n,p), the expected value is E[X] = np. Binomial Variance: Var(X) = np(1-p). These formulas provide quick calculations for binomial distributions.

Given
n=5, p=0.5
Expected value
E[X] = n×p
Variance
Var(X) = n×p×(1-p)
Results
2.5, 1.25
Step 1: Apply expected value formula

For X ~ B(n,p): E[X] = np = 5 × 0.5 = 2.5. We expect 2.5 heads on average.

Step 2: Apply variance formula

For X ~ B(n,p): Var(X) = np(1-p) = 5 × 0.5 × (1-0.5) = 5 × 0.5 × 0.5 = 1.25.

Step 3: Calculate standard deviation

SD(X) = √Var(X) = √1.25 ≈ 1.118.

E[X] = 2.5, Var(X) = 1.25
Final answer:

The expected number of heads is 2.5 and the variance is 1.25.

Applied rules:

• Binomial expectation: E[X] = np

• Binomial variance: Var(X) = np(1-p)

• Computational efficiency: Use formulas instead of calculating from definition

3 Cumulative Binomial Probability
Exercise 3
A quiz has 10 multiple-choice questions, each with 4 options. If a student guesses randomly on all questions, find the probability of getting at least 3 correct answers.
Definition:

Cumulative Binomial Probability: P(X ≤ k) = Σ(i=0 to k) P(X = i) or P(X ≥ k) = 1 - P(X ≤ k-1). Using the complement can simplify calculations.

Parameters
n=10, p=1/4
For P(X≥3)
1-P(X≤2)
P(X≤2)
P(X=0)+P(X=1)+P(X=2)
Result
≈0.4744
Step 1: Identify parameters

n = 10 (questions), p = 1/4 (probability of guessing correctly), X = number of correct answers.

Step 2: Use complement for efficiency

P(X ≥ 3) = 1 - P(X ≤ 2) = 1 - [P(X = 0) + P(X = 1) + P(X = 2)]

Step 3: Calculate individual probabilities

P(X = 0) = C(10,0)(1/4)⁰(3/4)¹⁰ ≈ 0.0563

P(X = 1) = C(10,1)(1/4)¹(3/4)⁹ ≈ 0.1877

P(X = 2) = C(10,2)(1/4)²(3/4)⁸ ≈ 0.2816

Step 4: Calculate final probability

P(X ≥ 3) = 1 - (0.0563 + 0.1877 + 0.2816) = 1 - 0.5256 = 0.4744

P(X ≥ 3) ≈ 0.4744
Final answer:

The probability of getting at least 3 correct answers is approximately 0.4744 or 47.44%.

Applied rules:

• Complement rule: P(A) = 1 - P(A^c)

• Cumulative probability: Sum individual probabilities

• Computational efficiency: Use complement when calculating "at least" probabilities

Rules and methods, laws,...
\(P(X = k) = \binom{n}{k}p^k(1-p)^{n-k}\)
Binomial Probability Formula
Probability
P(X=k) = C(n,k)p^k(1-p)^(n-k)
Exact success count
Expected Value
E[X] = np
Mean number of successes
Variance
Var(X) = np(1-p)
Spread of distribution
Standard Deviation
SD(X) = √[np(1-p)]
Units same as X
Key definitions:

Binomial Random Variable: A discrete random variable that represents the number of successes in n independent Bernoulli trials, each with the same probability p of success.

Bernoulli Trial: A single experiment with only two possible outcomes: success (with probability p) or failure (with probability 1-p).

Parameters: n = number of trials, p = probability of success on each trial.

Conditions: 1) Fixed number of trials, 2) Independent trials, 3) Constant probability of success, 4) Binary outcomes.

Notation: X ~ B(n,p) means X follows a binomial distribution with parameters n and p.

Complete methodology:
  1. Verify conditions: Check that we have n independent trials with constant p
  2. Identify parameters: Determine n (trials) and p (probability of success)
  3. Determine what's asked: Exact value, range, cumulative probability?
  4. Select formula: Use appropriate binomial formula
  5. Calculate: Apply the formula carefully
  6. Interpret: Make sure the answer makes sense
Tip 1: Use the complement rule P(X ≥ k) = 1 - P(X ≤ k-1) to simplify calculations.
Tip 2: Remember: E[X] = np and Var(X) = np(1-p) for binomial distributions.
Tip 3: Check that p is constant across all trials.
Tip 4: Trials must be independent for binomial distribution to apply.
Common errors: Misidentifying n and p, forgetting to verify independence, miscalculating combinations, misapplying formulas to non-binomial situations.
Key insight: Binomial distribution models the sum of independent Bernoulli trials.
Essential formulas:

• Probability: P(X = k) = C(n,k)p^k(1-p)^(n-k)

• Expected value: E[X] = np

• Variance: Var(X) = np(1-p)

• Standard deviation: SD(X) = √[np(1-p)]

• Cumulative: P(X ≤ k) = Σ(i=0 to k) P(X = i)

Solution: Exercises 4 to 5
4 Real-World Binomial Application
Exercise 4
A manufacturing company knows that 5% of its products are defective. If a quality inspector randomly selects 20 products, find the probability that exactly 2 are defective and the expected number of defective products.
Definition:

Real-World Binomial: Many practical scenarios follow binomial distribution when we have a fixed number of independent trials with constant probability of "success" (in this case, "defective" is the "success" we're counting).

Parameters
n=20, p=0.05
P(X=2)
C(20,2)(0.05)²(0.95)¹⁸
E[X]
n×p
Results
0.1887, 1
Step 1: Identify the binomial parameters

n = 20 (products selected), p = 0.05 (probability of being defective), X = number of defective products.

Step 2: Calculate P(X = 2)

P(X = 2) = C(20,2)(0.05)²(0.95)¹⁸ = 190 × 0.0025 × (0.95)¹⁸ ≈ 190 × 0.0025 × 0.3972 ≈ 0.1887

Step 3: Calculate expected value

E[X] = np = 20 × 0.05 = 1. We expect 1 defective product on average.

P(X = 2) ≈ 0.1887, E[X] = 1
Final answer:

The probability of exactly 2 defective products is approximately 0.1887, and the expected number of defective products is 1.

Applied rules:

• Real-world application: Identify success/failure in context

• Binomial probability: Apply the formula with correct parameters

• Expected value: Use E[X] = np for quick calculation

5 Finding Parameters
Exercise 5
A binomial random variable X has mean 12 and variance 8. Find n and p.
Definition:

Parameter Estimation: Given mean and variance of a binomial distribution, we can solve for n and p using the relationships E[X] = np and Var(X) = np(1-p).

Given
E[X]=12, Var(X)=8
Equations
np=12, np(1-p)=8
Solve for p
1-p=8/12=2/3
Results
n=36, p=1/3
Step 1: Set up equations using binomial properties

For X ~ B(n,p): E[X] = np = 12 and Var(X) = np(1-p) = 8.

Step 2: Solve for p

Divide the variance equation by the mean equation: [np(1-p)] / [np] = 8/12. This gives (1-p) = 2/3, so p = 1/3.

Step 3: Solve for n

Substitute p = 1/3 into np = 12: n(1/3) = 12, so n = 36.

Step 4: Verify the solution

Check: E[X] = 36 × (1/3) = 12 ✓ and Var(X) = 36 × (1/3) × (2/3) = 12 × (2/3) = 8 ✓

n = 36, p = 1/3
Final answer:

n = 36 and p = 1/3.

Applied rules:

• System of equations: Use both mean and variance equations

• Algebraic manipulation: Divide equations to eliminate n

• Verification: Always check that your solution satisfies both conditions

Comprehensive Summary: Binomial Random Variables Intro
\(P(X = k) = \binom{n}{k}p^k(1-p)^{n-k}\)
Binomial Probability Formula
Key definitions:

Binomial Random Variable: A discrete random variable that counts the number of successes in n independent Bernoulli trials, each with the same probability p of success.

Bernoulli Trial: A single experiment with only two possible outcomes: success (with probability p) or failure (with probability 1-p).

Parameters: n = number of trials, p = probability of success on each trial.

Conditions: 1) Fixed number of trials, 2) Independent trials, 3) Constant probability of success, 4) Binary outcomes.

Notation: X ~ B(n,p) means X follows a binomial distribution with parameters n and p.

Support: X can take values 0, 1, 2, ..., n.

Complete methodology:
  1. Verify binomial conditions: Check for fixed n, independence, constant p, binary outcomes
  2. Identify parameters: Determine n (number of trials) and p (probability of success)
  3. Determine what's needed: Exact probability, cumulative probability, expected value, variance?
  4. Select appropriate formula: Use probability, expectation, or variance formula as needed
  5. Calculate carefully: Apply formulas accurately, especially combinations
  6. Interpret results: Understand the practical meaning of the answer
Tip 1: Use the complement rule P(X ≥ k) = 1 - P(X ≤ k-1) to simplify "at least" calculations.
Tip 2: Remember: E[X] = np and Var(X) = np(1-p) for quick calculations.
Tip 3: Verify that trials are independent and p remains constant across all trials.
Tip 4: For large n, calculations can be tedious; consider using technology or approximations.
Tip 5: The binomial distribution approaches normal distribution as n increases (Central Limit Theorem).
Common errors: Misidentifying n and p, forgetting to verify independence, miscalculating combinations, misapplying formulas to non-binomial situations, confusing probability of success with probability of failure.
Memorization aid: "Binomial = Bernoulli trials summed, E[X] = np, Var(X) = np(1-p)".
Advanced insight: Binomial distribution is fundamental to many statistical tests and confidence intervals.
Essential formulas and properties:

• Probability: P(X = k) = C(n,k)p^k(1-p)^(n-k)

• Expected value: E[X] = np

• Variance: Var(X) = np(1-p)

• Standard deviation: SD(X) = √[np(1-p)]

• Support: X ∈ {0, 1, 2, ..., n}

• Sum: If X ~ B(n₁,p) and Y ~ B(n₂,p) are independent, then X + Y ~ B(n₁+n₂,p)

Example progression (Simple to Complex):

• Simple: Fair coin flips (n=small, p=0.5)

• Intermediate: Multiple choice quizzes (n=moderate, p=1/4)

• Advanced: Quality control (real-world applications)

• Complex: Parameter estimation and inference

Key takeaways for memorization:

• Binomial counts successes in n independent trials

• Requires: Fixed n, independence, constant p, binary outcomes

• E[X] = np and Var(X) = np(1-p) are fundamental

• Use complement rule for "at least" or "at most" calculations

• Check conditions before applying binomial formulas

Questions & Answers

Question: How do I know if a situation follows a binomial distribution?

Answer: A situation follows a binomial distribution if it meets all four conditions:

  • Fixed number of trials (n): The number of experiments is predetermined
  • Independent trials: The outcome of one trial doesn't affect others
  • Constant probability (p): The probability of success is the same for each trial
  • Binary outcomes: Each trial results in either success or failure

Example: Flipping a coin 10 times (✓ all conditions). Counter-example: Drawing cards without replacement (✗ not independent).

Question: Why is the variance of a binomial distribution np(1-p) and not just np?

Answer: The variance formula comes from the definition of variance and the binomial distribution:

  • For a single Bernoulli trial, Var(X) = p(1-p)
  • Since binomial is the sum of n independent Bernoulli trials, Var(sum) = sum of variances
  • Therefore: Var(X) = n × p(1-p) = np(1-p)

The (1-p) factor accounts for the uncertainty in each trial. When p=0.5, uncertainty is highest. When p=0 or p=1, there's no uncertainty and variance is 0.

Question: Can I use the binomial distribution if the probability of success changes from trial to trial?

Answer: No, the binomial distribution requires that the probability of success (p) remains constant across all trials. If p changes, the distribution is no longer binomial.

  • If p changes: You might need other distributions like Poisson binomial
  • Example of non-constant p: Drawing cards without replacement (probability changes after each draw)
  • Example of constant p: Rolling a die multiple times (probability of rolling a 6 stays 1/6)

Always verify that p remains constant before applying binomial formulas.