Tutorials › Statistical Theory I - Probability and Distribution Theory › Gamma Densities and Rate-Scale Conversions

Uniform, Beta, and Gamma Laws · Tutorial 164 of 994

Gamma Densities and Rate-Scale Conversions

Learn to write, normalize, recognize, and convert Gamma densities in rate and scale form.

Beginner 9 min read

What You'll Learn

  • State the support and parameter restrictions for a Gamma density.
  • Normalize rate and scale forms using the gamma integral.
  • Convert a rate parameter to its equivalent scale parameter.
  • Recognize equivalent Gamma density formulas despite different parameterizations.
  • Check density constants and units in worked examples.

Why Gamma Densities Have Two Parameterizations

A Gamma distribution is described by a positive shape parameter and a second positive parameter that can be written either as a rate or as a scale. Both descriptions give the same family of probability laws, but the formulas look different. Converting correctly matters because a rate multiplies the variable in the exponential, whereas a scale divides it.

The normalization rests on the gamma integral, which was defined earlier in the course. For \(a>0\), it is

$$ \Gamma(a)=\int_0^\infty u^{a-1}e^{-u}\,du. $$

The integral is finite and positive for \(a>0\). Its role here is to supply the constant that makes a Gamma density integrate to one.

Rate and Scale Definitions

Definition: Let \(\alpha>0\) and \(\beta>0\). The Gamma distribution with shape \(\alpha\) and rate \(\beta\), written here as Gamma\((\alpha,\beta)\) in rate form, has density $$ f(x)=\frac{\beta^\alpha}{\Gamma(\alpha)}x^{\alpha-1}e^{-\beta x},\qquad x>0, $$ and \(f(x)=0\) for \(x\leq 0\).
Definition: Let \(\alpha>0\) and \(\theta>0\). The Gamma distribution with shape \(\alpha\) and scale \(\theta\) has density $$ f(x)=\frac{1}{\Gamma(\alpha)\theta^\alpha}x^{\alpha-1}e^{-x/\theta},\qquad x>0, $$ and \(f(x)=0\) for \(x\leq 0\).

In both definitions, \(\alpha\) is dimensionless. If \(X\) has units such as hours, the rate \(\beta\) has units of inverse hours, while the scale \(\theta\) has units of hours. This matches the exponential terms: \(\beta x\) and \(x/\theta\) are dimensionless. The parameter names alone do not determine which formula is being used, so state explicitly whether the second parameter is a rate or a scale.

Why the Normalizing Constant Works

The central calculation is a change of variable in the gamma integral. It gives the integral of the unnormalized Gamma kernel for any positive rate. Once that calculation is established, normalization of both parameterizations follows.

Theorem: For \(\alpha>0\) and \(c>0\), $$ \int_0^\infty x^{\alpha-1}e^{-cx}\,dx=\frac{\Gamma(\alpha)}{c^\alpha}. $$ Consequently, the rate-form and scale-form formulas above are probability densities for their stated parameter ranges.

Proof. Make the substitution \(u=cx\). Since \(c>0\), this maps \(x\in(0,\infty)\) onto \(u\in(0,\infty)\), with \(x=u/c\) and \(dx=du/c\). Therefore,

$$ \begin{aligned} \int_0^\infty x^{\alpha-1}e^{-cx}\,dx &=\int_0^\infty \left(\frac{u}{c}\right)^{\alpha-1}e^{-u}\frac{du}{c}\\ &=\frac{1}{c^\alpha}\int_0^\infty u^{\alpha-1}e^{-u}\,du\\ &=\frac{\Gamma(\alpha)}{c^\alpha}. \end{aligned} $$

The integrand is nonnegative and the gamma integral is finite for \(\alpha>0\), so the substitution applies to this improper integral. Taking \(c=\beta\), the rate-form density has total integral

$$ \int_0^\infty \frac{\beta^\alpha}{\Gamma(\alpha)}x^{\alpha-1}e^{-\beta x}\,dx =\frac{\beta^\alpha}{\Gamma(\alpha)}\frac{\Gamma(\alpha)}{\beta^\alpha}=1. $$

