# Marginal PDF from joint PDF by integrating - help with integral

I'm trying to find the marginal PDF w.r.t. X for

f(x,y) = $(1/2\pi)e^{(-1/2)(x^2/4+4y^2)}$

I believe that to do this we integrate that joint PDF above from -$\infty$ to $\infty$ with respect to the other variable, Y. I can't figure out how to do this integral. The advice I received was that we can find a $\mu$ in terms of x and find a $\sigma$ so that the integrand becomes a normal pdf with respect to y, which can be integrated.

First, I've bashed my head against the wall for a while now and can't find any $\mu$ that makes this the case: $(y-\mu)^2 = y^2 -2y\mu + \mu^2$ and we don't have a $yx$ term in the original expression that can turn into $-2y\mu$ with a substitution.

Second, I don't see how getting this to be a normal PDF helps. Integrating the normal PDF from -infinity to infinity should be 1 because of normalization, but the marginal PDF is not just 1 everywhere.

I'm clearly misunderstanding something big here, any help on the problem is appreciated.

• There are standard tricks for integrating $e^{-2y^2}$. Yes the integral of the normal pdf is 1, but you don't exactly have that. Also your random variables are independent, they are actually independently normal. Try and find the mean and variance of each and see that $f(x,y)= f_X(x) f_Y(y)$. Nov 15 '17 at 5:06
• I don't see how they could be independent. This is the joint PDF: link. f(x,y) takes on a particular value along an ellipse, which means the chance that y=1,say, depends on what x is (I think). Also I'm not integrating e^(-2y^2), but a much more complicated mess - I still don't know how to do the integral. Nov 15 '17 at 5:12
• You see in the link the contour lines are circle, and as jdods mentioned above you can factorize the joint pdf into two parts, in which the two parts are solely depends on $x$ and $y$ respectively, but not other. By matching the mean and variance in side the exponent, you can tell the marginal distribution of $X$.
– BGM
Nov 15 '17 at 7:33

Note that I believe you have a typo regarding the $2\pi$ in the denominator, and your joint pdf should be: $$f(x,y) = 1/(2\pi)e^{(-1/2)(x^2/4+4y^2)}$$
$$f(x,y) = \frac{1}{2\pi}e^{(-1/2)(x^2/4+4y^2)}=\frac{1}{\sqrt{2\pi\cdot 4}}e^{-\frac{x^2}{2\cdot 4}}\cdot \frac{1}{\sqrt{2\pi\cdot\frac14}}e^{-\frac{y^2}{2\cdot\frac14}}$$
So $X$ is normal with mean zero and variance $\sigma_X^2=4$, and $Y$ is normal with mean zero and variance $\sigma_Y^2=\frac14$.
Since $f(x,y)=f_X(x)\cdot f_Y(y)$, this tells us that $X$ and $Y$ are independent.