X ∼ Exp(1) and Y ∼ uniform(0, 1) are independent. Compute $E(e^{-XY^2})$.
I am having trouble answering this question, I am not sure if I should take advantage of moment generating functions or multivariable LOTUS. I think multivariable law of the unconscious statistician would be easier, but I am unsure on how to derive the joint pdf.Any help would be greatly appreciated!
Alternatively, use moment-generating functions. We have $$\operatorname{E}[e^{-XY^2}] = \operatorname{E}[\operatorname{E}[e^{-XY^2} \mid Y]] = \operatorname{E}[M_X(-Y^2)] = \operatorname{E}\left[\frac{1}{1-(-Y^2)}\right] = \int_{y=0}^1 \frac{dy}{1+y^2} = \tan^{-1} 1 = \frac{\pi}{4},$$ where the MGF of $X$ is $M_X(t) = \operatorname{E}[e^{tX}] = \frac{1}{1-t}$.