How to detect or prove that this recurrence relation defines a periodic sequence?

152 Views Asked by At

How to detect or prove that this recurrence relation defines a periodic sequence.

Here is an example $A>0$ is fixed

\begin{align} f(0) & =0 \\[10pt] f(x+1) & = \begin{cases} f(x)+1,& \text{if } A\geq f(x)\ \\ f(x)-1,& \text{if } A<f(x)\ \end{cases} \end{align}

where $A,x$ are natural numbers and the function $f$ returns a natural value.

Can you suggest any method to detect whether this type of recurrence relation defines a periodic sequence?

1

There are 1 best solutions below

0
On

In fact, for $A$ integer, your sequence is 2-periodic (eventually).

As I indicated you, a drawing makes it clear that, if you suppose $A\in \mathbb{Z}$, you have two cases

  1. If $A\geq 0$, then your sequence increases (with $1$-steps) until it reaches $A$ then goes to $A+1$, then $$ A,\ A+1, A,\ A+1,A,\ A+1 \ldots $$
  2. If $A<0$, then your sequence decreases (with $1$-steps) until it reaches $A$ then goes to $A+1$, then $$ A,\ A+1, A,\ A+1,A,\ A+1 \ldots $$

in each case it is eventually periodic.

Hope it helps.