A binomial random variable is a type of discrete random variable that arises from a binomial experiment. A binomial experiment has the following characteristics:
- Fixed number of trials (n): The experiment is conducted a predetermined number of times.
- Two possible outcomes: Each trial results in one of two outcomes, often labeled as "success" and "failure."
- Constant probability (p): The probability of success (denoted as \(p\)) is the same for each trial.
- Independent trials: The outcomes of the trials are independent of one another.
The binomial random variable \(X\) represents the number of successes in these \(n\) trials.
Probability Mass Function (PMF)
The probability of observing exactly \(k\) successes (where \(k\) can range from 0 to \(n\)) in \(n\) trials is given by the binomial probability formula:
\[ P(X = k) = \binom{n}{k} p^k (1 - p)^{n - k} \]
Where:
- \(P(X = k)\) is the probability of getting exactly \(k\) successes.
- \(n\) is the total number of trials.
- \(k\) is the number of successes (where \(0 \leq k \leq n\)).
- \(p\) is the probability of success on an individual trial.
- \((1 - p)\) is the probability of failure.
- \(\binom{n}{k}\) is a binomial coefficient calculated as:
\[ \binom{n}{k} = \frac{n!}{k! (n - k)!} \]
Example Calculation
Suppose you want to find the probability of getting exactly 3 heads in 10 flips of a fair coin, where the probability of heads (success) is \(p = 0.5\):
- Set \(n = 10\) (the number of trials).
- Set \(k = 3\) (the desired number of successes).
- Calculate \(P(X = 3)\):
\[ P(X = 3) = \binom{10}{3} (0.5)^3 (0.5)^{10 - 3} \]
Calculating the binomial coefficient:
\[ \binom{10}{3} = \frac{10!}{3!(10 - 3)!} = \frac{10 \times 9 \times 8}{3 \times 2 \times 1} = 120 \]
Putting it all together:
\[ P(X = 3) = 120 \cdot (0.5)^3 \cdot (0.5)^7 = 120 \cdot (0.5)^{10} = 120 \cdot \frac{1}{1024} = \frac{120}{1024} = \frac{15}{128} \approx 0.1172 \]
Thus, the probability of getting exactly 3 heads in 10 flips of a fair coin is approximately \(0.1172\).