# How do gamma distributions add and what would that model?

Density distributions add by convolution, and the result is also a density distribution. So writing this in the time domain, w.l.o.g., the question becomes how do we take a faster gamma distribution:

${\mathrm{GD_{fast}}}\left(\mathrm{a} ;\ \mathrm{b}; \tau \right)=\left\{\begin{array}{cc}\hfill \frac{{\mathrm{b}}^{\mathrm{a}}}{\Gamma \left(\mathrm{a}\right)}{\tau}^{\mathrm{a}-1}{e}^{-\mathrm{b}\kern0.1em \tau },\hfill & \hfill \tau\ \ge\ 0\hfill \\ {}\hfill \kern2.75em 0\kern1.5em ,\hfill & \hfill \tau <0\hfill \end{array}\right.,$

where $\tau$ is time, and add it to a slower one:

${\mathrm{GD}}_{\mathrm{slow}}\left(\alpha; \beta; \tau \right)=\left\{\begin{array}{cc}\hfill \frac{\beta^{\kern0.1em \alpha }}{\Gamma \left(\alpha \right)}{\tau}^{\alpha -1}{e}^{-\beta\;\tau },\hfill & \hfill \tau \ge 0\hfill \\ {}\hfill \kern3em 0\kern1.2em ,\hfill & \hfill \kern1.4em \tau <0\hfill \end{array}\right.,$

The notation here assigns the rate scalar $\beta=\frac{1}{\theta}$, where $\theta$ is the time scalar. Both parameterizations are in common use. Thus, when we require $b>\beta$, we are requiring that $\text{GD(b)}$ to be faster (e.g., lighter right-tailed) than $\text{GD}(\beta)$. The solution is well known for the simpler case when $\mathrm{b}=\beta$; it is also a gamma distribution. But what we (Q1) want is a general closed form convolution solution for the sum of two gamma distributions: a gamma distribution convolution of the type

$\mathrm{GDC}\left(\mathrm{a}\kern0.1em ,\mathrm{b},\alpha, \beta; \tau \right)={\mathrm{GD_{fast}}}\left(\mathrm{a},\mathrm{b};\;\tau \right)\otimes {\mathrm{GD_{slow}}}\left(\alpha, \beta; \tau \right),$

Finally, we (Q2) want some indication of whether this can be used to form reasonable models, and whether or not it has found practical applications.

• @Glen_b I looked, and it was not, not in closed form. As a recursion, yes, and approximate answers, yes. And, it was whuber who answered it, and his comment is below the answer and his comment below the answer refers to this post stats.stackexchange.com/questions/72479/…
– Carl
Dec 21, 2016 at 2:53

A procedural solution for $$n$$ tuple convolution is given here.

Q1: The two gamma distribution convolution (GDC) in closed form is only given here

$$\mathrm{G}\mathrm{D}\mathrm{C}\left(\mathrm{a}\kern0.1em ,\mathrm{b}\kern0.1em ,\alpha, \beta; \tau \right)=\left\{\begin{array}{cc}\hfill \frac{{\mathrm{b}}^{\mathrm{a}}{\beta}^{\alpha }}{\Gamma \left(\mathrm{a}+\alpha \right)}{e}^{-\mathrm{b}\tau }{\tau^{\mathrm{a}+\alpha-1}}{}_1F_1\left[\alpha, \mathrm{a}+\alpha, \left(\mathrm{b}-\beta \right)\tau \right],\hfill & \hfill \tau >0\hfill \\ {}\hfill \kern2em 0\kern6.6em ,\hfill \kern5.4em \tau \kern0.30em \le \kern0.30em 0\hfill \end{array}\right.,$$

which is a density function consisting of a gamma variate multiplied by $$_1 F _1(A; B; Z)$$, where the latter is a confluent hypergeometric function of the first kind, and see end note below. For $$\text{b} = β$$, this equation reduces to the well known result $$\text{iff b}=\beta\text{;}\;{\mathrm{GD}}\left(\mathrm{a},\mathrm{b};\;\tau \right)\otimes {\mathrm{GD}}\left(\alpha, \text{b}; \tau \right)=\text{GD}(\text{a}+α,\text{b} ;τ)$$

An even more general solution with weights is given in Eq. (2) here. Furthermore, that reference lists a non-closed form solution for the sum of $$n$$ weighted gamma distributions.

Q2: No applications for the GDC have been posted on CV prior to this. Most recently, the GDC has been used in medicine for the first time to model radioactive tracer activity in time in the thyroid gland. GDC models have also been applied for ecological water storage I/O, waiting times in queuing theory, and in the evaluation of aggregate economic risk of portfolios.

End note: The fast computation of the confluent hypergeometric function of the first kind uses the Euler's integral identity $${}_1F_1\left(A;B;Z\right)=\frac{\Gamma \left(B\right)}{\Gamma \left(B-A\right)\Gamma \left(\mathrm{A}\right)}{\displaystyle {\int}_0^1{\mathrm{e}}^{Z\;u}{u}^{A-1}{\left(1-u\right)}^{B-A-1}du}$$.