Is it true that there exist a continuous function f that for every algebraic number q , his image f(q) is a rational number?
Thank you for your answers
Is it true that there exist a continuous function f that for every algebraic number q , his image f(q) is a rational number?
Thank you for your answers
Yes -- there is even a strictly increasing continuous bijection $\mathbb R\to\mathbb R$ such that the image of the algebraic reals is exactly the rational numbers.
The key to this is that both the algebraic reals and the rational numbers are countable dense total orders without first or last element, and it is a general theorem that every such two sets are order-isomorphic. Since both sets are dense in $\mathbb R$, an isomorphism between them extends uniquely to a continuous function $\mathbb R\to\mathbb R$.
(Even better, every strictly increasing continuous bijection $\mathbb R\to\mathbb R$ can be uniformly approximated by such functions).
You can even do it with an entire function.
EDIT: Here's one way to construct an entire function that maps $\mathbb R$ to $\mathbb R$, $\mathbb A$ to $\mathbb Q[i]$, and is one-to-one on $\mathbb R$. Here $\mathbb A$ is the algebraic numbers (not necessarily real) and $\mathbb Q$ the rationals.
Start by fixing an enumeration $a_k$ of $\{z \in \mathbb A: \text{Im}(z) \ge 0\}$. The function will be of the form
$$ f(z) = z + \sum_{k=1}^\infty f_k(z)$$
where $f_j$ are chosen inductively so that, writing $F_j(z) = z + \sum_{k=1}^j f_k(z)$,
Given $f_k$ for $k < j$, we start with $$ h(z) = e^{-z^2} \prod_{k < j} (z - a_k)(z - \overline{a_k})$$ which satisfies (1) and (2).
If $\alpha_j \in \mathbb R$, then $h(\alpha_j) \in \mathbb R \backslash \{0\}$ and $F_{j-1}(\alpha_j) \in \mathbb R$. Since $h$ is bounded on $\{z: |z| \le j\}$ and $h'$ is bounded on $\mathbb R$, there is $\epsilon > 0$ such that (4) and (5) are true with $f_j (z) = t h(z)$ as long as $|t| < \epsilon$, and (3) will be true for a dense set of $t \in (-\epsilon, \epsilon)$.
If $\alpha_j \notin \mathbb R$, (3) is a bit more complicated. We therefore take $f_j(z) = (t + s z) h(z)$: there will still be $\epsilon > 0$ such that (4) and (5) hold for $(s,t) \in (-\epsilon, \epsilon)^2$, and for a dense set of such $(s,t)$ we will have (3).