Tutorials › VEE Mathematical Statistics › Gamma Sums Through MGFs

VEE Mathematical Statistics · Moment Generating Functions · Tutorial 240 of 880

Gamma Sums Through MGFs

Learn how independence and a shared gamma rate make shape parameters add, and how parameterization mismatches can lead to incorrect conclusions.

Intermediate 9 min read

What You'll Learn

  • Write the gamma MGF using the shape-rate parameterization and its domain.
  • Apply the product rule to derive the distribution of a sum with a common rate.
  • Convert scale parameters to rates before deciding whether gamma variables have a common parameter.
  • Verify a gamma-sum result by comparing means and variances.
  • Explain why independent gamma variables with different rates do not generally have a gamma sum.

Why a Shared Rate Matters

A sum of independent gamma random variables is especially easy to identify when the variables share a rate: their shape parameters add, while the common rate stays unchanged. This result follows directly from the product rule for moment generating functions (MGFs). The parameter condition is essential. Two gamma variables may both be gamma-distributed and independent, yet have different rates; in that case, the product of their MGFs generally does not have the form of a single gamma MGF.

Before combining parameters, check which gamma convention is being used. A rate and a scale are reciprocals, so equal numerical values for one variable's rate and another variable's scale do not mean those variables have a common rate.

Definition: In this tutorial, \(\operatorname{Gamma}(\alpha,\beta)\) denotes the gamma distribution with shape \(\alpha>0\) and rate \(\beta>0\). Its density, for \(x>0\), is $$ f_X(x)=\frac{\beta^\alpha}{\Gamma(\alpha)}x^{\alpha-1}e^{-\beta x}, $$ and its MGF is $$ M_X(t)=\left(1-\frac{t}{\beta}\right)^{-\alpha},\qquad t<\beta. $$ Here \(\Gamma(\alpha)\) is the gamma function. If instead a gamma distribution is specified by shape \(\alpha\) and scale \(\theta>0\), its rate is \(\beta=1/\theta\), and its MGF is \(M_X(t)=(1-\theta t)^{-\alpha}\) for \(t<1/\theta\).

The Gamma-Sum Result

Suppose \(X_1,\ldots,X_n\) are mutually independent and \(X_j\sim\operatorname{Gamma}(\alpha_j,\beta)\) for every \(j\), with the same rate \(\beta\). Independence allows us to multiply their MGFs. The resulting expression is the MGF of a gamma distribution whose shape is the sum of the individual shapes.

Theorem: If \(X_1,\ldots,X_n\) are independent and \(X_j\sim\operatorname{Gamma}(\alpha_j,\beta)\), where every variable has the same rate \(\beta\), then $$ \sum_{j=1}^{n}X_j\sim\operatorname{Gamma}\left(\sum_{j=1}^{n}\alpha_j,\beta\right). $$ The variables must be independent, and their rates—not merely their distribution families—must agree.

For two independent variables, the reason is visible in a few algebraic steps. The MGF of a sum is the product of the individual MGFs when the variables are independent. Since the rate is common, both factors have the same base, so their exponents combine.

$$ \begin{aligned} M_{X_1+X_2}(t) &=M_{X_1}(t)M_{X_2}(t)\\ &=\left(1-\frac{t}{\beta}\right)^{-\alpha_1} \left(1-\frac{t}{\beta}\right)^{-\alpha_2}\\ &=\left(1-\frac{t}{\beta}\right)^{-(\alpha_1+\alpha_2)}. \end{aligned} $$

This product is an MGF on the interval \(t<\beta\), which includes an open interval around zero. It matches the MGF of \(\operatorname{Gamma}(\alpha_1+\alpha_2,\beta)\). By the uniqueness theorem for MGFs, the sum has that distribution. For \(n\) variables, the same multiplication adds all the exponents.

Worked Example: Adding Shapes at a Common Rate

A hypothetical system records two independent waiting times \(X\) and \(Y\), measured in hours. Suppose \(X\sim\operatorname{Gamma}(2,3)\) and \(Y\sim\operatorname{Gamma}(5,3)\), using shape-rate parameters. Find the distribution, mean, and variance of \(T=X+Y\).

