Probability Distributions

Negative Binomial Distribution Calculator

Use this negative binomial distribution calculator to find exact and cumulative probabilities for the trial on which the r-th success occurs. Enter the required number of successes (r), probability of success (p), and trial number (x) to get an instant answer with a clear step-by-step solution.

Enter a whole number of at least 1.
Enter a decimal greater than 0 and no greater than 1.
x represents the trial on which the r-th success occurs.

How to Use the Negative Binomial Distribution Calculator

This calculator allows you to find exact and cumulative probabilities for a negative binomial distribution. It is appropriate for trials on which a specified number of successes occurs. To use the calculator:

  1. Enter the required number of successes, r.
  2. Enter the probability of success, p, as a decimal.
  3. Enter the trial number, x, on which the r-th success occurs. For a between probability, enter the lower and upper trial numbers.
  4. Select the probability you want to find.
  5. Choose the number of decimal places for the final answer.
  6. Click Calculate.

The calculator returns the requested probability and shows how it was calculated step by step. It also provides the mean and standard deviation of the negative binomial distribution.

With this calculator, you can find:

  • Probability that the r-th success occurs exactly on trial x, P(X = x)
  • Probability that the r-th success occurs by trial x, P(X ≤ x)
  • Probability that the r-th success occurs before trial x, P(X < x)
  • Probability that the r-th success occurs on trial x or later, P(X ≥ x)
  • Probability that the r-th success occurs after trial x, P(X > x)
  • Probability that the r-th success occurs between trials a and b, P(a ≤ X ≤ b)

What Is a Negative Binomial Distribution?

A negative binomial distribution is a discrete probability distribution used to model the number of independent trials required to obtain a specified number of successes.

For example, suppose a salesperson has a 0.30 probability of making a sale on each independent call. If calls continue until the salesperson makes the third sale, the trial number on which that third sale occurs can be modeled using a negative binomial distribution.

In this calculator:

  • r is the required number of successes.
  • p is the probability of success on each trial.
  • X is the trial number on which the r-th success occurs.

For example, if r = 3 and X = 7, the third success occurs on trial 7. This means there must be exactly 2 successes among the first 6 trials, followed by a success on trial 7.

When Should You Use the Negative Binomial Distribution?

A negative binomial distribution is appropriate when:

  • each trial has two possible outcomes, usually called success and failure;
  • trials are independent;
  • the probability of success, p, remains constant from one trial to the next;
  • the required number of successes, r, is fixed in advance; and
  • trials continue until the r-th success occurs.

For example, you could use a negative binomial distribution to find the probability that the third sale occurs on the seventh customer call or that the fifth correct answer occurs by question 9.

If the number of trials is fixed and you want to count how many successes occur, use the Binomial Distribution Calculator instead.

Negative Binomial Distribution Formula

The negative binomial distribution formula is:

P(X=x)=(x1r1)pr(1p)xrP(X=x)=\binom{x-1}{r-1}p^r(1-p)^{x-r}

Where:

  • X is the trial number on which the r-th success occurs.
  • x is the specified trial number.
  • r is the required number of successes.
  • p is the probability of success on each trial.
  • 1 − p is the probability of failure.
  • The combination term counts the number of ways the first r − 1 successes can occur within the first x − 1 trials.

The formula allows you to calculate the probability that the r-th success occurs exactly on trial x, where X represents the trial number on which the r-th success occurs.

The formula works because the r-th success must occur on trial x. Therefore, among the first x – 1 trials, there must be exactly r – 1 successes. Trial x must then be a success.

Why Must x Be at Least r?

The r-th success cannot occur before r trials have taken place. For example, if you need 4 successes, the earliest possible trial on which the fourth success can occur is trial 4. Therefore, x ≥ r.

For instance, if r = 4 and x = 3, P(X = 3) = 0 because it is impossible to obtain 4 successes in only 3 trials. This is an important check when entering values into the negative binomial calculator.

Exact and Cumulative Negative Binomial Probabilities

An exact negative binomial probability finds the probability that the r-th success occurs on one specific trial. For example, P(X = 7) means that the r-th success occurs exactly on trial 7. On the other hand, a cumulative probability covers several possible trial numbers. For example, P(X ≤ 7) means that the r-th success occurs on trial 7 or earlier.

