Given the sequence $ y_{k}=2^k\tan(\frac{\pi}{2^k})$ for k=2,3,.. prove that $ y_{k} $ is recursively produced by the algorithm: $$ y_{k+1}=2^{2k+1}\frac{\sqrt{1+(2^{-k}y_{k})^2}-1}{y_{k}} $$ for k=2,3,...
I used the identity $ {\tan^2({a})}=\frac{1-\cos{(2a)}}{1+\cos{(2a)}}$ but I couldn't get it right. Any help appreciated.
Let us have a heuristic proof, i.e., try to understand how the recursive formula has been found, in order that, at the end, we can say "I understand how they have had the idea (and how simple it was)".
The formula that is to be established deals with tangents; thus, let us stay with tangents by centering our computations on the classical formula connecting the tangent of an angle to the tangent of the corresponding half-angle (https://en.wikipedia.org/wiki/Tangent_half-angle_formula):
$$T=\dfrac{2t}{1-t^2} \ \ \text{with} \ \ T:=\tan(a) \ \text{and} \ t:=\tan(a/2) \ \ \ (1)$$
Viewing this relationship as a quadratic equation in $t$, i.e.,
$$t^2T+2t-T=0 \ \ \ (2)$$
then expressing that $t$ is its unique positive root, we get the inverse relationship:
$$t=\dfrac{-1+\sqrt{1+T^2}}{T} \ \ \ (3)$$
It suffices now to set $t=\dfrac{y_{k+1}}{2^{k+1}}=\tan\dfrac{\pi}{2^{k+1}}$ and $T=\dfrac{y_{k}}{2^{k}}=\tan\dfrac{\pi}{2^{k}}$ (by definition of $y_k$) in (3) and the recursion formula is proven.