3.4 Geometric Distribution
Key Terms
- Geometric distribution(幾何分配)
A discrete distribution for the number of independent Bernoulli trials required to obtain the first success.
- Waiting time(等待次數)
The number of trials required before a specified success occurs.
- Memoryless property(無記憶性)
After any number of failures, the future waiting distribution is the same as it was at the beginning.
3.4.1 Main Idea
The geometric distribution uses the same Bernoulli-trial structure as the binomial distribution:
each trial has two outcomes, success or failure;
trials are independent;
the probability of success \(p\) is constant;
the probability of failure is \(q=1-p\).
The difference is the stopping rule.
For a binomial experiment, the number of trials is fixed and we count successes. For a geometric experiment, we repeat trials until the first success and count how many trials are required.
Let
Then
The number of possible trials is not fixed in advance. In principle, the waiting time can be arbitrarily large.
3.4.2 Bernoulli-Trial Structure
A geometric experiment is built from repeated Bernoulli trials. Every trial must have the same success probability \(p\) and failure probability \(q=1-p\).
The experiment stops as soon as the first success occurs. For example, if the first success occurs on trial 4, the observed sequence must have the form
The first three trials are failures and the fourth trial is the first success. This failure-then-success structure is the key to the geometric PMF.
3.4.3 Two Common Random-Variable Conventions
There are two common ways to define a geometric random variable. The formulas look slightly different, so the definition of the random variable must always be checked first.
In this handout, the main convention is
Thus,
An alternative convention is
Then
and the two variables are related by
Unless stated otherwise, the remainder of this section uses \(X\), the trial number of the first success.
3.4.4 Deriving the Geometric PMF
Suppose the first success occurs on trial \(x\).
Then the first \(x-1\) trials must all be failures, followed by a success on trial \(x\):
Because the trials are independent,
The probability that trial \(x\) is a success is \(p\). Therefore, by the multiplication rule,
Since \(q=1-p\), we obtain
Note
Geometric PMF
Unlike a binomial PMF, there is no combination coefficient. Once \(x\) is specified, the order is fixed: all previous trials must be failures and the last trial must be the first success.
3.4.5 Why the PMF Sums to 1
Let \(q=1-p\). Then
Factor out \(p\):
Using the geometric-series identity
we obtain
Because \(1-q=p\),
Thus the geometric PMF is a valid probability distribution.
3.4.6 Why It Is Called “Geometric”
Successive probabilities form a geometric sequence. In fact,
Therefore,
Each bar is a constant fraction \(q=1-p\) of the previous bar.
For example, when \(p=0.25\), the probabilities decrease by the common ratio \(q=0.75\).
The distribution is right-skewed: small waiting times are most likely, while large waiting times remain possible but become progressively less probable.
3.4.7 Example: First Success with \(p=0.25\)
Suppose independent Bernoulli trials have
Let \(X\) be the number of trials until the first success.
To find the probability that the first success occurs on trial 4,
Therefore,
The event requires exactly three failures followed by one success.
3.4.8 CDF and Tail Probabilities
The event \(X>x\) means that the first \(x\) trials are all failures. Therefore,
The cumulative distribution function follows from the complement rule:
Thus, for positive integers \(x\),
Note
Geometric CDF
Closely related forms are
and
For \(p=0.25\),
Equivalently, there is a 42.19% chance that the first three trials all fail.
3.4.9 Memoryless Property
The geometric distribution is memoryless. If no success has occurred in the first \(k\) trials, the future waiting-time distribution is the same as if the experiment had just started.
For integers \(k,m\ge0\),
Using the tail formula,
But
Therefore,
Note
Memoryless Property
Previous failures do not make a success “due.” The property follows from the independence of the Bernoulli trials and the fact that \(p\) remains constant.
For example, if \(p=0.25\) and the first five trials have failed, then
This is exactly the same probability as needing more than 3 trials from a fresh start.
3.4.10 Deriving the Mean
For a geometric random variable,
Substitute the PMF:
Start from the geometric series
Differentiate both sides with respect to \(q\):
Therefore,
Since \(1-q=p\),
Thus,
Note
Mean of a Geometric Distribution
For \(p=0.25\),
Over many repetitions, the first success occurs after 4 trials on average. The mean need not be an integer even though \(X\) takes only integer values.
3.4.11 Deriving the Variance
Use
First,
From the geometric series,
Differentiate again:
Hence,
Since \(1-q=p\),
Now subtract the squared mean:
Therefore,
Thus,
Note
Variance and Standard Deviation
and
For \(p=0.25\),
so
3.4.12 Alternative Convention: Failures Before Success
Suppose instead that
Then \(Y=X-1\), so
Its PMF is
Because \(Y=X-1\),
while subtracting a constant does not change variance:
This convention explains why geometric formulas may appear different across textbooks or software packages. Always check what the random variable counts.
3.4.13 Geometric as a Special Negative Binomial Case
The negative binomial distribution counts the number of trials required to obtain the \(r\)-th success. Setting
means stopping at the first success. Therefore, the geometric distribution is the special negative binomial case \(r=1\).
The negative-binomial PMF
becomes
3.4.14 Binomial Versus Geometric
Feature |
Binomial |
Geometric |
|---|---|---|
Number of trials |
Fixed \(n\) |
Random |
Number of successes |
Random |
Stop at first success |
Random variable |
Number of successes |
Trials until first success |
Support |
\(0,1,\ldots,n\) |
\(1,2,3,\ldots\) |
Main question |
How many successes? |
How long until success? |
The modeling distinction is more important than memorizing formulas.
3.4.15 A Simple Method
For a possible geometric problem:
Define what counts as a success.
Verify independent Bernoulli trials.
Verify that \(p\) is constant.
Check that trials continue until the first success.
Define clearly whether the random variable counts trials or failures.
Translate the requested event before calculating.
Use the PMF, CDF, or tail formula as appropriate.
3.4.16 Quick Practice
A fair six-sided die is rolled repeatedly. Define success as rolling a 6. Let \(X\) be the number of rolls until the first 6.
Find:
\(P(X=3)\);
\(P(X>3)\);
\(E(X)\); and
\(\operatorname{Var}(X)\).
Answer
Here,
Therefore,
Also,
The mean is
and the variance is
3.4.17 Common Mistakes
Do not use \(q^xp\) when \(X\) counts the trial number of the first success. There are only \(x-1\) failures before trial \(x\).
Do not include \(X=0\) under the trial-count convention. At least one trial is required.
Do not confuse “trials until first success” with “failures before first success.” They differ by 1.
Do not use a geometric model if \(p\) changes from trial to trial. For example, learning, fatigue, or sampling without replacement can violate the constant-probability assumption.
Do not interpret a long run of failures as evidence that success is now more likely. Under the geometric assumptions, the process is memoryless.
3.4.18 Summary
For
with independent Bernoulli trials and constant success probability \(p\),
The CDF and tail probability are
and
The mean and variance are
and
The key modeling question is:
Are we counting a fixed number of successes, or waiting until the first success occurs?