Method. Check independence and compare rates first. The variables are independent, and both rates are \(3\), so the gamma-sum theorem applies.

Their MGFs are $$ M_X(t)=\left(1-\frac{t}{3}\right)^{-2}, \qquad M_Y(t)=\left(1-\frac{t}{3}\right)^{-5}, \qquad t<3. $$ Therefore, $$ M_T(t)=M_X(t)M_Y(t) =\left(1-\frac{t}{3}\right)^{-2} \left(1-\frac{t}{3}\right)^{-5} =\left(1-\frac{t}{3}\right)^{-7}. $$

This is the MGF of \(\operatorname{Gamma}(7,3)\), so \(T\sim\operatorname{Gamma}(7,3)\). For a gamma variable with shape \(\alpha\) and rate \(\beta\), the mean is \(\alpha/\beta\) and the variance is \(\alpha/\beta^2\). Thus $$ E[T]=\frac{7}{3}\text{ hours},\qquad \operatorname{Var}(T)=\frac{7}{3^2}=\frac{7}{9}\text{ hours}^2. $$

Check. The component means add to \(2/3+5/3=7/3\), and the component variances add to \(2/9+5/9=7/9\), agreeing with the identified distribution. The common mistake is to add rates as well as shapes; the rate remains \(3\).

Converting Between Rate and Scale

The scale form of the MGF is \((1-\theta t)^{-\alpha}\), while the rate form is \((1-t/\beta)^{-\alpha}\). These are the same expression when \(\theta=1/\beta\). To use the sum result with mixed notation, convert each scale to its reciprocal rate, or rewrite all MGFs in the scale form. The sum rule applies when the rates agree, equivalently when the scales agree.

Worked Example: Converting a Scale Before Adding

Suppose independent hypothetical repair durations \(X\) and \(Y\), in days, have these specifications: \(X\) has shape \(3\) and scale \(2\), while \(Y\) has shape \(4\) and rate \(1/2\). Find the distribution, mean, and variance of \(T=X+Y\).

Method. Convert both specifications to one parameterization. The rate for \(X\) is the reciprocal of its scale: $$ \beta_X=\frac{1}{2}. $$ The stated rate for \(Y\) is also \(1/2\). Thus the variables are independent with a common rate \(1/2\), and their shapes add to \(3+4=7\).

The MGF of \(X\), written from its scale, is \((1-2t)^{-3}\). For \(Y\), the rate form gives \((1-t/(1/2))^{-4}=(1-2t)^{-4}\). Multiplying, $$ M_T(t)=(1-2t)^{-3}(1-2t)^{-4}=(1-2t)^{-7},\qquad t<\frac12. $$ This is the MGF of shape \(7\), scale \(2\), or equivalently shape \(7\), rate \(1/2\). Therefore, $$ E[T]=\frac{7}{1/2}=14\text{ days},\qquad \operatorname{Var}(T)=\frac{7}{(1/2)^2}=28\text{ days}^2. $$

Check. \(X\) has mean \(3(2)=6\) and variance \(3(2^2)=12\); \(Y\) has mean \(4/(1/2)=8\) and variance \(4/(1/2)^2=16\). Their sums are \(14\) and \(28\), as above. The trap is to mistake the scale \(2\) for a rate and conclude the parameters do not match.

What Changes When Rates Differ?

Independence still gives the product of the MGFs if the rates differ, but the factors then have different bases. They cannot generally be combined by adding exponents into one gamma MGF. In particular, do not apply the common-rate theorem just because each summand is gamma-distributed.

Worked Example: Detecting Unequal Rates

Let independent hypothetical claim-processing durations \(X\) and \(Y\), in days, satisfy \(X\sim\operatorname{Gamma}(2,2)\) and \(Y\sim\operatorname{Gamma}(3,4)\), both in shape-rate form. Determine whether \(T=X+Y\) has a gamma distribution. Also find its mean and variance.

