Solution to Problem 2
We give an analytic proof whose final step is a polynomial identity. This form is especially suitable for formal verification.
1. Coordinates and parameters
Scale the figure so that (AC=1), and choose coordinates
[ A=(0,0),\qquad B=(\rho,0),\qquad C=(c,s), ]
where
[ c^2+s^2=1, \qquad \rho=\frac{AB}{AC}>0. ]
Let
[ \alpha=\angle KBA=\angle ACL, \qquad x=\angle BAK, \qquad z=\angle LAC, ]
and write
[ a=\tan\alpha, \qquad p=\tan x, \qquad q=\tan z. ]
For the generic case in which these tangents are finite, intersecting the corresponding rays gives
[ K=\frac{a\rho}{a+p}(1,p), \tag{1} ]
and
[ L=\frac{a}{a+q}(c+qs,\ s-qc). \tag{2} ]
Indeed, ((1,p)) is the direction of (AK), while ((-1,a)) is the direction of (BK). Similarly, ((c+qs,s-qc)) is the direction of (AL).
The midpoint coordinates are
[ M=\left(\frac\rho2,0\right), \qquad N=\left(\frac c2,\frac s2\right). \tag{3} ]
All equations below can be cleared of denominators. Thus the exceptional right-angle cases are covered by the same homogeneous polynomial identities, using direction vectors ((\cos t,\sin t)) instead of tangents.
2. Translating the two remaining angle conditions
From (2), the vectors (NC) and (NL), expressed in the orthonormal basis
[ (c,s),\qquad (s,-c), ]
show that
[ \tan\angle LNC=\frac{2aq}{a-q}. \tag{4} ]
Likewise, from (1),
[ \tan\angle BMK=\frac{2ap}{a-p}. \tag{5} ]
Define
[ F(t)= c\bigl((1+2a^2)t^2+a^2\bigr) +s\bigl(a(t^2+1)-(a^2+1)t\bigr). \tag{6} ]
For two vectors (u,v), use
[ \tan\angle(u,v)=\frac{\det(u,v)}{u\cdot v} ]
and clear denominators.
The equality (\angle LBK=\angle LNC), together with (4), becomes
[ \boxed{\rho(a+q)^2=F(q)}. \tag{7} ]
Similarly, (\angle LCK=\angle BMK), together with (5) and (c^2+s^2=1), becomes
[ \boxed{\rho F(p)=(a+p)^2}. \tag{8} ]
For example, a direction vector of (BK) is ((-1,a)). Substituting the coordinates of (L) into
[ (a-q)\det(BL,BK)=2aq,(BL\cdot BK) ]
and simplifying gives exactly (7). Equation (8) follows analogously from the vectors (CL) and (CK).
3. Equations for the circumcentre
Write
[ O=(u,v). ]
Since (O) is the circumcentre of (AKL) and (A=(0,0)),
[ 2O\cdot K=|K|^2, \qquad 2O\cdot L=|L|^2. ]
Using (1) and (2), these equations become
[ 2(a+p)(u+pv)=a\rho(1+p^2), \tag{9} ]
and
[ 2(a+q)\bigl(u(c+qs)+v(s-qc)\bigr)=a(1+q^2). \tag{10} ]
Set
[ \Delta=s(1-pq)-c(p+q). \tag{11} ]
This is the determinant of the direction vectors of (AK) and (AL), so (\Delta\ne0) because (A,K,L) are not collinear.
Solving (9)--(10) for the linear expression needed later gives
[ \begin{aligned} 4\bigl((\rho-c)u-sv\bigr) =\frac{2a}{(a+p)(a+q)\Delta} \Bigl[&\rho(1+p^2)(a+q)\bigl(\rho(s-qc)+q\bigr)\ &-(1+q^2)(a+p)\bigl(s+p(\rho-c)\bigr) \Bigr]. \end{aligned} \tag{12} ]
4. Polynomial certificate
Introduce
[ H_q=\rho(a+q)^2-F(q), \qquad H_p=\rho F(p)-(a+p)^2, \qquad H_0=c^2+s^2-1. ]
By (7), (8), and the definition of (c,s),
[ H_q=H_p=H_0=0. \tag{13} ]
Let
[ \begin{aligned} T={}&2a\Bigl[ \rho(1+p^2)(a+q)\bigl(\rho(s-qc)+q\bigr)\ &\hspace{28mm}-(1+q^2)(a+p)\bigl(s+p(\rho-c)\bigr) \Bigr]\ &-(\rho^2-1)(a+p)(a+q)\Delta. \end{aligned} \tag{14} ]
Define
[ U_p=a+p+\rho\bigl(-2acp^2-ac+aps+cp+p^2s\bigr), ]
[ V_q=\rho(a+q)-2acq^2-ac+aqs+cq+q^2s. ]
A direct expansion gives the identity
[ \boxed{ T=U_pH_q+V_qH_p -\rho(p-q)\bigl(2a^2pq-a^2-ap-aq+pq\bigr)H_0. } \tag{15} ]
This is a pure polynomial identity; it can be verified by expansion, or by Lean's ring tactic. From (13) and (15), we obtain (T=0). Comparing this with (12) yields
[ 4\bigl((\rho-c)u-sv\bigr)=\rho^2-1. \tag{16} ]
5. Comparing the two distances
Using (3),
[ \begin{aligned} OM^2-ON^2 &=\left(u-\frac\rho2\right)^2+v^2 -\left(u-\frac c2\right)^2 -\left(v-\frac s2\right)^2\ &=-(\rho-c)u+sv+\frac{\rho^2-(c^2+s^2)}4\ &=-(\rho-c)u+sv+\frac{\rho^2-1}{4}. \end{aligned} ]
Equation (16) shows that the last expression is zero. Hence
[ OM^2=ON^2. ]
Both distances are nonnegative, so
[ \boxed{OM=ON}. ]