How is $\sqrt{\frac{\sqrt{2}-1}{\sqrt{2}+1}} = \sqrt{2}-1$? I wondered, why this:
$$\sqrt{\frac{\sqrt{2}-1}{\sqrt{2}+1}}$$
is equal to $\sqrt{2}-1$.
Can anyone explain me, why this is equal? :/
 A: \begin{align}
\sqrt{\frac{\sqrt{2}-1}{\sqrt{2}+1}} &= \sqrt{\frac{\sqrt{2}-1}{\sqrt{2}+1}}\cdot\sqrt{\frac{\sqrt{2}-1}{\sqrt{2}-1}}\\
&=\sqrt{\frac{\left(\sqrt{2}-1\right)^2}{2-1}}\\
&=\sqrt{\left(\sqrt{2}-1\right)^2}\\\\
&=\sqrt{2}-1
\end{align}
A: For $a,b>0$, if $ab=1$, then
$$
\frac{a}{b}=a^2
$$
and thus
$$
\sqrt{\frac{a}{b}}=a.
$$
Now, consider $a=\sqrt{2}-1$ and $b=\sqrt{2}+1$.
A: Since I've expanded on my initial "joke comment", I might as well make it a full joke answer :) By that I mean, nobody in their right mind would take this approach to actually verify that the two quantities are equal: instead, what follows is a good, but limited, way to produce expressions with radicals that look different, but are really not.
The trigonometric function $\tan$ (tangent) has a wide variety of half-angle formulas. I would like to use the following two:
\begin{align*}
\tan \frac\theta 2 &= \frac{1 - \sin \theta}{\cos \theta} \tag{1}\\[10pt]
\tan \frac\theta 2 &= \sqrt{\frac{1 - \cos \theta}{1 + \cos \theta}} \tag{2}
\end{align*} 
Evaluating the first at $\theta = \frac{\pi}{4}$, we have that
\begin{align*}
\tan \frac{\pi}{8} = \tan \frac{\pi/4}{2} &= \frac{1 - \sin(\pi/4)}{\cos(\pi/4)} \\[7pt]
 &= \frac{1 - \frac{1}{\sqrt{2}}}{\frac{1}{\sqrt{2}}} \\[7pt]
&= \left(1 - \frac{1}{\sqrt{2}}\right) \cdot \frac{\sqrt{2}}{1} \\[5pt]
&= \sqrt{2} - 1
\end{align*}
Now, using the second identity with $\theta = \pi/4$, we have
\begin{align*}
\tan \frac{\pi}{8} = \tan \frac{\pi/4}{2} 
&= \sqrt{\frac{1 - \cos(\pi/4)}{1 + \cos(\pi/4)}} \\[7pt]
&=\sqrt{\frac{1 - \frac{1}{\sqrt{2}}}{1 + \frac{1}{\sqrt{2}}}} \\[7pt]
&=\sqrt{\frac{1 - \frac{1}{\sqrt{2}}}{1 + \frac{1}{\sqrt{2}}} \cdot \left(\frac{\sqrt 2}{\sqrt 2}\right)} \\[7pt]
&= \sqrt{\frac{\sqrt{2} - 1}{\sqrt{2} + 1}}
\end{align*}
