Let $\displaystyle f: \mathbb{R} \longrightarrow \mathbb{R}$ be continuous and $\displaystyle f(x)=f(x+1)=f(x+\sqrt{2}),$ for all $\displaystyle x \in \mathbb{R}.$ Prove that $\displaystyle f$ is constant.
Source: Berkely Preliminary Exam
Let $\displaystyle f: \mathbb{R} \longrightarrow \mathbb{R}$ be continuous and $\displaystyle f(x)=f(x+1)=f(x+\sqrt{2}),$ for all $\displaystyle x \in \mathbb{R}.$ Prove that $\displaystyle f$ is constant.
Source: Berkely Preliminary Exam
$\displaystyle f(x)=f(x+1)$
Also,$\displaystyle f(x)=f(x+\sqrt{2})$
If T is periodic with period $\displaystyle 1$ and also periodic with period $\displaystyle \sqrt{2}$ then $\displaystyle \sqrt{2}$ must be an integral multiple of $\displaystyle 1$ which is impossible.
This means that $\displaystyle f(x)$ is periodic but its period is undefined.
The situation is similar to
$\displaystyle f(x)=c$
where $\displaystyle c$ is constant.Here $\displaystyle f(x)$ is periodic but its period is not defined.
Thus $\displaystyle f(x)$ may be a constant function.
But my solution lacks rigour.
We can say that $\displaystyle f $ is bounded and uniformly continuous. Maybe we can say that $\displaystyle f $ is a doubly periodic function (e.g. $\displaystyle f(z) = f(z+u) = f(z+v) $). And somehow use Liouville's theorem to show that it is constant? The imaginary parts would be $\displaystyle 0 $.
Or going from the first idea...if $\displaystyle f $ is bounded, then $\displaystyle |f(x)| \leq M $ for some $\displaystyle M>0 $ and for all $\displaystyle x \in \mathbb{R} $. So suppose for contradiction that $\displaystyle f $ was not constant. Then it is monotonic increasing or decreasing. But this contradicts the fact that $\displaystyle f $ is bounded. Hence $\displaystyle f $ is constant.
I think I have it.
$\displaystyle f(x)=f(x+1)$
$\displaystyle x+1=x+nT$,where $\displaystyle T$ is the fundamental period or the smallest period and $\displaystyle n$ is any positive integer.
$\displaystyle T=\frac{1}{n}$
Similarly,$\displaystyle f(x)=f(x+\sqrt 2)$ results in
$\displaystyle x+\sqrt 2=x+mT$,where $\displaystyle m$ is a positive integer and $\displaystyle T$ is the fundamental period.
$\displaystyle T=\frac{\sqrt 2}{m}$
$\displaystyle \frac{1}{n}=\frac{\sqrt 2}{m}$
$\displaystyle m=\sqrt 2 n$
which is impossible since m and n are integers.Therefore $\displaystyle T$ is undefined.But since the function repeats itself it can only be constant
that's not always true. for example consider the function $\displaystyle f(x)=\begin{cases} 1 & x \in \mathbb{Q} \\ 0 & x \notin \mathbb{Q} \end{cases}.$ here we have $\displaystyle f(x+r)=f(x), \ \forall x \in \mathbb{R}, \ \forall r \in \mathbb{Q}.$ of course, $\displaystyle f$ is not continuous!
my point is that i don't see how "continuity" of $\displaystyle f$ was used in your solution!
Consider the set $\displaystyle S=\{a+b\sqrt{2}\: : \: a,b \in \mathbb{Z}\}$. This set is dense in $\displaystyle \mathbb{R}$, and $\displaystyle f$ must be equal to $\displaystyle f(0)$ everywhere in $\displaystyle S$. Since $\displaystyle f$ is continuous and $\displaystyle S$ is dense, $\displaystyle f(x)=f(0)$ for all real $\displaystyle x$ and $\displaystyle f$ is constant.
To see that $\displaystyle S$ is dense in $\displaystyle \mathbb{R}$, notice that it is a subgroup of $\displaystyle \mathbb{R}$, hence it suffices to prove that it is dense on some interval; we choose the interval $\displaystyle [0,1]$. Consider $\displaystyle J=\{s-\lfloor s\rfloor\: : \: s\in S\}$; this is a subset of $\displaystyle S \cap [0,1]$. Moreover if $\displaystyle s_1-\lfloor s_1\rfloor = s_2-\lfloor s_2\rfloor$ then $\displaystyle s_1=s_2$ because $\displaystyle \sqrt{2}$ is irrational. Hence there are infinitely many points of $\displaystyle S$ in $\displaystyle [0,1]$, hence two of them are arbitrarily close; but then since $\displaystyle S$ is closed under addition, $\displaystyle S$ is dense in $\displaystyle \mathbb{R}$, Q.E.D.
this is not true! counter-examples: $\displaystyle s_1=a_1+b\sqrt{2}, \ s_2=a_2+b\sqrt{2}, \ \ a_1 \neq a_2.$
what do you mean by "them"? whatever it means, obviously $\displaystyle S \cap [0,1]=S_1$ having infinitely many points doesn't imply that $\displaystyle S_1$ is dense in $\displaystyle [0,1].$
Hence there are infinitely many points of $\displaystyle S$ in $\displaystyle [0,1]$, hence two of them are arbitrarily close
Oops. What I was thinking is that if $\displaystyle s_1=b_1\sqrt{2}, s_2=b_2\sqrt{2}$ and $\displaystyle s_1-s_2 \in \mathbb{Z}$ then $\displaystyle s_1=s_2$; since there are infinitely many choices of $\displaystyle b$, there are infinitely many points in $\displaystyle S_1$.
The fact that $\displaystyle S_1$ contains infinitely many points does indeed imply that $\displaystyle S$ is dense in $\displaystyle \mathbb{R}$ : it implies that $\displaystyle S_1$ (and hence $\displaystyle S$) has an accumulation point, and any additive subgroup of $\displaystyle \mathbb{R}$ having an accumulation point is dense in $\displaystyle \mathbb{R}$.what do you mean by "them"? whatever it means, obviously $\displaystyle S \cap [0,1]=S_1$ having infinitely many points doesn't imply that $\displaystyle S_1$ is dense in $\displaystyle [0,1].$
Where do you see that I said $\displaystyle S_1$ is compact or closed? It is neither. I said that $\displaystyle S_1$ is dense in $\displaystyle [0,1]$.
To see this rigorously consider the map
$\displaystyle S\rightarrow [0,1]$
$\displaystyle s\mapsto s-\lfloor s \rfloor$
This map, restricted to the subset of $\displaystyle S$ consisting of elements of the form $\displaystyle b\sqrt{2},\ b \in \mathbb{Z}$, is an injection; moreover when $\displaystyle s \in S$, we have $\displaystyle s-\lfloor s \rfloor \in S$; hence there are infinitely many points of $\displaystyle S$ in the bounded set $\displaystyle [0,1]$. Immediately from the Bolzano-Weierstrass theorem we know that $\displaystyle S$ has an accumulation point. It is then an easy matter to show that any additive subgroup of $\displaystyle \mathbb{R}$ having an accumulation point is dense in $\displaystyle \mathbb{R}$. To see this, suppose you have an open interval $\displaystyle I$ of length $\displaystyle L$ in $\displaystyle \mathbb{R}$. Then by the above there is an element of $\displaystyle S$ with 0<|s|<L; taking all its multiples (which are all elements of $\displaystyle S$) we see that one of them must fall in $\displaystyle I$.
I still don't get it, for example in $\displaystyle I=[0,1]$ there are only two integers $\displaystyle 0,1$ and no elements of the form $\displaystyle b\sqrt{2}$ with $\displaystyle b\neq 0$, the element $\displaystyle \sqrt{2} -1 \in [0,1]$ and is the only one that falls in $\displaystyle I$ from the set $\displaystyle A= \{ \sqrt{2} +a : a \in \mathbb{Z} \}$ and the set $\displaystyle B= \{ b\sqrt{2} -1 : b \in \mathbb{Z} \}$ and $\displaystyle S=A+B$, but how do you conclude that there are infinitely many elements from $\displaystyle S$ in $\displaystyle [0,1]$
You should read carefully what I wrote.
$\displaystyle \sqrt{2} = 1.41421...$
$\displaystyle 2\sqrt{2} = 2.82843...$
$\displaystyle 3\sqrt{2} = 4.24264...$
$\displaystyle 4\sqrt{2} = 5.65685...$
and the sequence
$\displaystyle \{0.41421...,\: 0.82843...,\: 0.24264...,\: 0.65685...,\: ...\}$
is a sequence of distinct elements of $\displaystyle S$, all in $\displaystyle [0,1]$.