I saw this link for closed form formula for a recursive sequence (How to derive a closed form of a simple recursion?)
However, what if my formula is: $$x_n = x_{n-1} + \alpha\sqrt{x_{n-1}} \quad \text{ and } \quad x_0 = \beta \quad \text{ and }\quad\alpha,\beta> 0$$
Is there a closed form solution to determine the value of $x_n$ for a given $n$?
Bonus: If there is a closed form solution, is there an inverse? That is, if one is given a value $y$, can one deduce the closest $n$ such that $x_n$ is the closest to $y$ compared to any other possible $x_n$ value?
I couldn't figure out the mathemical formula for either question. Since we're CS engineers, we know that we could create a lookup table for the first 1 million values of $n$ and that should work for us. (It's arguably a reasonable solution, since we need to compute $x_n$ for 100 million values of $n$ (so obviously, $n$ will be the same thousands of times and so precomputing is not such a bad idea.) But still, it would "cleaner" if there were a closed form analytical solution to the above recursive sequence that we could use/consider.
The bonus question turns out to be easier to solve than the actual problem. Note the problem can be rewritten as
$$x_{n+1}-x_n=\alpha\sqrt{x_n}$$
Consider a variation on this:
$$\frac{dy}{dt}=\underbrace{\lim_{h\to0}{y(t+h)-y(t)\over h}}_{\approx~y(t+1)-y(t)}=\alpha\sqrt{y(t)}$$
This is easily solved using calculus and gives
$$y(t)=\left(\frac{\alpha t}2+\sqrt{y(0)}\right)^2$$
Thus, the solution to your problem is approximately given by
$$x_n\approx\left(\frac{\alpha n}2+\sqrt\beta\right)^2$$
Note that:
$$y(t+1)-y(t)=\alpha\left(\frac{\alpha t}2+\sqrt{y(0)}\right)+\frac{\alpha^2}4$$
$$\alpha\sqrt{y(t)}=\frac{\alpha^2t}2+\alpha\sqrt{y(0)}$$
That is,
$$y(t+1)-y(t)=\alpha\sqrt{y(t)}+\frac{\alpha^2}4$$
So the approximation is pretty decently close.
Thus, the inverse $z_n$ is given by
$$z_n\approx\frac2\alpha\left(\sqrt n-\sqrt\beta\right)$$