How do we reach the answer to the following recursive problem? $\large{a_{n+1} = \frac{a_n}{n} + \frac{n}{a_n}, a_1 = 1}$
Let the sequence $\large{\left< a_n \right>}$ be defined as above for all positive integers n. Evaluate $\large{\left \lfloor a_{2015} \right \rfloor}$.
I wrote a C++ program to solve the problem but I've no idea how to mathematically approach it.
Thanks in advance!
 A: If we let $x_n=a_n/\sqrt n$ then we have the recursive rule for $x_n$:
$$
x_{n+1}={x_n\over\sqrt{n(n+1)}}+{1\over x_n}\sqrt{n\over n+1}.
$$
It is easy to prove that $\lim_{n\to\infty}x_n=1$, so that $a_n/\sqrt{2015}$ should be very close to $1$. In other words we may conclude that
$$
\lfloor a_{2015} \rfloor = \lfloor \sqrt{2015} \rfloor=44.
$$
A: This is close to the Babylonian method or Newton's method for computing $\sqrt n$  You use $a_{n-1}$ (which will be close to $\sqrt{n-1}$) as a starting guess and do one iteration.  If you want, you can show that the error is positive, decreasing, and (after a while) bounded by a small enough fraction that you know $44 \lt a_{2015} \lt 45$  
Added:  a little experimentation shows that $a_n$ is a little greater than $\sqrt n$.  For example, $a_{16} \approx 4.06653$.  Define $b_n=a_n-\sqrt n$.  If $\frac 1n \lt b_n \lt \frac 1{\sqrt n}$ (as is true for $n=16$), we can approximate $$b_{n+1}=\frac n{a_n}+\frac {a_n}n-\sqrt n\\
b_{n+1}=\frac n{b_n+\sqrt n}+\frac{b_n+\sqrt n}n-\sqrt n\\
\approx \sqrt n(1-\frac {b_n}{\sqrt n})+\frac 1{\sqrt n}+\frac {b_n}n-\sqrt n\\
=-b_n+\frac 1{\sqrt n}+\frac {b_n}n\\
\approx\frac 1{\sqrt{n+1}}+\frac 2{n^{3/2}}-b_n+\frac {b_n}n$$  We need to argue that $\frac 1{n+1} \le b_{n+1} \lt \frac 1{\sqrt {n+1}}$, but I can't quite get there.  It seems clear, and this gives us an induction that says $b_n$ is small and $a_n \approx \sqrt n$
A: It is probably easier to prove directly by induction that $\sqrt{n-1}\le a_n\le\sqrt{n+2}$ from some $n$ onwards. 
We must prove at first that $a_{n+1}\le\sqrt{n+3}$, which is equivalent to $a_n/n+n/a_n\le\sqrt{n+3}$. But by the inductive hypothesis $a_n/n+n/a_n\le\sqrt{n+2}/n+n/\sqrt{n}$, so that we are left to prove that $\sqrt{n+2}/n+\sqrt{n}\le\sqrt{n+3}$. This last inequality boils down to $\sqrt{1+2/n}(\sqrt{1+3/n}+1)\le3$, which is true for $n\ge4$.
In a similar way, to prove that $a_{n+1}\ge\sqrt{n}$ one must prove $\sqrt{n-1}/n+n/\sqrt{n+2}\le\sqrt{n}$. After some tinkering this is equivalent to $\sqrt{1+(3n-2)/n^2}(1+\sqrt{1+2/n})\ge2$, which is true for $n\ge1$.
In the end we get then $\sqrt{2014}\le a_{2015}\le\sqrt{2017}$, that is $44.878\le a_{2015}\le44.911$.
