If $ \bigtriangleup ABC$: $\angle CAB = \frac{\pi}{2}$, with height $AD$ and median $AK$. Prove $\angle BAD = \angle BCA = \angle KAC.$ 
If $\triangle ABC$ is a triangle and $\angle CAB = \frac{\pi}{2}$, with height $AD$ and median $AK$; suppose that $D$ is between $B$ and $K$.

*

*Prove that $\angle BAD = \angle BCA = \angle KAC$.

*Then, prove that $\angle BCA= \frac\pi 8$ if $|AD|=|DK|$.

*Conclude that
$$\sin\frac \pi 8=\frac{\sqrt{2-\sqrt 2}}{2};\quad \cos\frac \pi 8=\frac{\sqrt{2+\sqrt 2}}{2};\quad \operatorname{tg}\frac \pi 8= \sqrt 2 - 1$$


I already achieved the draw, but I don't really know how to start.
I know that $\bigtriangleup DBA \sim \bigtriangleup DAC$
 A: Let $D$ be placed between $K$ and $B$.
Thus, since $AK$ is a median, we obtain $$AK=CK=KB,$$ which gives
$$\measuredangle BAD=90^{\circ}-\measuredangle ABC=\measuredangle BCA=\measuredangle KAC.$$
A: *

*Since you have figured out that $\triangle DBA \sim \triangle DAC$, use the property that corresponding angles of similar triangles are equal. Also, notice that $AK=KC$, hence $\triangle KAC$ is isosceles.


*If $AD=DK$, we have $\angle DKA=\angle KAD=45°\implies\angle AKC=135°$. Thus, $\triangle KAC$ being isosceles, we have $\angle BCA=22.5°=\frac{π}{8}$.


*We have $AK=KC=\frac{a}{2}\implies AD=DK=\frac{a}{2\sqrt 2}$. In $\triangle ADC$, $$\tan\angle DCA=\tan\frac{π}{8}=\sqrt 2-1$$
A: 
Consider the circumcircle of $\triangle ABC$. Since $\angle A=\frac{\pi}{2}$, it subtends the diameter, thus $K$ is the circumcenter and $$KA=KB=KC\tag{1}$$

*

*Since $\triangle KCA$ is isosceles, $\angle KCA=\angle KAC$.
In $\triangle ABD$ $\ \ \angle D=\frac{\pi}{2}$, thus $\angle BAD=\frac{\pi}{2}-\angle ABD$, but $\frac{\pi}{2}-\angle ABC=\angle ACB$, thus $\angle BAD=\angle ACB=\angle KAC$, QED.

*In $\triangle ADK$ $\ \ \angle D=\frac{\pi}{2}$, thus $|AD|=|DK|$ $\Rightarrow$ $\angle A=\angle K=\frac{\pi-\angle D}{2}=\frac{\pi}{4}$.
Since $\frac{\pi}{4}=\angle AKD=\angle KAC+\angle KCA$ and $\angle KAC=\angle KCA$, thus $\angle ACK=\frac{\pi}{8}$, QED.

*In $\triangle ADC$ $\ \ \angle D=\frac{\pi}{2}$ and $AK=KC=AD\sqrt{2}$ thus $$\tan \frac{\pi}{8}=\frac{AD}{DK+KC}=\frac{AD}{AD+AD\sqrt{2}}=
\frac{1}{1+\sqrt{2}}=\sqrt{2}-1,$$
the other functions of $\frac{\pi}{8}$ are done by using
$$\frac{1}{\cos^2\theta}=1+\operatorname{tg}^2\theta,\quad
\frac{1}{\sin^2\theta}=1+\operatorname{ctg}^2\theta.$$
