Skip to main content

Grades 9-12Free, no account needed

Geometric first-success probability calculator

Find exact first-success waiting probabilities, mean and variance, with a finite PMF prefix and an explicitly pooled infinite tail.

All calculators

Try your problem

After k means strictly more than k trials.
Positive probability at most 1; same p on every independent trial.
Whole integer 1-100. Paste geometric(exactly;1/4;3).

Your calculations stay in this browser. No input history is saved.

Supported inputs and limits

Modes exactly, at-most and after-k; integer cutoff k from 1 to 100, optional sign/leading zeroes but at most 12 integer digits. Constant success probability 0<p<=1; p=0 is rejected. All answers are exact rational powers. The graph displays 6-12 individual masses, then a pooled tail; requested mass within that tail is separately identified, including k beyond the prefix. Tiny plotted masses may be visually unresolved; exact table values remain. Scalars are signed integers, decimals with 1-6 decimal places, or integer fractions with positive denominator, at most 24 characters and 12 digits per integer part. Magnitude at most 1000000 and reduced denominator at most 1000000. No expressions, mixed numbers, repeating decimals, percent signs or scientific notation. Lists have at most 520 characters. All numerical answers and table values are exact rationals; diagram positions alone are approximate. Named paste commands are case-sensitive and at most 200 characters.

Understand the method

For independent trials with p=1/2, the first-success masses at trials 1, 2 and 3 are 1/2, 1/4 and 1/8. The pooled tail after 3 is 1/8. Prefix plus tail is 1; the mean waiting time is 2 trials.

Let X count trials through the first success in independent trials with the same success probability p. The possible trial counts are 1,2,3,...; p must be positive. At p=1, X=1 with certainty.

Writing q=1-p, exactly k trials means k-1 failures followed by one success, so P(X=k)=q^(k-1)p. After k means X>k, requiring k failures, so its probability is q^k.

At most k includes k and equals 1-q^k. The mean waiting time is 1/p trials and variance is (1-p)/(p squared) in trials squared. The displayed final bucket pools all counts beyond the shown prefix; it is not one additional trial or a truncated model. Exact prefix mass plus exact tail mass equals 1.

Worked examples

Read the reasoning, or load an example into the calculator.

First success on trial three

With p=1/4, exactly three trials requires two failures then success: (3/4)^2(1/4)=9/64. Mean waiting time is 4 trials.

At most three trials

With p=1/2, at most three trials has probability 1-(1/2)^3=7/8. The excluded tail is three consecutive failures.

Certain immediate success

With p=1, the first trial succeeds with certainty. After five trials has probability 0, mean is 1 and variance is 0; no infinite or undefined substitute is needed.

Try it without the calculator

Three questions for practice, not a graded school assessment. Your answers stay on this page and are not saved.

1. For p=1/2, what is P(X=2)?
2. For p=1/4, what is the mean trial count through first success?
3. For p=1/5, what is the probability of more than three trials?

Original Testinar learning content. This local preview is awaiting final review before publication.

Page UP