Is it possible to find such a discrete non-cyclic function with the following features?
Let $$f: \mathbb{Z^{+}} \rightarrow \left\{0,1,2 \right\},$$
and for any $n\in\mathbb{Z^{+}},\left\{ f(3n-2),f(3n-1),f(3n)\right\}$ must be equal $\left\{0,1,2 \right\}$, or $\left\{ 0,2,1\right\},\left\{1,2,0 \right\},\left\{1,0,2 \right\} \left\{2,1,0 \right\},\left\{ 2,0,1\right\}$.
Discrete non-cyclic means, for example:
$$\color{purple}{\left\{f(1),f(2),f(3),f(4),f(5),f(6),f(7),f(8),...f(n) \right\}:=}\color{red}{\left\{\color{red}{0,1,2,2,1,0,1,0,2;} \color{green}{0,1,2,2,1,0,1,0,2;} \color{blue}{0,1,2,2,1,0,1,0,2;}... \right\}}$$
Thus, we have discrete cyclic sequence. Because,
$f(9)=f(1), f(10)=f(2), f(11)=f(3),...,f(16)=f(8).$ In other words, $f(n)=f(n-8)$, where $n≥9, n\in\mathbb{Z^{+}}$ and cycle length is equal to $8.$
I hope I'm asking the question clearly.
I am looking for a mathematical function that takes discrete non-cyclic values. I'm not saying to MSE "Find such a function." What I want to know is whether such a special function can exist mathematically.
Thank you very much.
Not only are such sequences easy to define (as shown in the comments to your post), but there are also some very cool ones that find applications elsewhere in mathematics. In particular, the Thue-Morse sequence is aperiodic, and even has a ternary version.