If f is a continuous function from [0,1] to R, and f(q) is given for all rational q, is f(i) determined uniquely for all irrational i?

287 Views Asked by At

Let $f,g: [0,1] \to \mathbb{R}$ be two continuous functions such that $\forall x\in \mathbb{Q} \cap [0,1], f(x) = g(x)$.

Does it follow that f = g? In other words, is it true that $\forall x \in [0,1] \setminus \mathbb{Q}, f(x) = g(x)$?

To give context, I'm trying to prove that the set $A :=\{f:[0,1] \to \mathbb{R} | f$ is continuous function$\}$ is equinumerous with $\mathbb{R}$. I already know that the set $B :=\{ f:\mathbb{N} \to \mathbb{R} : f$ is a function$\}$ is equinumerous with $\mathbb{R}$. So if the f and g defined at the beginning are equal, then I can easily construct a bijection between A and B and I would be done.

2

There are 2 best solutions below

0
On

Yes, for an irrational number $q\in[0,1]$, let a sequence of rational numbers $(p_{n})\subseteq[0,1]$ such that $p_{n}\rightarrow q$, then $f(p_{n})=g(p_{n})\rightarrow f(q),g(q)$ by continuities of $f$ and $g$, then $f(q)=g(q)$.

1
On

Yes, they are the same. Fix an $\epsilon>0$. There is a corresponding $\delta>0$ with $$ |q-i|<\delta \implies|f(q)-f(i)|<\epsilon/2,|g(q)-g(i)|<\epsilon/2 $$ Suppose that we have some irrational $i$. Find a rational $q$ within $\delta$ of it by density, then $$ |f(q)-f(i)|+|g(q)-g(i)|<\epsilon\implies |g(i)-f(i)|<\epsilon $$ by the triangle inequality. Thus $f(i)=g(i)$.