Let $k$ be a non-zero natural number and $f:\mathbb{R} \to \mathbb{R}$ be a monotonic function, such that $f(a+b\sqrt{2})=(a+b\sqrt{2})^{2k+1}, \forall a,b \in \mathbb{Z}$. Find $f$.
I found that $f$ has to be increasing and then I tried to work with an auxiliary function like $g(x)=f(x)-x^{2k+1}$, trying to prove that $f(x)=x^{2k+1}$ is the only solution, but I didn't succeed.
$X=\{a+b\sqrt2 \mid a,b \in \Bbb Z\}$ is dense in $\Bbb R$.
For any $x \in \Bbb R$, construct a sequence $u_n$ approaching $x$ from above, with $u_n \in X$ for each $n$; construct a sequence $d_n$ approaching $x$ from below, with $d_n \in X$ for each $n$. Since $f(x) \le f(u_n)$ for each $n$, we have $f(x) \le \inf f(u_n) = \inf (u_n)^{2k+1} = x^{2k+1}$. Since $f(x) \ge f(d_n)$ for each $n$, we have $f(x) \ge \sup f(d_n) = \sup (d_n)^{2k+1} = x^{2k+1}$. Therefore, $f(x) = x^{2k+1}$.