Since the earliest possible value of X is r: P(X ≤ 7) = P(X = r) + P(X = r + 1) + … + P(X = 7). The other cumulative probability formulas for the negative binomial distribution are:

  • Less than x: P(X < x) = P(X ≤ x − 1)
  • At least x: P(X ≥ x) = 1 − P(X ≤ x − 1)
  • More than x: P(X > x) = 1 − P(X ≤ x)
  • Between a and b: P(a ≤ X ≤ b) = P(X = a) + P(X = a + 1) + … + P(X = b)

The calculator automatically performs these calculations based on the probability you select.

How to Calculate Negative Binomial Probability

To calculate negative binomial probability manually:

  1. Identify the required number of successes, r, the probability of success, p, and the trial number, x.
  2. Determine whether the question asks for an exact, at most, less than, at least, more than, or between probability.
  3. For an exact probability, substitute the values directly into the negative binomial formula. However, for a cumulative probability, calculate and combine the required exact probabilities or use the complement rule where appropriate.

Example 1: Exact Negative Binomial Probability

A customer service representative successfully resolves a particular type of issue on each independent attempt with a probability of 0.40. What is the probability that the representative gets the third successful resolution on the seventh attempt?

Solution

From the question, we know that:

  • Required number of successes, r = 3
  • Probability of success, p = 0.40
  • Trial number, x = 7

In this case, a success means successfully resolving the issue.

We need to find the probability that the third success occurs exactly on trial 7. Thus, we need to find P(X = 7)

Recall. The negative binomial probability formula is:

P(X=x)=(x1r1)pr(1p)xrP(X=x)=\binom{x-1}{r-1}p^r(1-p)^{x-r}

Substituting r = 3, p = 0.40, and x = 7 gives:

P(X=7)=(7131)(0.40)3(0.60)73P(X=7)=\binom{7-1}{3-1}(0.40)^3(0.60)^{7-3}
=(62)(0.40)3(0.60)4=\binom{6}{2}(0.40)^3(0.60)^4

= 15 x 0.064 x 0.1296

= 0.124416

This implies that the probability that the representative gets the third successful resolution exactly on the seventh attempt is approximately 0.1244.

Example 2: Cumulative Negative Binomial Probability

A sales representative has a 0.35 probability of making a sale on each independent customer call. What is the probability that the representative makes the third sale on the seventh call or later?

Solution

From the question, we know that:

  • Required number of successes, r = 3
  • Probability of success, p = 0.35
  • Trial number, x = 7

In this case, a success means making a sale. “On the seventh call or later” means the third success occurs on trial 7 or after.

Thus, we need to find P(X ≥ 7)

Rather than adding an infinite number of probabilities beginning at X = 7, we can use the complement rule.

Using the complement rule, P(X ≥ 7) = 1 − P(X ≤ 6)

Since the third success cannot occur before trial 3, P(X ≤ 6) = P(X = 3) + P(X = 4) + P(X = 5) + P(X = 6). Computing the individual probabilities using the negative binomial distribution formula, we get:

For x = 3:

P(X=3)=(3131)(0.35)3(0.65)33P(X=3)=\binom{3-1}{3-1}(0.35)^3(0.65)^{3-3}
=(22)(0.35)3(0.65)0=\binom{2}{2}(0.35)^3(0.65)^0

= 1 x 0.042875 x 1

= 0.042875

For x = 4:

P(X=4)=(4131)(0.35)3(0.65)43P(X=4)=\binom{4-1}{3-1}(0.35)^3(0.65)^{4-3}
=(32)(0.35)3(0.65)1=\binom{3}{2}(0.35)^3(0.65)^1

=3 x 0.042875 x 0.65

= 0.08360625

For x = 5:

P(X=5)=(5131)(0.35)3(0.65)53P(X=5)=\binom{5-1}{3-1}(0.35)^3(0.65)^{5-3}
=(42)(0.35)3(0.65)2=\binom{4}{2}(0.35)^3(0.65)^2

= 6 x 0.042875 x 0.4225

= 0.108688

For X = 6:

P(X=6)=(6131)(0.35)3(0.65)63P(X=6)=\binom{6-1}{3-1}(0.35)^3(0.65)^{6-3}
=(52)(0.35)3(0.65)3=\binom{5}{2}(0.35)^3(0.65)^3

= 10 x 0.042875 x 0.274625

= 0.11774547

Therefore, P(X ≤ 6) = 0.042875 + 0.08360625 + 0.10868812 + 0.11774547

= 0.35291484

Now, applying the complement rule, we get:

P(X ≥ 7) = 1 − 0.35291484

= 0.64708516

This implies that the probability that the representative makes the third sale on the seventh call or later is approximately 0.6471.

Mean and Standard Deviation of a Negative Binomial Distribution

