Does there exist a cont function $f$ : $\mathbb{R}$ $\rightarrow$$\mathbb{R}$ which takes irrational values at rational points and rational values at irrational points?
Asked
Active
Viewed 138 times
3
-
I get the feeling, no. And I suspect this is because of their density – Squirtle Dec 26 '13 at 08:36
1 Answers
2
No. Such a function is clearly not constant. Let $a$ and $b$ be numbers with $f(a)\ne f(b)$. Then $f(x)$ must take all values between $f(a)$ and $f(b)$ for $x$ between $a$ and $b$. But there are an uncountable number of irrational numbers between $f(a)$ and $f(b)$, and only a countable number of rational $x$ between $a$ and $b$.
Harald Hanche-Olsen
- 32,608
- 2
- 61
- 87
-
-
2@Squirtle: Such a function is clearly not constant in any case, even if "cont" means continuous. – Mårten W Dec 26 '13 at 08:49
-
I didn't say it was.... I agree with the response; however, this simply wasn't the question. – Squirtle Dec 26 '13 at 09:15
-
1@Squirtle It was the first step to observe that the function $f$ not constant. Then we show that such continuous function impossible because we can not map countable set of rational numbers from $(a,b)$ on to uncountable set of irrational numbers from $(f(a), f(b))$. – Nikita Evseev Dec 26 '13 at 11:15