Astonishing: the sum of two infinite products of nested radicals equal to $ \pi $.

Let $\theta=\arctan\frac{1}{2}$. Then $\cos\theta = \frac{2}{\sqrt{5}}$, hence $\sec\theta=\frac{\sqrt{5}}{2}$ and $$\cos\frac{\theta}{2}=\sqrt{\frac{1}{2}+\frac{1}{\sqrt{5}}},\qquad \cos\frac{\theta}{4}=\sqrt{\frac{1+\sqrt{\frac{1}{2}+\frac{1}{\sqrt{5}}}}{2}}$$

and so on. Perform a bit of maquillage, then recall that $$ \cos(\theta)\cos(2\theta)\cdots\cos(2^N\theta)=\frac{\sin(2^{N+1}\theta)}{2^N\sin(\theta)}$$ by a telescopic product, and you will recognize that your identity is just asserting $$ \arctan\frac{1}{2}+\arctan\frac{1}{3}=\frac{\pi}{4},$$ pretty well-known. Your grandfather just combined a Machin-like formula with the principle behind Vieta's formula for $\pi$.