1

What is the nth term of the sequence: $$2,2+\frac{1}{2},2+\frac{1}{2+\frac{1}{2}},2+\frac{1}{2+\frac{1}{2+\frac{1}{2}}},2+\frac{1}{2+\frac{1}{2+\frac{1}{2+\frac{1}{2}}}}...$$

in terms of $s_{n-1}$.

I have tried for some time to calculate this but to no avail. Hopefully somebody with a better understanding of the world of sequences could help/point me in the right direction!

MrMath
  • 71
  • The sequence is $;x_{n+1}=2+\frac1{x_n};$ , with $;x_0=2;$ ...Do you need the limit, in case it exists? – DonAntonio Mar 22 '21 at 23:26
  • What is $;S_{n-1}; $ ...?? – DonAntonio Mar 22 '21 at 23:34
  • @DonAntonio So I just noticed I left off part of the question where the question is: Write the nth term of the sequence $s_n$ in terms of $s_{n−1}$. I may be incorrect but this may just be the nth term that you have provided minus one from the term. I am sorry if I haven't phased that well – MrMath Mar 22 '21 at 23:37
  • Yes, that's the name of the sequence and thus my comment above answers your question. – DonAntonio Mar 22 '21 at 23:37
  • 1
    Calculate the first few values \begin{eqnarray} \frac{2}{1} , \frac{5}{2} , \frac{12}{5} , \frac{29}{12} , \cdots \end{eqnarray} & then look the sequence up ... https://oeis.org/search?q=1%2C2%2C5%2C12%2C29&language=english&go=Search – Donald Splutterwit Mar 23 '21 at 00:32
  • @Mr Nop, the limit is $;1+\sqrt2;$ ...can you see why? It isn't very easy...but also not too hard. – DonAntonio Mar 23 '21 at 00:34
  • https://en.wikipedia.org/wiki/Continued_fraction – saulspatz Mar 23 '21 at 00:36
  • @DonAntonio. Did you know the formula I wrote in my edit ? For me, it is just beautiful. Cheers.:-) – Claude Leibovici Mar 23 '21 at 09:56
  • @ClaudeLeibovici Salut cher ami! No, I really didn't know that beautiful formula. Very nice, indeed ! – DonAntonio Mar 23 '21 at 10:41
  • @DonAntonio Could you please elaborate in regards to how you got that as the limit, I am interested in the method that you used. – MrMath Mar 23 '21 at 14:53
  • @DonAntonio is it something to do with the fact that $1+\frac{1}{2+\frac{1}{2+\frac{1}{2+\frac{1}{2+...}}}}$ is the approximation of $\sqrt{2}$? – MrMath Mar 23 '21 at 15:00

2 Answers2

5

In my answer to this question, I detailed the steps for solving a first-order rational difference equation such as $${ a_{n+1} = \frac{ma_n + x}{a_n + y} }=m+\frac{x-m y}{a_n+y}$$ For your case $m=2$, $x=1$ and $y=0$. So, using the initial condition, $$a_n=\frac{\left(1+\sqrt{2}\right)^n-\left(1-\sqrt{2}\right)^n } { \left(1+\sqrt{2}\right) \left(1-\sqrt{2}\right)^n+\left(\sqrt{2}-1\right)\left(1+\sqrt{2}\right)^n}$$

Edit

In the documentation of sequence $A000129$ in $OEIS$, there is superb formula given by Peter Luschny in year $2018$. It write $$a_n=\frac 1{\sqrt{2}}\, e^{\frac{i \pi n}{2}}\,\sinh \left(n \cosh ^{-1}(-i)\right)$$

2

Assuming you already know the sequence converges, and that is not trivial as the subsequence $\;\left\{x_{2n}\right\}_{n=0}^\infty\;$ is monotonic descending whereas the subsequence $\;\left\{x_{2n+1}\right\}_{n=0}^\infty\;$ is monotonic ascending ( yet both sequences are appropiatedly bounded and converge to the same non-zero finite limit ), and if we put $\;\alpha=\lim\limits_{n\to\infty} x_n\;$ , we can then use arithmetic of limits and get

$$\alpha=\lim_{n\to\infty} x_{n+1}=\lim_{n\to\infty}\left(2+\frac1{x_n}\right)=2+\frac1\alpha\implies\alpha^2-2\alpha-1=0$$

and solving the above quadratic we get that the only plausible limit is $\;1+\sqrt2\;$ ,since the other root of the quadratic is negative: $\;1-\sqrt2<0\;$ .

DonAntonio
  • 211,718
  • 17
  • 136
  • 287