Method. Form the product MGF and check whether it has the single-rate gamma form. The rates are \(2\) and \(4\), so the common-rate theorem does not apply: $$ M_T(t)=\left(1-\frac{t}{2}\right)^{-2} \left(1-\frac{t}{4}\right)^{-3},\qquad t<2. $$ A single gamma MGF has the form \((1-t/\beta)^{-\alpha}\), with one rate and thus one singular boundary. The displayed product has distinct singularities at \(t=2\) and \(t=4\); it cannot be a single gamma MGF. Consequently, \(T\) is not generally gamma-distributed.

Its mean and variance can still be found by adding the component means and variances, since \(X\) and \(Y\) are independent. In detail, $$ E[T]=\frac{2}{2}+\frac{3}{4}=1+\frac34=\frac74\text{ days}, $$ and $$ \operatorname{Var}(T)=\frac{2}{2^2}+\frac{3}{4^2} =\frac12+\frac{3}{16} =\frac{8}{16}+\frac{3}{16} =\frac{11}{16}\text{ days}^2. $$

Check. Matching these two moments to a gamma distribution would require shape \((7/4)^2/(11/16)=49/11\) and rate \((7/4)/(11/16)=28/11\). That candidate's MGF would have one singular boundary, at \(28/11\), and cannot equal the product MGF above. The trap is to infer a gamma distribution from matching only the mean and variance; matching moments does not establish the distribution.

Using the Result Reliably

A short parameter check prevents most errors. Confirm independence, put every variable into the same convention, and compare rates (or, equivalently, compare scales). Only after both conditions are satisfied should you add shapes. A final mean-and-variance check is useful, but it verifies consistency rather than proving the distribution by itself.

1
State the model.
Write the shape and rate or scale of every gamma variable, and state that the variables are independent.
2
Align the parameterization.
Convert each scale \(\theta\) to its rate \(1/\theta\), or express all variables using scale.
3
Check the shared parameter.
If rates (or scales) agree, multiply MGFs and add shapes. If they do not, do not claim the sum is gamma on the basis of this theorem.
4
Verify the result.
For a proposed gamma sum, check that its mean and variance agree with the sums of the component means and variances.

The shared-rate condition is what makes the gamma family closed under sums of independent variables: it gives every MGF factor the same base, leaving only exponents to combine. This MGF argument is aligned with the SOA VEE Mathematical Statistics syllabus and is useful whenever a model represents a total accumulated waiting time, duration, or positive amount as a sum of independent gamma components.

Check Your Understanding

For each problem, check independence and parameterization before deciding whether the common-rate gamma-sum result applies.

  1. Independent \(U\sim\operatorname{Gamma}(2,5)\) and \(V\sim\operatorname{Gamma}(3,5)\) are measured in hours. Give the distribution, mean, and variance of \(U+V\). (Answer: \(\operatorname{Gamma}(5,5)\); mean \(1\) hour; variance \(0.2\) hours\(^2\).)
  2. Independent \(A\) with shape \(1.5\) and scale \(6\), and \(B\) with shape \(2.5\) and rate \(1/6\), are measured in days. Find the distribution, mean, and variance of \(A+B\). (Answer: shape \(4\), scale \(6\) (rate \(1/6\)); mean \(24\) days; variance \(144\) days\(^2\).)
  3. Four independent variables each have shape \(2\) and rate \(1/2\), in a common unit of time. Find the distribution, mean, and variance of their sum. (Answer: \(\operatorname{Gamma}(8,1/2)\); mean \(16\); variance \(32\), in the corresponding time units and squared time units.)
  4. Independent \(C\sim\operatorname{Gamma}(3,2)\) and \(D\sim\operatorname{Gamma}(2,3)\) are in days. State the MGF of \(C+D\), explain whether it is gamma, and calculate its mean and variance. (Answer: \(M(t)=(1-t/2)^{-3}(1-t/3)^{-2}\); it is not generally gamma because the rates differ; mean \(13/6\) days; variance \(35/36\) days\(^2\).)
  5. Independent \(E\), with shape \(2\) and scale \(1/4\), and \(F\), with shape \(3\) and rate \(4\), are measured in hours. Find the distribution, mean, and variance of \(E+F\). (Answer: \(\operatorname{Gamma}(5,4)\); mean \(5/4\) hours; variance \(5/16\) hours\(^2\).)
Clinical Biostats