# Are the domain of the density of a random variable and the domain of that random variable itself same, in the context of normal distribution?

The domain of a random variable is a sample space, which is interpreted as the set of possible outcomes of a random phenomenon.

This claim is conceptual.

Let's use $$\Omega_1$$ to denote the domain of the density of a random variable.

Let's use $$\Omega_2$$ to denote the domain (the sample space) of the r.v. itself.

In particular, consider a random variable that follows the normal probability distribution.

in this case, are $$\Omega_1$$ and $$\Omega_2$$ the same set, that is $$(-\infty, \infty)$$, Is it ?

## 2 Answers

You are using the word "domain" to mean two mathematically distinct concepts, and this is confusing you. Per your other (very similar) question asked around the same time, I believe what you are really interested in is the support of the distribution of the random variable.

To try to explain things more concretely, let us imagine using a random number generator to simulate a normal distribution. Assume the random number generator produces a uniformly random real number $$X$$ in $$[0,1]$$. Then you can apply a suitable function $$f\colon [0,1]\to\mathbb R$$ to $$X$$ to obtain a standard normal random variable. (If you want instructions of how to explicitly write down such a function, see https://en.wikipedia.org/wiki/Inverse_transform_sampling)

Now the incredible (or incredibly boring) insight of (formal) probability theory is that $$f$$ is the same thing as the standard normal random variable. In your notation, $$\Omega_2=[0,1]$$ is the sample space and $$f$$ is the random variable. But by the same token, I could have started on another domain, like saying $$Y$$ is uniformly random in $$[0,2]$$, and found a different function $$g$$, with the property that $$g(Y)$$ and $$f(X)$$ have the same distribution - standard normal in both cases. So we would have $$\Omega_2'=[0,2]$$. So $$\Omega_2$$ is not intrinsic to the standard normal distribution - it can be (almost) anything.

Now let's address $$\Omega_1$$. We all know the standard normal density is a constant times $$e^{-x^2/2}$$. Of course, it is a function from $$\mathbb R$$ to $$\mathbb R$$. But this does not really tell us anything about the standard normal density. The same is true for densities that are not supported on all of $$\mathbb R$$, like the exponential density, which is $$e^{-x}\cdot 1[x\geq 0].$$ This funny notation means that the density is a function, defined for all $$x\in\mathbb R$$, that happens to equal $$0$$ when $$x$$ is negative. (In particular, it is not continuous at $$x=0$$.) So in this case too, we can say that the domain of the density is all of $$\mathbb R$$. But the support is only $$[0,\infty)$$ - the set of positive real numbers. In the other question you asked, I gave a careful definition of the support. For the purposes of this question, you can think of it as just the set of $$x\in\mathbb R$$ for which the density is non-zero.

• Thanks for your comments. Why does f use [0,1] as its domain instead of $(-\infty, \infty)$, because the former is more easy and feasible? Commented Aug 3, 2019 at 7:28
• The point is that you can use any domain. On a computer, the "default" random number generators produce a uniform number between $0$ and $1$, because in many situations it is more convenient to work with numbers in a bounded range and then scale them instead of having unbounded numbers. But my point is that it really doesn't matter which domain is used - you can always map from one domain to another without affecting the distribution of the random variable. Commented Aug 3, 2019 at 7:43
• To be clear, a random variable is a function, and has a completely determined domain. However, there are many, many, many, random variables with the same distribution. Sometimes people are sloppy and refer to any two random variables with the same distribution as "being the same", even though this is technically incorrect since the sample spaces are different. But the point of probability is that any two random variables with the same distribution will give the same answers to probabilistic questions, even if the sample space and functions are different. Commented Aug 3, 2019 at 8:02
• Your answers are so informative, thanks! "The support is only $[0,\infty)$" in your last paragraph, is that for $e^{-x}\cdot 1[x\geq 0]$ other than the standard normal density, right? Commented Aug 3, 2019 at 8:54
• Yes, since the standard normal density is non-zero for all of $(-\infty,\infty)$ whereas the exponential density is non-zero only for $[0,\infty)$ Commented Aug 3, 2019 at 8:55

In practice the domain of a random variable is abstract and it rarely matters what exactly it looks like. In elementary probability theory we refer to it as the set of possible outcomes, but when we are being more honest about it, it is really just a probability space that does everything we want it to do. Only very rarely do we even need to check that such a probability space actually exists.

The domain of the CDF of a (real) random variable is $$\mathbb{R}$$, and the same is true of the density of the PDF if there is one.