The negative-binomial distribution #
This file defines the negative-binomial family. The law counts failures before the rth success,
with real shape r and success probability p. Its native mass is the Gamma-expression
Γ(k + r) / (k! Γ(r)) * p^r * (1 - p)^k.
The definition is totalized explicitly: the positive family is used for 0 < r and 0 < p ≤ 1,
the boundary r = 0 is a Dirac mass at zero, and every other parameter value gives the zero
measure. The file supplies the normalized measure, its native singleton and support interfaces,
the exact integrability domain and closed form of its probability-generating function, and the
additivity of the shape parameter under convolution.
Main results #
negativeBinomialMeasure_singletonandnegativeBinomialMeasure_real_singletoncompute the native masses;negativeBinomialMeasure_singleton_ne_zero_iffcharacterizes their exact support, including the shape-zero and success-probability-one boundary laws;pgf_negativeBinomialMeasurecomputes the probability-generating function on its exact domain;negativeBinomialMeasure_conv_negativeBinomialMeasureproves that convolution adds shapes.
The normalization uses Mathlib's real binomial power series, after identifying its coefficients with the Gamma quotient. The distributional convention follows Johnson, Kemp, and Kotz, Univariate Discrete Distributions, 3rd ed., Chapter 5.
The real coefficient in the negative-binomial mass at k.
Equations
Instances For
The ℝ≥0∞-valued negative-binomial mass at k.
Equations
Instances For
The negative-binomial law with real shape r and success probability p.
For 0 < r and 0 < p ≤ 1 this is the weighted Dirac sum with the usual Gamma masses. The
boundary shape r = 0 is the Dirac law at zero; all remaining parameters are totalized to zero.
Equations
- One or more equations did not get rendered due to their size.
Instances For
In the valid parameter range, the measure is its weighted Dirac sum, including r = 0.
The boundary shape r = 0 is the Dirac law at zero in the valid probability range.
At nonzero shape, the real negative-binomial weight has its defining Gamma-quotient form.
The real negative-binomial mass in its multichoose coefficient form.
The negative-binomial measure is a probability measure in its classical parameter range.
For nonzero success probability, the geometric law is the negative-binomial law of shape one.
Support #
A real negative-binomial weight is positive exactly at zero or in the nondegenerate family.
Thus the shape-zero and success-probability-one laws are supported only at zero, while positive shape and success probability strictly below one give positive mass to every natural number.
For positive shape and valid success probability, the negative-binomial probability-generating-function integrand is integrable exactly inside its disk of convergence. Thus it is non-integrable both on and beyond the boundary.
At shape zero, the negative-binomial PGF is one in the valid probability range and zero
outside it, in accordance with the totalization of negativeBinomialMeasure.
Convolution #
The convolution of two negative-binomial laws with the same success probability is negative-binomial, with the shape parameters added. This includes either shape-zero boundary and the success-probability-one Dirac family; outside the valid probability range all three measures vanish.