How to find marginal distribution from joint distribution with multi-variable dependence? One of the problems in my textbook is posed as follows. A two-dimensional stochastic continuous vector has the following density function:
$$
f_{X,Y}(x,y)=
\begin{cases}
15xy^2 & \text{if 0 < x < 1 and 0 < y < x}\\
0 & \text{otherwise}\\
\end{cases}
$$
Show that the marginal density functions $f_X$ and $f_Y$ are:
$$
f_{X}(x)=
\begin{cases}
5x^4 & \text{if 0 < x < 1}\\
0 & \text{otherwise}\\
\end{cases}
$$
$$
f_{Y}(y)=
\begin{cases}
\scriptsize{\frac{15}{2}}\normalsize y^2(1-y^2) & \text{if 0 < y < 1}\\
0 & \text{otherwise}\\
\end{cases}
$$
I understand how the density function $f_X$ is calculated, by integrating $f_{X,Y}$ from $0$ to $x$ with respect to $y$. I'm however totally lost on $f_Y$, where is the $(1-y^2)$ coming from? If I integrate from $0$ to $1$ with respect to $x$ then I only get $\scriptsize{\frac{15}{2}}\normalsize y^2$, and why is the range $0 < y < 1$?
I've graphed the support for $X,Y$, all values where $f_{X,Y}>0$ are colored blue:

 A: As you correctly pointed out in your question $f_{Y}(y)$ is calculated by integrating the joint density, $f_{X,Y}(x,y)$ with respect to X. The critical part here is identifying the area on which you integrate. You have already clearly showed graphically the support of the joint distribution function $f_{X,Y}(x,y)$. So, now, you can note that the range of $X$ in the shaded region is from $X=y$ to $X=1$ (i.e. graphically, you can visualize horizontal lines, parallel to the x-axis,  going from the diagonal line $Y=X$ to the vertical line at $X=1$).
Thus, the lower and upper limits of the integration are going to be $X=y$ and $X=1$. Thus, the solution to the problem is as follows:
$$f_{Y}(y)= \int_{y}^{1} f_{X,Y}(x,y) dx= \int_{y}^{1} 15xy^{2} dx=15y^{2}\int_{y}^{1} x dx=15y^{2}\left(\frac{1}{2}x^2\Big|_y^1\right)\\=\frac{15}{2}y^2(1-y^2).
$$
A: The reason for integrating for $f_{XY}(x,y)\,dx$ from the range $y$ to $1$ is that it gives you the $(1-y^2)$ term.
The marginal distribution is when for any constant value of fixed $y$ we sum over all the possible values of $x.$
So here if we fix $y,$ say, at $0.6,$ then $f_{XY}(x,y)\,dx$ has to be integrated for all the values of $x$ in $(-\infty, +\infty).$ But for this case it must also satisfy two more bounding constraints on the random variable $X.$ $X$ should be such that it's greater than $Y$ only when the joint pdf is defined (see your definition of the joint pdf).
Now here I took $0.6$ as the fixed $Y.$
I get
$$f_Y(0.6) = \int_{0.6}^1 f_{XY}(x,y)\,dx.$$
So if we want for any arbitrary value of $y$ then we integrate $x$ from limits $y$ to $1.$
I hope that helps
Cheers
