Discrete and Continuous Random Variables and Associated Sample Spaces

1) I am aware that a continuous random variable cannot be obtained from a sample space that is countably infinite or finite. In other words, the sample space of an experiment has to be uncountably infinite in order for one to be able to assign a meaningful continuous random variable. But can one define a discrete random variable on an uncountably infinite sample space? Or does an uncountably infinite sample space only allow us to define a continuous random variable?

2) My second question is somewhat different and relates to continuous random variables specifically. Given a continuous random variable $X$ and a real-valued function $g$, $g(X)$ is a random variable. However, unlike the discrete case wherein functions of discrete random variables are inevitably discrete, this need not be the case for functions of continuous random variables. If $X$ is continuous, $g(X)$ can be continuous or discrete. I find this confusing because in order for us to define a continuous random variable $X$ to start with we need an uncountably infinite sample space. But given that uncountably infinite sample space how can one associate with it a discrete random variable $g(X)$? Finally, does one define a probability mass function for $g(X)$ if it turns out to be discrete?

• But then $g(X)$, the discrete random variable, would be associated with an uncountably infinite sample space, which you said is not possible. How do you explain that? – 0MW Jul 15 '18 at 12:09
• I’m also wondering, given an uncountably infinite sample space, if we define the degenerate random variable $X$ that takes a constant value (say 2) for all outcomes, is this a discrete or continuous random variable? – 0MW Jul 15 '18 at 12:19