<s>[INST] In this approximation of $\pi$, do you need to know $\pi$ make these calculations? $\pi = 2n\dfrac{\cos (x)}{\sin (x)+1}$
where $x = 90°\dfrac{n-2}{n}$
and $n \to \infty$
A high school student came up with the idea for this approximation of $\pi$, and I helped develop it. It is based on an inscribed polygon. Is this a circular definition? Does it require knowledge of the value of $\pi$ to work?
 [/INST] With some trigonometric identities we can rewrite this as $\pi=\lim_{n\to\infty}n\tan\frac{\pi}{n}$, which doesn't require knowledge of $\pi$ provided we consider values of $n$ that are powers of $2$. The insight is that $\tan 2x =\frac{2\tan x}{1-\tan^2 x}$ implies $$\tan 2x\tan^2 x +2\tan x - \tan 2x=0,\,\tan x =\frac{-1+\sqrt{1+\tan^2 2x}}{\tan 2x}$$for small $x>0$. (The sign used in the quadratic formula follows from $\tan 2x \approx 2x,\,\tan x \approx x.$) Now use $\tan\frac{\pi}{4}=1$ to compute $\tan\frac{\pi}{2^k}$ for $k\ge 3$. Whereas the case $k=2$ gives $\pi\approx 4\cdot 1 = 4$, $k=3$ gives $\pi\approx 8\cdot(\sqrt{2}-1)\approx 3.3$.
How good is this approximation? Writing $n=2^k$ we have $$n\tan\frac{\pi}{n}\approx n(\frac{\pi}{n}+\frac{1}{3}(\frac{\pi}{n})^3)=\pi+\frac{\pi^3}{3n^2}=\pi+\frac{\pi^3}{3\cdot 4^k},$$so to get $d$ decimal places right requires $k\approx d\dfrac{\log 10}{\log 4}$.
</s>