# What is the distribution of the ratio between independent Beta and Gamma random variables?

What would be the distribution of the following equation:

$$y = \frac{a}{(a+d)^2}$$

where $a, d$ $\sim$ $\Gamma(M,c)$. Additionally, $a$ and $d$ are independent random variables.

• Your title doesn't match the body of your question -- $y$ is not the ratio of independent chi-square variates. Dec 29 '16 at 8:27
• @Glen_b, could you give me better title,please? Dec 29 '16 at 8:40
• Can you say how the calculation arises? That might lead to a better description. Dec 29 '16 at 9:20

For independent $a, d\sim\operatorname{\Gamma}(M,c)$, a remarkable result is that $U=a+d$ and $V=a/(a+d)$ are also independent. In addition, $U\sim\operatorname{\Gamma}(2M, c)$, $V\sim\mathrm{B}(M,M)$. See for example Ch.25, Sec. 2 of Johnson, Kotz, and Balakrishnan's Continuous Univariate Distributions, Volume 2 for some details.

Now this says $$Y=\frac{a}{(a+d)^2}=\frac{1}{a+d}\frac{a}{a+d}=\frac{V}{U}$$ is a ratio between independent Gamma and Beta random variables. Nadarajah and Kotz's On the Product and Ratio of Gamma and Beta Random Variables and Nadarajah's The Gamma Beta Ratio Distribution have discussed this distribution thoroughly.

EDIT: Using the CDFs and PDFs given in the articles mentioned above, we can derive (simplified with Wolfram Alpha) the CDF of $Y$ as: $$F_Y(y) = 1-\frac{\Gamma(3M)}{2(cy)^{2M}\Gamma(M+1)\Gamma(4M)}{}_2F_2\left(2M, 3M; 2M+1,4M; -\frac{1}{cy}\right),$$ and the PDF of $Y$ as: $$f_Y(y)=\frac{\Gamma(3M)}{y(cy)^{2M}\Gamma(M)\Gamma(4M)}{}_1F_1\left(3M; 4M; -\frac{1}{cy}\right)$$ where ${}_1F_1$ and ${}_2F_2$ are the generalized hyper-geometric functions. These expressions are in accordance with @wolfies's result.

• So maybe the title should be "What is the distribution of the ratio between independent Gamma and Beta random variables?". Dec 29 '16 at 13:43
• What a cool answer Dec 29 '16 at 14:58
• @Francis, is there a specific name for such distribution? Thanks! Dec 29 '16 at 19:56
• @FelipeAugustodeFigueiredo: The papers simply called $U/V$ as gamma beta ratio distribution, so I guess $Y$ can be called beta gamma ratio distribution. Dec 29 '16 at 20:01
• @Francis, would the moment for the so called beta gamma ratio distribution be the same as the one given in projecteuclid.org/download/pdfview_1/euclid.bjps/1327328084 for the gamma beta ratio distribution, see page 187, section 6? Dec 29 '16 at 21:52

Francis has provided the definitive elegant solution. Following his beautiful method, it seems possible to produce a somewhat simpler form for the pdf.

In particular, following Francis' elegant solution, let $$V \sim \text{Beta}(m,m)$$ with pdf $$f(v)$$:

.. and let $$U \sim \text{Gamma}(2m, c)$$ where $$U$$ is independent of $$V$$, and let $$Z = \frac1U$$, so that $$Z \sim \text{InverseGamma}(2m,c)$$ with pdf $$g(z)$$:

Then the desired pdf of $$Y = \frac{V}{U} = V Z$$, say $$h(y)$$, can be found with:

where I am using the TransformProduct function from the mathStatica package for Mathematica to automate the nitty gritties.

So does it work?

Here is a quick Monte Carlo check of the:

• simulated pdf of $$Y = \frac{A}{(A+D)^2}$$ (generated from $$A$$ and $$D$$) (blue squiggly)

• compared to the exact theoretical pdf $$h(y)$$ (dashed red) derived above:

when parameter $$m = 4$$ and $$c=3.01$$. Looks fine.

• could you have a look at the following question, please? stats.stackexchange.com/questions/253764/…. I think you might possibly help with that. Thanks! Dec 30 '16 at 12:01
• No mention of the conflict of interest you have in advocating the use of said for-profit package? Funny how you tend to "forget" this...
– Did
Jan 1 '17 at 11:19