geometric pdf calculator

Geometric PMF Calculator

Compute the probability of the first success occurring at a specific trial (or after a specific number of failures).

Valid range: 0 < p ≤ 1
For current mode, k must be an integer ≥ 1.
Enter values and click Calculate.

What this geometric PDF calculator does

This calculator evaluates the probability mass function (PMF) of a geometric distribution. In plain language, it answers questions like: “If each attempt succeeds with probability p, what is the probability that the first success happens exactly at trial k?”

The geometric model is used in quality control, reliability testing, call-center conversion tracking, and A/B testing scenarios where repeated independent trials continue until the first success appears.

Geometric PMF formulas

1) Trial-number definition

If X is the trial index of the first success (k = 1, 2, 3, ...), then:

P(X = k) = (1 - p)^(k - 1) * p

2) Failures-before-success definition

If X is the number of failures before the first success (k = 0, 1, 2, ...), then:

P(X = k) = (1 - p)^k * p

Both definitions describe the same process; they just shift the index by one.

How to use the calculator

  • Select how you define the random variable X.
  • Enter the success probability per trial p.
  • Enter integer k.
  • Click Calculate to get PMF, CDF, tail probability, mean, variance, and standard deviation.

Worked example

Example: 25% success chance per attempt

Suppose p = 0.25 and you want the probability that the first success occurs on the 3rd trial. Using the trial-number definition:

P(X = 3) = (1 - 0.25)^(3 - 1) * 0.25 = 0.75^2 * 0.25 = 0.140625

So there is about a 14.06% chance the first success happens exactly on trial 3.

Why geometric distributions are useful

  • Simple assumptions: independent trials with constant success probability.
  • Memoryless property: the future does not depend on past failures.
  • Fast planning estimates: expected attempts until first success are easy to compute.

Key interpretation tips

Mean and variance

For trial-number form, the mean is 1/p. For failures-before-success form, the mean is (1-p)/p. The variance in both forms is (1-p)/p^2.

CDF and tail probability

The calculator also shows cumulative probability P(X ≤ k) and tail probability P(X > k). These are often more useful in decision-making than a single exact-point probability.

Common mistakes to avoid

  • Using a non-integer k value.
  • Mixing up the two geometric definitions.
  • Entering p = 0 or p > 1, which are invalid.
  • Applying geometric distribution when success probability changes across trials.

Quick FAQ

Is this for continuous variables?

No. The geometric distribution is discrete.

Is this the same as a binomial calculator?

Not exactly. Binomial counts successes in a fixed number of trials, while geometric counts trials (or failures) until the first success.

What if my process has changing probabilities?

Then geometric assumptions are violated. Consider a non-homogeneous or simulation-based model instead.

🔗 Related Calculators