Finding the probability density function of a square root of a sum

1.8k Views Asked by At

As an exam review question, I have two independently distributed random variables $X$ and $Y$ which are both $\text{Gamma} \sim (2,\frac{1}{2})$ distributed. How do I find the probability density function of the random variable $Z$, defined as $\sqrt{X+Y}$?

I'm not sure what the simplest approach to this question is, but my first thought was to use moment generating functions, to try and find the moment generating function of $Z$. However this doesn't seem to help much when it comes to determining the p.d.f. anyways. Am I thinking about this all wrong?

2

There are 2 best solutions below

0
On BEST ANSWER

The following solution might be a bit cumbersome, but it is rather straightforward. We make use of the ''change of variable'' formula, i.e. $$f_{U,V}(u,v) = f_{X,Y}(x(u,v),y(u,v))\vert J \vert$$ where $J$ denotes the determinant of the jacobian matrix. Set $$ U = \sqrt{X+Y},\quad V = X$$ We find that $$ X = V,\quad Y = U^2 - V$$ The jacobian determinant is easily calculated to be equal to $2U$. Since $X$ and $Y$ are independent, it follows from the above forumla that $$f_{U,V}(u,v) = f_{X,Y}(x,y)\cdot 2u = f_X(x)f_Y(y)\cdot 2u$$ The above calculations are formal; considering the domain we have that, since $x,y > 0$ for the gamma distribution, $u^2 > v > 0$. It follows that $$f_{U,V}(u,v) = \begin{cases} 32uv(u^2-v)e^{-2u^2}, \mbox{if } u^2>v>0 \\ 0, \mbox{otherwise} \end{cases}$$ The get our result, we integrate the above with respect to $v$: $$f_U(u) = 32ue^{-2u^2}\int_0^{u^2}(vu^2 - v^2)dv = \frac{16}{3}u^7e^{-2u^2}$$

0
On

It seems that the answer provided by Lionel Ricci assumes both $X$ and $Y$ are Gamma distributed with $\beta = \frac{1}{\theta} = \frac{1}{\frac{1}{2}} = 2$ and $\alpha = 2$. This leads to the joint distribution of $U$ and $V$ as $$f_{U,V}(u,v) = \begin{cases} \frac{2^2 v^{2-1} e^{-2v}}{\Gamma(2)} \frac{2^2 (u^2-v)^{2-1} e^{-2(u^2 - v)}}{\Gamma(2)}(2u), \mbox{if } u^2>v>0 \\ 0, \mbox{otherwise} \end{cases} =\begin{cases} 32uv(u^2-v)e^{-2u^2}, \mbox{if } u^2>v>0 \\ 0, \mbox{otherwise} \end{cases}$$, as stated in Ricci's answer.

However, depending on the source from which one gets their information, one might see $X\sim GAM(\theta, \kappa)$, with $f_X(x) = \frac{1}{\theta^{\kappa}\Gamma(\kappa)}x^{\kappa - 1}e^{-\frac{x}{\theta}}$. In this case, we see

$$f_{U,V}(u,v) = \begin{cases} [\frac{1}{\sqrt{2} \Gamma(\frac{1}{2})} v^{-1/2} e^{-v/2}] [\frac{1}{\sqrt{2} \Gamma(\frac{1}{2})} (u^2 - v)^{-1/2} \hspace{0.1cm} e^{-(u^2 - v)/2}] , \mbox{if } u^2>v>0 \\ 0, \mbox{otherwise} \end{cases}$$

$$= \begin{cases} \frac{1}{2\pi} (v(u^2 - v))^{-1/2} \hspace{0.1cm} e^{-u^2/2} \hspace{.1cm}, \mbox{if } u^2>v>0 \\ 0, \mbox{otherwise} \end{cases}$$

If we assume this joint distribution of $U,V$, then one may integrate over $V$ to find the marginal density of $U$:

$$ f_U(u) = \frac{2y e^{-y^2/2}}{\pi}\int_{0}^{\infty} \frac{dv}{2\sqrt{u^2 v( 1 -(\frac{\sqrt{v}}{u}})^2} $$

Substituting $z = \frac{\sqrt{v}}{u}$, we have $dz = \frac{1}{2u\sqrt{v}}dv $, which turns the above integral into

$$\frac{2ye^{-y^2/2}}{\pi}\int_{0}^{\infty} \frac{dz}{\sqrt{ 1 -z^2}} = \frac{2ye^{-y^2/2}}{\pi}(sin^{-1}(\frac{\sqrt{z}}{u}) \mid_0^{\infty} ) = \frac{2ye^{-y^2/2}}{\pi}(\frac{\pi}{2} - 0) = ye^{-y^2/2}, y >0$$