Prove that if $f: \mathbb{R} \rightarrow \mathbb{R}$ is a homeomorphism, then $f$ cannot have periodic points of primitive period $3$.
The proof was given as follows:
Suppose that we have a primitive period of $3$. Then either:
1) the interval $[x \quad f(x)]$ maps to $[f(x) \quad f^2(x)]$, and $[f(x) \quad f^2(x)]$ maps to $[x \quad f^2(x)]$, or
2) $[x \quad f^2(x)]$ maps to $[f^2(x) \quad f(x)]$, and $[f^2(x) \quad f(x)]$ maps to $[x \quad f(x)]$.
Assume either 1) $x < f(x) < f^2(x)$, or 2) $x < f^2(x) < f(x)$.
Then for 1), $I_1 = [x \quad f(x)]$ and $I_2 = [f(x) \quad f^2(x)]$ and so then $f(I_1) = I_2$ and $f(I_2) = I_1 \cup I_2$. By the intermediate value theorem, there exists a $k \in I_2$ such that $f(k) = f(x)$, but since $x \neq k$ and we have that $f(k) = f(x)$, this is a contradiction.
For 2), $I_1 = [x \quad f^2(x)]$ and $I_2 = [f^2(x) \quad f(x)]$. Then $f(I_1) = I_1 \cup I_2$. Then there exists a $k \in I_1$ such that $f(k) = f^2(x)$ but $f(k) = f(f(x)) = f^2(x)$ which is a contradiction to the assumption that the primitive period was $3$. Q.E.D.
I didn't understand anything about the proof, especially this "interval" business and how the intermediate value theorem is relevant at all.
This fact is quite intuitive. First of all, we can make things a little easier if we assume that $f:\mathbb R\to \mathbb R$ is an orientation preserving homeo (which means that $f$ is increasing): if $f$ was not, then $f^2$ verifies this property and the dynamics of $f^2$ is approximatively the same (the bounded orbits are the same).
Now let us suppose that there exists a point $x_0\in\mathbb R$ and $q\in \mathbb N$, $q\ge 2$ such that $f^q(x_0)=x_0$. Set $x_{k}=f^{k}(x_0)$. Since $f$ is increasing (by induction) we have $$x_0<x_1<\ldots<x_{q-1}<x_q,$$ but, oops!, $x_q=x_0$: contradiction!