Uniform distribution marginal density and conditional expectation

42 Views Asked by At

Let $X$ be uniform on $\left[0,1\right]$, and given $X$, let $Y$ be uniform on $\left[X^{2},X\right]$. Find the marginal density of $Y$ and find $E(X|Y)$. My attempt was $$f_{y|x}(y|x)=\begin{cases} \frac{1}{x-x^{2}}, \text{if $0\leq x^{2}\leq y\leq x\leq 1$}\\ 0,&\text{otherwise} \end{cases}$$ and $f_{y}(y)= \int_{-\infty}^{\infty} f(x,y) \,dx$ and $f(x,y)=f_{y|x}(y|x)\times f_{x}(x)$, where $$f_{x}(x)=\begin{cases} 1, & \text{if x $\in \left[0,1\right]$}\\ 0, &\text{otherwise} \end{cases}$$ Hence $$f(x,y)=\begin{cases} \frac{1}{x-x^{2}},& \text{if $0\leq x^{2}\leq y\leq x\leq 1$}\\ 0,&\text{otherwise} \end{cases}$$ Finally $f_{y}(y)= \int_{-\infty}^{\infty}\frac{1}{x-x^{2}} \,dx$ but there exists improperness the integral is undefined at $0$ and $1$ therefore I could not make progress.