# Density function of transformation /marginal distribution

1. Density function of random variable transformation

Given $$X$$ a real valued random variable with a density function $$f_X$$. Let $$g$$ be a continuous function.

Does this imply, that the random variable $$g(X)$$ has a density function? Or do I need more assumptions, for example that $$g$$ has an inverse function?

2. Density function of marginal distribution

Let $$\lambda(dx,dy)$$ be a Radon measure with a density function and $$D$$ is compact. Does this imply, that the marginal distribution $$\lambda(dx)=\int_D \lambda(dx,dy)dy$$ has a density function too?

If $$g$$ is a cosntant then $$g(X)$$ does not have a density. Even if you assume that $$g$$ has an inverse $$g(X)$$ need not have a density. For example if $$X$$ has uniform distribution and $$g$$ is a striclty increasing singular function then $$g(X)$$ does not have a density.
For the second part the answer is YES. $$m(A)=0$$ implies $$m_2(A\times \mathbb R)=0$$ where $$m_2$$ is two dimensional Lebesgue measure. This implies $$\lambda (A \times \mathbb R)=0$$ so the first marginal of $$\lambda$$ has an absolutely continuous distribution.