For the scale form, take \(c=1/\theta\). Its total integral is

$$ \int_0^\infty \frac{1}{\Gamma(\alpha)\theta^\alpha}x^{\alpha-1}e^{-x/\theta}\,dx =\frac{1}{\Gamma(\alpha)\theta^\alpha} \frac{\Gamma(\alpha)}{(1/\theta)^\alpha}=1. $$

Both formulas are nonnegative on their support and zero off it. Having total integral one, each is a probability density. \(\square\)

Converting Rate and Scale Without Changing the Law

To describe the same density in both forms, match the exponential terms. The rate form contains \(e^{-\beta x}\), and the scale form contains \(e^{-x/\theta}\). These agree for every \(x>0\) exactly when \(\beta=1/\theta\). Under that relationship, their constants also agree.

Theorem: For fixed \(\alpha>0\), Gamma shape \(\alpha\), rate \(\beta>0\) and Gamma shape \(\alpha\), scale \(\theta>0\) describe the same law when $$ \theta=\frac{1}{\beta} \qquad\text{or, equivalently,}\qquad \beta=\frac{1}{\theta}. $$

Proof. Substitute \(\beta=1/\theta\) into the rate-form density. Its coefficient and exponential become

$$ \frac{\beta^\alpha}{\Gamma(\alpha)} =\frac{1}{\Gamma(\alpha)\theta^\alpha}, \qquad e^{-\beta x}=e^{-x/\theta}. $$

The power \(x^{\alpha-1}\) and support \(x>0\) are unchanged, so the entire density is the scale-form density at every \(x\). Equal densities give equal probability laws. Reversing the relation gives \(\beta=1/\theta\). \(\square\)

This parameter conversion is not a transformation of the random variable: \(X\) itself is not being rescaled. It is a change in how the same density is written. In particular, replacing a rate by a scale without taking its reciprocal generally changes the law.

Worked Example: Convert a Rate of 2 to a Scale

Let \(X\) have shape \(\alpha=3\) and rate \(\beta=2\). Write its density, then express the same density using a scale parameter.

The gamma recurrence gives \(\Gamma(3)=2!=2\). Thus the rate-form coefficient is

$$ \frac{\beta^\alpha}{\Gamma(\alpha)} =\frac{2^3}{\Gamma(3)} =\frac{8}{2}=4. $$

The density is \(f(x)=4x^2e^{-2x}\) for \(x>0\), and is zero otherwise. The equivalent scale is the reciprocal of the rate:

$$ \theta=\frac{1}{\beta}=\frac{1}{2}. $$

In scale form the coefficient is

$$ \frac{1}{\Gamma(3)\theta^3} =\frac{1}{2(1/2)^3} =\frac{1}{2(1/8)} =4, $$

and the exponential term is \(e^{-x/\theta}=e^{-x/(1/2)}=e^{-2x}\). The scale formula therefore gives exactly \(4x^2e^{-2x}\), confirming that it describes the same law.

Worked Example: Write a Density from a Scale

Suppose \(X\) has shape \(\alpha=2\) and scale \(\theta=5\). Find its density in scale form and then in rate form.

Since \(\Gamma(2)=1\), the scale-form coefficient is

$$ \frac{1}{\Gamma(2)\theta^2} =\frac{1}{1\cdot 5^2} =\frac{1}{25}. $$

The scale-form density is \(f(x)=\frac{x}{25}e^{-x/5}\) for \(x>0\), and zero for \(x\leq 0\). The corresponding rate is

$$ \beta=\frac{1}{\theta}=\frac{1}{5}. $$

The rate-form coefficient is

$$ \frac{\beta^\alpha}{\Gamma(\alpha)} =\frac{(1/5)^2}{1} =\frac{1}{25}, $$

and \(e^{-\beta x}=e^{-x/5}\). So the rate-form density is again \(f(x)=\frac{x}{25}e^{-x/5}\) for \(x>0\). As a normalization check, the general integral formula gives

