# Loopy

Investigate sequences given by $a_n = \frac{1+a_{n-1}}{a_{n-2}}$
for different choices of the first two terms. Make a conjecture
about the behaviour of these sequences. Can you prove your
conjecture?

The terms $a_1, a_2, a_3,...\ a_n,...\ $ of a sequence are given by: $$a_n =\frac{1+a_{n-1}}{a_{n-2}}.$$ Investigate the sequences you get when you choose your own first two terms.

Make a conjecture about the behaviour of these sequences.

Can you prove your conjecture?

Investigate the sequences.

Try some numerical examples and then just use elementary algebra.
You will need to be able to handle algebraic fractions and to do a
simple factorisation.

Sunil sent us his work on this problem:

When I tried this out, no matter what numbers I started with, I always seemed to find that the $6$th term was the same as the $1$st term, and the $7$th the same as the $2$nd, so it kept repeating. I used a spreadsheet to help me do the calculations! Then I used algebra to try to explain why it worked.

The first term is $a_1$.

The second term is $a_2$.

The third term is $\frac{1+a_2}{a_1}$.

The fourth term is $\frac{1+a_1+a_2}{a_1 a_2}$.

The fifth term is $\left(\frac{1+a_1+a_2+a_1 a_2}{a_1 a_2}\right)\times\left(\frac {a_1}{1+a_2}\right)=\left(\frac{(1+a_1)(1+a_2)}{a_1 a_2}\right)\times\left( \frac{a_1}{1+a_2}\right)=\frac{1+a_1}{a_2}$.

The sixth term is $\left(\frac{1+a_1+a_2}{a_2}\right)\times\left(\frac{a_1 a_2} {1+a_1+a_2}\right)=a_1$.

The seventh term is $\left(a_1+1\right)\times\left(\frac{a_2}{1+a_1}\right)=a_2$.

This explains why the pattern always works, no matter what you start with! (As long as the bottom is never $0$, so we can't have $a_1=0$, or $a_2=0$, or $a_1=-1$, or $a_2=-1$, or $a_1+a_2=-1$.)