Can any real function of irrational numbers be rational ? If possible, please give examples. Special case $ e^ {\pi i } = -1 $ seems to restrict solutions entirely to complex numbers. The question is right now vague as I do not know how to exclude "obviously derived " examples.
-
Maybe more interesting to try to find a surjection $\mathbb{R}\setminus\mathbb{Q}\rightarrow\mathbb{Q}$. – catfish Nov 26 '15 at 20:22
-
On the opposite, can you find a continuous function that never maps an irrational to a rational, other than a rational fraction ? – Nov 26 '15 at 21:27
-
1@YvesDaoust $f(x)=|x|$? – Wojowu Nov 26 '15 at 21:45
-
@Wojowu: all piecewise functional inverses of rational fractions with rational coefficients never map an irrational to a rational. $|x|$ is such a function. – Nov 26 '15 at 22:51
8 Answers
Sure. Choose any constant function $f : \mathbb R \setminus \mathbb Q \to \mathbb Q$, for example
$$f(x) = 1 \quad\text{ for all } x \in \mathbb R \setminus \mathbb Q$$
If this answer seems flippant, you may want to sharpen the question.

- 26,524
-
For kicks, define it as conways base 13 function everywhere else. – Christopher King Nov 26 '15 at 22:50
You can construct required function from any real function, rounding the result to finite number of decimals.

- 530
What about $f(x)=x^2$? One has $f(\sqrt2)=2$.

- 50,470
- 4
- 42
- 77
-
-
-
More generally, all algebraic numbers evaluate to $0$ for some polynomial function. – Nov 26 '15 at 21:06
-
@YvesDaoust, what you say is ambiguous (in English!). Better to say, “Every algebraic number evaluates to $0$ for some polynomial function”. – Lubin Nov 26 '15 at 22:04
-
A well-known example.
Is $m:=\sqrt{2}^{\sqrt{2}}$ rational? If yes, that is your answer.
If no, then $m^\sqrt{2}$ is your answer: $m$ and $\sqrt{2}$ are irrational, but $$ m^\sqrt{2} = \left(\sqrt{2}^\sqrt{2}\right)^\sqrt{2} =\sqrt{2}^{(\sqrt{2}\cdot\sqrt{2})} = \sqrt{2}^2 = 2 $$ is rational.

- 111,679
I don’t understand your question, since it seems to be insufficiently quantified. Do you mean, “Is there a function that takes every irrational number to a rational?”? Or do you mean, “Given an irrational number, is there a function that takes it to a rational image?”? Your example seems to support the second interpretation, in which case I’d suggest the function $f(x)=x/a$, if your given irrational number is $a$.
And you didn’t say what kind of function you were allowing. Any continuous function? Analytic? I can suggest all manner of discontinuous functions that take irrationals to rationals, beyond of course the ultimate in continuity, the constant functions.

- 62,818
-
I meant a situation about any function of rationals mapped from independent irrational variable numbers, – Narasimham Nov 27 '15 at 09:12
According to a famous theorem about trascendental numbers for all $\alpha$ real algebraic with $1\ne\alpha\ne0$ the number $\ln \alpha$ is trascendental. Consider the function $f(x)=e^x$ which is a bijection of $\mathbb R$ onto $]0,\infty[$; take now un $r\in$ $\mathbb Q^+ $, for instance $r=7$; there exists x such that $f(x)=7$ but $f(x)=e^x=7\iff x=\ln 7$ hence $x$ is a trascendental number whose image by $f$ is rational.
You have this way infinitely many rational $r$ such that if $x=\ln r$ then $f(x)=r$ where x is irrational (it is trascendental indeed).

- 29,594
-
Is the theorem that you mention a particular case of the Lindemann-Weierstrass theorem? – Alex M. Sep 23 '16 at 21:25
Several.
f(x) = x - x = 0
f(x) = x / x = 1, for x in R - {0}
f(x) = round(x, 5)
, where round() rounds a number to the specified quantity of decimal places.
The Dirac delta.
f(x) =
1 if x in Q,
0 if x not in Q
f(x) =
The average of the first 10^6 digits of x (in base 10).
And so on...