$$ \int_0^\infty \frac{x}{25}e^{-x/5}\,dx =\frac{1}{25}\frac{\Gamma(2)}{(1/5)^2} =\frac{1}{25}\cdot 25=1. $$

Worked Example: Recognize a Fractional Shape

Consider the proposed density

$$ f(x)=\frac{1}{24\sqrt{\pi}}x^{3/2}e^{-x/4},\qquad x>0, $$

with \(f(x)=0\) otherwise. Identify its shape and scale, express it in rate form, and check its normalizing constant.

The power of \(x\) is \(\alpha-1=3/2\), so \(\alpha=5/2\). The exponential term is \(e^{-x/\theta}\) with \(\theta=4\); equivalently, the rate is \(\beta=1/4\). Using the gamma recurrence and \(\Gamma(1/2)=\sqrt{\pi}\),

$$ \Gamma(5/2)=\frac{3}{2}\Gamma(3/2) =\frac{3}{2}\cdot\frac{1}{2}\Gamma(1/2) =\frac{3\sqrt{\pi}}{4}. $$

The scale-form coefficient is therefore

$$ \frac{1}{\Gamma(5/2)4^{5/2}} =\frac{1}{(3\sqrt{\pi}/4)\cdot 32} =\frac{1}{24\sqrt{\pi}}. $$

In rate form, the coefficient gives the same result:

$$ \frac{(1/4)^{5/2}}{\Gamma(5/2)} =\frac{1/32}{3\sqrt{\pi}/4} =\frac{1}{24\sqrt{\pi}}. $$

Thus the proposed formula has the required Gamma form. Its integral is one by the normalization result, since \(\alpha=5/2>0\) and \(\theta=4>0\).

Checks That Prevent Parameterization Errors

When reading or writing a Gamma density, identify the exponent before evaluating the coefficient. The power \(x^{\alpha-1}\) determines the shape, while the factor in the exponential identifies the rate or scale. Then check that the coefficient agrees with the same choice.

FormExponential termNormalizing coefficientConversion
Shape \(\alpha\), rate \(\beta\)\(e^{-\beta x}\)\(\beta^\alpha/\Gamma(\alpha)\)\(\theta=1/\beta\)
Shape \(\alpha\), scale \(\theta\)\(e^{-x/\theta}\)\(1/(\Gamma(\alpha)\theta^\alpha)\)\(\beta=1/\theta\)

A common mistake is to read \(e^{-\beta x}\) as though \(\beta\) were the scale, then write \(e^{-x/\beta}\) while leaving the coefficient unchanged. That substitution does not preserve the formula: it changes the exponential term, and the coefficient may no longer normalize it. The correction is to use the reciprocal conversion, \(\theta=1/\beta\), and recompute the coefficient in the chosen form.

Another useful check is dimensional. For a variable measured in hours, a rate must be measured in inverse hours and a scale in hours. If the proposed exponential contains a dimensional quantity rather than a dimensionless product or ratio, the parameter has probably been assigned the wrong interpretation.

Key takeaway: A Gamma density has shape \(\alpha>0\) and either rate \(\beta>0\) or scale \(\theta>0\). The rate and scale describe the same law precisely when \(\theta=1/\beta\); the gamma integral verifies that each corresponding formula integrates to one.

Check Your Understanding

Use the density formulas and gamma integral to answer these questions.

  1. Write the Gamma density with shape \(4\) and rate \(3\), including its support and normalizing coefficient.
  2. A Gamma density contains the exponential factor \(e^{-x/7}\). What is its scale, and what is its rate?
  3. For shape \(\alpha=2\) and rate \(\beta=4\), verify the normalizing constant using the rate integral formula.
  4. Explain why a Gamma shape of \(1/2\) is allowed, even though the shape is not a positive integer.
  5. A density is written with the factor \(e^{-5x}\). If it is rewritten in scale form, what scale must be used?