# Marginal probability densities

I am trying to work on the following problem, and can't seem to quite figure out how to work out the marginal probability density functions:

Given

$f(x,y) = \begin{cases} k & 0 \leq x \leq 2\,,\quad 0 \leq y \leq 1\,,\quad 2y \leq x \\[1mm] 0 & \mbox{otherwise} \end{cases}$

I am asked to find $k$ so that $f(x,y)$ is a probability density function. I worked it out to $k=1$, but then I'm asked to find the marginal probability densities for $x$ and $y$ and I'm hitting a bit of a roadblock.

In order to find the x marginal, I integrate against $y$:

$f_x = \int_{o}^{1}dy = \dots = 1$

That's interesting - the marginal probability of $x$ is 1? Well, maybe. Let's move on.

In order to find the y marginal, I integrate against $x$:

$f_y = \int_{o}^{2}dx = \dots = 2$

Now clearly this is wrong. I am 99% sure that my calculation of $k$ is correct, and that the issue is that my integration limits are borked.

If someone could explain how to find the marginal here, I'd appreciate it.

Hint: you forgot the third condition $2y<x$ and its impact on the marginal integrals' bounds.
$$f_X(x) ~=~ \int_0^{\min\{x/2,1\}}\mathbf 1_{0\leq x\leq 2}\operatorname d y~=~\frac x 2\cdotp\mathbf 1_{0\leq x\leq 2}$$
• So, I would integrate from $2y$ to $2$, and get $2(1-y)$? for the y-marginal? – ConfusedMathStudent Nov 1 '16 at 2:45
• @ConfusedMathStudent Yes, $\int_{2y}^2\operatorname d x=2-2y$ But don't forget to note where the support lies. $0\leq y\leq 1$ – Graham Kemp Nov 1 '16 at 2:47