I have a random vector (X,Y) uniformly distributed in the region defined by the following functions:
- y = 1 + x
- y = -1 + x
- y = 1 - x
- y = -1 - x
I need to answer the following questions, but I really don't know how to proceed:
- What is the joint density function of the vector?
- The marginal density function of X is fX(x) = 1 - |x| when -1 < x < 1. True or false?
- P(X > 0, Y > 0) = 1/8. True or false?
- Are the variables X and Y independent?
I'm stuck and quite panicking. Any and all help is appreciated!
The first thing to always do in any problem is to graph it and take a look at whats going on! So lets look at the region that the vector is defined in:
We can see that the region is this square in the middle of side length $ \sqrt{2}$ and hence area $2.$ If you look closely you can think of this region instead of the 4 linear functions but you can combine the two bottom lines/sides of the square as $y = |x| -1 $ and the top two sides as $y = 1 - |x| $ Hence the region can bee seen as $R = \{ (x,y) \in \mathbb{R} : |x| -1 < y < 1 - |x| \} $
The joint probability density function of a uniformly distributed vector is $\frac{1}{Area} = \frac{1}{2}. $ (This is identically analogous to the density of uniform random variable on an interval $(a,b)$ which is simply $\frac{1}{Length} = \frac{1}{b-a} $ )
For the marginal density of X we simply "integrate out" Y on its range from the joint density. As shown in our alternative deffiniton of the region R we have: $|x| - 1 < y < 1 - |x|$ Hence marginal of $X$ = $f_X = \int_{|x| - 1}^{1 - |x|} f_{X,Y}(x,y) dy$ (Where $ f_{X,Y}(x,y)$ is the joint density = $ \frac{1}{2}$ ) Hence: $f_X = \int_{|x| - 1}^{1 - |x|} \frac{1}{2} dy =[ \frac{y}{2} ]_{|x| - 1}^{1-|x|} = 1 - |x| $
So the answer is true.
Lets look at our picture for this one, no real need for numbers. The region where both x and y are greater than zero is that little top right hand right triangle. If we split the square (our total sample space) into the four triangles it makes with the x and y axis we see that there are four of equal area and only in one of them do we have x and y both positive. Hence $P(X > 0 , Y > 0) = \frac{1}{4}$
I will provide two ways of doing this. First without numbers then with. The answer is quite clearly no, they are not independent as the value of $X$ quite clearly impacts $Y$. For example if we were told $X < -0.8 $ then we know for sure $Y$ cannot be greater than $0.9 $ As in the region of our sample space, the square, that $X < - 0.8 $ ,this little tiny wedge on the left, the maximum value of $Y$ is $0.2$ However if we were told that $ <-0.3<X<0.3$, this thin arrow like shape in the middle, then $Y$ can definitely be greater than $0.9$.
A more formal and rigorous proof with numbers would be to show that $f_X(x) \cdot f_Y(y) \not = f_{X,Y}(x,y) $ As the product of the marginal density is the joint density if and only if they are independent. We worked out before that $f_X(x) = 1 - |x| $ and via symmetry of this problem we have $f_Y(y) = 1 - |y| $ Checking $f_X(x) \cdot f_Y(y)$ yields $( 1 - |x| - |y| + |x||y| ) $ which is quite clearly not $\frac{1}{2} $ (the joint density of $X,Y$) hence they are not independent
I really hope this helped, if you would like any further explanation please ask away! Also for what it is worth I have been studying these topics for a while and this question is definitely very challenging so don't beat yourself up at all!