6

If $x \in [0, 1]$, what is $\text{P}(x\in \mathbb Q)$? In other words, what is the probability that $x$ is rational?

This is what I tried:

$$\begin{array}{rcl}\text{P}(x \in \mathbb Q) &=& \displaystyle \int^1_0 f(x)\,dx \end{array}$$

where

$$f(x) = \begin{cases}1, & x \in \mathbb Q\\0, & x\notin\mathbb Q\end{cases}$$

However, the function is not Riemann-integrable.

I want to try comparing the cardinalities of the rational set and the irrational set by using a one-to-one mapping between the two sets. But I don't have idea how I can do it. Can anyone give a hint?

Rodrigo de Azevedo
  • 18,977
  • 5
  • 36
  • 95
Max Wong
  • 539
  • 3
  • 14

3 Answers3

16

The function $f$ is indeed not Riemann-integrable, but it is Lebesgue-integrable. And its integral is $0$. Therefore, the answer is $0$. That is natural, since $\mathbb Q\cap[0,1]$ is countable, whereas $[0,1]$ is uncountable. It follows that there is no bijection between $\mathbb Q\cap[0,1]$ and $[0,1]\setminus\mathbb Q$.

cqfd
  • 11,466
  • 6
  • 19
  • 43
José Carlos Santos
  • 397,636
  • 215
  • 245
  • 423
  • What is the relation between a probability function and integration? – Cantor Oct 12 '19 at 17:23
  • 5
    Probability theory is very much connected to measure theory. An we can compute the measure of a set by computing the integral of its characteristic function. – José Carlos Santos Oct 12 '19 at 17:29
  • Thank you very much Dr. Santos. I'll inquire further on the subject. Can you recommend an article or book on the matter? – Cantor Oct 12 '19 at 17:31
  • 2
    I think that [this question](https://math.stackexchange.com/questions/1506416/probability-and-measure-theory) and its answers are a good starting point. – José Carlos Santos Oct 12 '19 at 17:35
6

This answer might miss the real goal, but is inspired by the tag "probability".


In your question it is not explicitly mentioned how probability $P$ is defined.

So actually the question: "what is the probability that $x$ is rational?" makes no sense in this context.

Your try indicates that you are thinking of uniform distribution on interval $[0,1]$ where: $$P(B):=\lambda(B\cap[0,1])$$ for every Borel set and $\lambda$ denotes the Lebesgue measure on the $\sigma$-algebra of Borel sets $B\subseteq\mathbb R$.

It is well known that $\lambda(\{x\})=0$ for any $x\in\mathbb R$ and consequently we have $\lambda(S)=\sum_{x\in S}\lambda(\{x\})=0$ for every countable set, and of course $\mathbb Q$ is countable.

So under uniform distribution on $[0,1]$ we have $P(\mathbb Q)=0$.

In probability theory Riemann-integrability is (as far as I know) not practicized.

Notation $P(x\in \mathbb Q)$ only makes sense if $x$ denotes a random variable here.

So your problem setting: "if $x\in[0,1]$ then what is $P(x\in\mathbb Q)$?" is not okay.

drhab
  • 141,227
  • 9
  • 70
  • 190
2

I want to try comparing the cardinalities of the rational set and the irrational set by using a one-to-one mapping between the two sets

You can't. The set of rationals is countable. The set of irrationals is uncountable (see Proof that the irrational numbers are uncountable). Cantor proved by diagonalization that such that mapping cannot exist.