# Some conjectures about a curious sequence

Let $$(u_n)_{n \in \mathbb{N}}$$ defined by $$u_{n+2} = |u_{n+1} - u_n|$$. We will denote "$$U(a,b)$$" the sequence writed term by term until we hit $$0$$. For instance, we have : $$U(4,2) : 4, 2, |2-4|=2,|2-2|=0$$ so $$U(4,2) : 4,2,2,0$$ or $$U(10,3):10,3,7,4,3,1,2,1,1,0$$

We can easily write a code (in python) that generate such sequences :

def U(a,b):
q = [a,b]
n = 1
while n != 0:
n = abs(q[-1]-q[-2])
q.append(n)
return q


Let $$L(a,b)$$ be the length of $$U(a,b)$$, i.e. the length of the sequence until we hit $$0$$. For instance, $$L(10,3) = 10$$ because there is 10 terms in the sequence shown above !

And let $$M(a,b)$$ the lowest element of the sequence that is not $$0$$. For exemple, we have $$U(15,4) : 15, 4, 11, 7, 4, 3, 1, 2, 1, 1, 0$$ So $$M(15,4) = 1$$ (note that we also have $$L(15,4)=11$$).

We now state two conjectures that I'd like to prove !

(1) $$\forall a,b \in \mathbb{N}, M(a,b)=M(b,a)=\gcd(a,b)$$ Exemple : $$U(15,18) : 15, 18, 3, 15, 12, 3, 9, 6, 3, 3, 0$$

We see that $$M(15,18)=3$$ and we have $$\gcd(15,18)=3$$

From that conjecture, I have the deep intuition that this sequence have much to do with prime numbers, in a way that I don't know yet...

The second conjecture is :

(2) $$\forall a, b \in \mathbb{N}, c \in \mathbb{N}^*, L(ac,bc)=L(a,b)$$

For exemple $$L(4,2)=4$$ and $$U(2,1): 2, 1, 1, 0$$

so $$L(2,1)=4$$.

With this conjecture, I think that there is a deeper link between $$U(ac,bc)$$ and $$U(a,b)$$ than just their lengths (like maybe $$U(ac,bc)=c \times U(a,b)$$ or something like that...

Edit : I don't say it because it seemed obvious to me, but we also conjecture that $$L(a,b)$$ is finite for all integers a and b ! It'd be good to prove this conjecture too.