Besides the requested probability, the calculator also provides the mean and standard deviation of the negative binomial distribution.

The mean of a negative binomial distribution is: μ = r/p. It represents the expected number of trials required to obtain r successes.

For example, suppose r = 3 and p = 0.40; we can calculate the mean of the negative binomial distribution as follows:

μ = 3/0.40

= 7.5

Therefore, over many repetitions of the negative binomial experiment, it would take an average of 7.5 trials to obtain 3 successes.

The variance of a negative binomial distribution is: σ2 = r(1 − p)/p² and the standard deviation is: σ = √[r(1 − p)]/p.

Therefore, using r = 3 and p = 0.40, we can calculate the standard deviation as follows:

σ = √[3(1 − 0.40)]/0.40

= √1.8/0.40

= 3.3541

Negative Binomial Distribution vs. Binomial Distribution

The negative binomial and binomial distributions involve the same basic type of independent success/failure trials, but they answer different questions. With a binomial distribution, the number of trials is fixed, and you count the number of successes. However, with a negative binomial distribution, the required number of successes is fixed, and you count how many trials are needed to reach that number of successes.

Negative Binomial vs. Geometric Distribution

The geometric distribution is a special case of the negative binomial distribution. While a geometric distribution models the trial on which the first success occurs, a negative binomial distribution models the trial on which the r-th success occurs.

Therefore, when r = 1, the negative binomial distribution becomes a geometric distribution.

Common Mistakes When Calculating Negative Binomial Probability

Avoid these common mistakes when finding negative binomial probabilities:

  • Confusing r and x. r is the required number of successes, while x is the trial on which the r-th success occurs.
  • Entering x smaller than r. The r-th success cannot occur before trial r.
  • Entering p as a percentage instead of a decimal. For a 40% probability of success, enter p = 0.40.
  • Confusing negative binomial and binomial problems. Binomial fixes the number of trials; negative binomial fixes the required number of successes.
  • Confusing at least and more than. P(X ≥ 7) includes trial 7, while P(X > 7) does not.
  • Confusing at most and less than. P(X ≤ 7) includes trial 7, while P(X < 7) does not.
  • Using the wrong negative binomial convention. This calculator counts total trials until the r-th success, not failures before the r-th success.
  • Using a changing probability of success. The standard negative binomial distribution assumes that p remains constant across trials.

Frequently Asked Questions

What is a negative binomial distribution calculator?

A negative binomial distribution calculator is a tool used to find probabilities for the trial on which a specified number of successes occurs in a sequence of independent trials. This calculator finds exact and cumulative probabilities and also provides the mean, standard deviation, percentage, and a clear step-by-step solution.

What do r, p, and x mean in a negative binomial distribution?

In this calculator, r is the required number of successes, p is the probability of success on each trial, and x is the trial number on which the r-th success occurs.

What is the negative binomial probability formula?

When X represents the trial number on which the r-th success occurs, the formula is: P(X=x)=(x1r1)pr(1p)xrP(X=x)=\binom{x-1}{r-1}p^r(1-p)^{x-r}. The formula only applies when x ≥ r.

How do I find the probability that the r-th success occurs by trial x?

“By trial x” means that the r-th success occurs on trial x or earlier. Therefore, calculate P(X ≤ x), which is the sum of the possible exact probabilities from X = r through X = x.

What is the mean of a negative binomial distribution?

The mean of a negative binomial distribution is: μ = r/p. This represents the expected number of trials required to obtain r successes.

What is the standard deviation of a negative binomial distribution?

The standard deviation of a negative binomial distribution is σ = √[r(1 − p)/p].

What is the difference between a negative binomial and geometric distribution?

The geometric distribution finds the trial on which the first success occurs, while the negative binomial distribution finds the trial on which the r-th success occurs. Therefore, the geometric distribution is the special case of the negative binomial distribution where r = 1.

Cite

Choose APA, MLA, Chicago, or Harvard, then copy the citation.

Mburu, J.. (2026, September 1). Negative Binomial Distribution Calculator. StatCalc.net. Retrieved September 11, 2026, from https://statcalc.net/negative-binomial-distribution-calculator/

Joseph Mburu

About This Calculator

Prepared by Joseph Mburu · Updated on

Joseph is an applied statistician and data analyst with over 6 years of experience helping students, researchers, and professionals solve statistics and data analysis problems. He holds a degree in Applied Statistics and a Master’s degree in Data…

We aim to keep our calculators accurate, easy to use, and helpful for learning. Always check that your inputs match the assumptions of the method you are using.