TITLE: Which irrationals yield bounded sets of iterates?
QUESTION [13 upvotes]: For $r > 0$, define $f(n) = \lfloor {nr}\rfloor$ if $n$ is odd and $f(n) = \lfloor {n/r}\rfloor$ if $n$ is even.  For which real numbers $r$ is the set $\{n,f(n), f(f(n)),\dots\}$ bounded for every nonnegative integer $n$?
So far, I have only computer-generated evidence.  If $r = \sqrt 3$, the iterates reach $1$ for $n = 1,...,10^5$.  If $r = \sqrt 5$, the iterates reach $0$ for $n = 1,...,10^5$.  If $r = \sqrt 2$ and $n = 73$, the iterates appear to be unbounded.  If $r = (1+\sqrt 5)/2$, it appears that the iterates are bounded if and only if $|n+1-2F| \le 1$ for some Fibonacci number $F$; the sequence of such $n$ begins with $0,1,2,3,4,5,6,8,9,10,14,15,16$.
A few more examples, in response to comments:  if $r = 2^{1/3}$, the iterates for $n=9$ and $10 < n < 200001$ reach the cycle ${9,11,13,16,12}$.  If $r = 2^{2/3}$, the iterates reach 1 for $n = 1,...,10^5$.  For $r = e$ and $r = \pi$, the iterates reach $0$ for $n = 1,...,20000$.  For $r = 1/9$, the iterates appear unbounded for many choices of $n$, whereas for $r = 2/9$, perhaps they are all bounded.

REPLY [4 votes]: Let me write the iteration as $x(k+1, r) = f(x(k,r)) =\lfloor r x(k,r) \rfloor$ if $x(k,r)$ is odd, $\lfloor x(k,r)/r \rfloor$ if $x(k,r)$ is even,
where $x(0,r) = 1$ (for convenience). I claim there is an uncountable set of $r$ for which all $x(k,r)$ are odd, and in particular $x(k,r) \to \infty$ as $k \to \infty$.  This will be constructed as the intersection of sets $E_m$, $m=0, 1, \ldots$, where each $E_m$ is the union of $2^m$ disjoint intervals $L_{m,j}$ and for each $(m,j)$ there is an odd integer $X(m,j)$ such that 

$L_{m,j} = \{r: r X(m,\lfloor j/2 \rfloor) \in [X(m+1,j), X(m+1,j)+1)\}$
$x(m+1,r) = X(m+1,j)$ for $r \in L_{m,j}$.
$L_{m+1,2j} \cup L_{m+1,2j+1} \subset L_{m,j}$

For $m=0$ we take $E_0 = L_{0,0} = [5,6)$, $X(0,0) = 1$ and $X(1,0) = 5$.
Suppose we have $L_{m,j}$, $X(m,j)$ as above.  Then $L_{m,j} X(m+1,j)$ is an interval of length $X(m+1,j)/X(m,j) \ge 5$, so it contains 
at least two intervals of the form $[i,i+1)$ with $i$ odd.  These $i$ will be $X(m+2,2j)$ and $X(m+2,2j+1)$.  Then we have $L_{m+1,2j} = \{r: r X(m+1,j) \in [X(m+2,2j),X(m+2,2j)+1)\}$ and $L_{m+1,2j+2} = \{r: r X(m+1,j) \in [X(m+2,2j+1),X(m+2,2j+1)+1)\}$.  
The intersection of the closures of the $E_m$ is a Cantor set, in particular of cardinality of the continuum, and with at most countably many exceptions (endpoints of the $L{m,j}$) its points all have all $x(k,r)$ odd.