Calculate the ratio based on the lengths of edges of triangle
Solution 1:
triangle ABC with sides a. b, and c.
$\begin{array}{} A=(\frac{a^2+b^2-c^2}{2a},\frac{2S}{a}) & B=(a,0) & C=(0,0) & S=Δ(ABC) \end{array}$
$\begin{array}{} \text{Euler line (OH)} & l·x+m·y+n=0 & l=\frac{2a^4-(b^2-c^2)^2-a^2(b^2+c^2)}{2a} & m=\frac{2S(c^2-b^2)}{a} \end{array}$
$\begin{array}{} \left\{ D,E \right\}=OH∩Circle(O,r=R) & R=\frac{abc}{4S} & . \\ K=AD∩BC & L=AE∩BC & T=AO∩BC \\ \end{array}$
$\begin{array}{} m_{OH}=tan(ε)=\frac{-l}{m} & ε+θ=π & tan(θ)=\frac{l}{m} \end{array}$
$\begin{array}{} \text{triangle ODP} & OP=Rcos(θ) & DP=Rsin(θ) \\ x_{D}=x_{O}-Rcos(θ) & y_{D}=y_{O}+Rsin(θ) & ε+θ=π \\ cos(ϕ)=\frac{±1}{\sqrt{1+tan(ϕ)^2}} & cos(θ)=\frac{m}{ρ} & sin(θ)=\frac{l}{ρ} \\ ρ=\sqrt{l^2+m^2} & x_{O}=\frac{a}{2} & y_{O}=\frac{a(-a^2+b^2+c^2)}{8S} \\ x_{D}=\frac{a}{2}-\frac{Rm}{ρ} &y_{D}=Rcos(α)+\frac{Rl}{ρ} & D+E=2O \\ x_{E}=\frac{a}{2}+\frac{Rm}{ρ} & y_{E}=Rcos(α)-\frac{Rl}{ρ} & cos(α)=\frac{-a^2+b^2+c^2}{2bc}\end{array}$
$\begin{array}{} \text{points: K,L,T } & \left| \begin{array}{} x_{A} & y_{A} & 1 \\ x_{D} & y_{D} & 1 \\ x_{K} & 0 & 1 \\ \end{array} \right| =0 & \left| \begin{array}{} x_{A} & y_{A} & 1 \\ x_{E} & y_{E} & 1 \\ x_{L} & 0 & 1 \\ \end{array} \right|=0 & \left| \begin{array}{} x_{A} & y_{A} & 1 \\ x_{O} & y_{O} & 1 \\ x_{T} & 0 & 1 \\ \end{array} \right| =0 \end{array}$
replace everything: $x_{A}$,$y_{A}$,...$R$, $l$,$m$ and $S$. Solve $x_{K}$, $x_{L}$ and $x_{T}$. Simplify
$\begin{array}{} S=\sqrt{s(s-a)(s-b)(s-c)} & s=\dfrac{a+b+c}{2} \end{array}$
$x_{K}=\dfrac{b (a² - b² + c²) ρ - a c [(a² - c²)² + b² (a² + c²) - 2b⁴]}{a b c [(b² - c²)² + a² (b² + c²) - 2a⁴] - [(b² - c²)² - a² (b² + c²)] ρ} a b$
$x_{L}=\dfrac{b (a² - b² + c²) ρ + a c [(a² - c²)² + b² (a² + c²) - 2b⁴]}{a b c [(b² - c²)² + a² (b² + c²) - 2a⁴] + [(b² - c²)² - a² (b² + c²)] ρ} (-a b)$
$x_{T}=\dfrac{a b² (a² - b² + c²)}{a² (b² + c²) - (b² - c²)²}$
$\begin{array}{} r=\dfrac{TK}{TL} & r=\dfrac{x_{T}-x_{K}}{x_{T}-x_{L}} & r=\dfrac{1-p}{1+p} & \text{where:} \end{array}$
$p=\dfrac{[a² (b² + c²) - (b² - c²)²] ρ}{ a b c [(b² - c²)² + a² (b² + c²) - 2a⁴]}$
$ρ=\sqrt{(abc)^2-(-a^2+b^2+c^2)(a^2-b^2+c^2)(a^2+b^2-c^2)}$
Solution 2:
The easiest way to express the ratio $\dfrac{TK}{TL}$ (see $\mathrm{Fig.\space 1}$) in terms of the three angles of an arbitrary acute $\triangle ABC$ is to use the m-n theorem (a.k.a cot theorem) shown in the inset. A proof of this theorem can be found here. But, first we need to do some angle chasing to determine some angles needed for the application of the theorem. To facilitate our work, we add the line segment $QC$, where $Q$ is the point of intersection between the extended $AO$ and the circumcircle of $\triangle ABC$. Furthermore, for brevity, we let $\measuredangle BAK= \phi$.
Since $AQ$ is a diameter of this circle, we have $\measuredangle QCA = 90^0$. As a consequence, we can express $\measuredangle QCB$ as, $$\measuredangle QCB = 90^0 -\hat{C}. $$
The two angles, namely $\measuredangle QCB$ and $\measuredangle QAB$, are subtended by the same chord $BQ$ of the circumcircle at its circumference. Hence, $$\measuredangle QAB= \measuredangle QCB = 90^0 - \hat{C} ,$$ from which it follows that $$\measuredangle TAK= \measuredangle QAB + \measuredangle BAK = 90^0 - \left(\hat{C} -\phi\right). \tag{1}$$
Since $EF$ is a diameter of the circumcircle, we have $\measuredangle FAE = 90^0$. Therefore, $$\measuredangle LAT= \measuredangle FAE - \measuredangle TAK = \hat{C} -\phi. \tag{2}$$
According to Euclid I.32., the external angle at the vertex $T$ of the $\triangle BTA$ can be determined as, $$\measuredangle ATC = \measuredangle ABT + \measuredangle TAB = 90^0 + \left(\hat{B}-\hat{C}\right). \tag{3}$$
Since we now have determined the three required angles, we can apply the m-n theorem to $\triangle ABC$, where the line $AT$ passes through the vertex $A$ and meets the side $BC$ at $T$. $$\left(TK+TL\right)\cot\left\{90^0 + \left(\hat{B}-\hat{C}\right)\right\} =TK\cot\left\{90^0 - \left(\hat{C} -\phi\right)\right\} – TL\cot\left(\hat{C} -\phi \right)$$
This can be rewritten as, $$-\left(TK+TL\right)\tan\left(\hat{B}-\hat{C}\right) =TK\tan\left(\hat{C} -\phi\right) – TL\cot\left(\hat{C} -\phi \right).$$
We can use this equation to set up an expression for the ratio $\dfrac{TK}{TL}$ as shown below. $$\frac{TK}{TL}=\frac{\tan\left(\hat{B}-\hat{C}\right)- \cot\left(\hat{C} -\phi \right)}{ -\tan\left(\hat{B}-\hat{C}\right) - \tan\left(\hat{C} -\phi \right)}$$
Upon simplification of the right hand side of this equation, the above identity becomes, $$\frac{TK}{TL}=\cot\left(\hat{B} -\phi \right) \cot\left(\hat{C} -\phi \right) =\dfrac{2}{1+\dfrac{\cos\left(\hat{A}+2\phi\right)}{\cos\left(\hat{B}-\hat{C}\right)}}-1. \tag{4}$$
We are still in arrear of an expression to determine the value of $\phi$ in terms of the angles of the $\triangle ABC$. Pay your attention to $\mathrm{Fig.\space 2}$, where we have added altitudes $AM$ and $CN$ and drawn two radii $OB$ and $OC$. We also dropped perpendicular $OP$ from $O$ to $BC$, which forced $P$ to be the midpoint of $BC$. Dropping another perpendicular $HG$ from $H$ to $OP$ completes the diagram. Our immediate aim is to find a formula for $\angle GOH$ of the right angle triangle $GOH$, which can be expressed as, $$\measuredangle GOH = \measuredangle POB + \measuredangle BOE =\tan^{-1}\left(\frac{HG}{OG}\right) \tag{5}$$
Arc $BE$ subtends $\angle BAE$ and $\angle BOE$ respectively at the circumference and the center of the circumcircle of $\triangle ABC$. Therefore, $$\measuredangle BOE = 2\measuredangle BAE = 2\phi. \tag{6}$$
Similarly, arc $CB$ subtends $\angle CAB$ and $\angle COB$ respectively at the circumference and the center of the same circle. Hence,
$$\measuredangle COB = 2\measuredangle CAB = 2\hat{A}. $$
Since $OP$ is the perpendicular dropped from the apex to the base of the isosceles triangle $COB$, $$\measuredangle POB = \dfrac{\measuredangle COB}{2} = \hat{A}.\tag{7}$$
According to (5), (6) and (7), we have, $$\measuredangle GOH = 2\phi + \hat{A} =\tan^{-1}\left(\dfrac{HG}{OG}\right) \tag{8}$$
Let’s find formulae for $HG$ and $OG$. $$HG = MP =BP – BM = \dfrac{a}{2} – c\cos\left(\hat{B}\right)\tag{9} $$
$$GP = HM = MC\tan\left(90^0 - \hat{B}\right) = b\cos\left(\hat{C}\right)\cot\left(\hat{B}\right)$$
$$OG = OP – GP = R\cos\left(\hat{A}\right) - b\cos\left(\hat{C}\right)\cot\left(\hat{B}\right), \enspace\small{\text{where $R$ is the circumradius}} \tag{10}$$
Using using the identity $b=2R\sin\left(B\right)$, (8), (9), and (10), we can obtain the following equation. $$\small{\hat{A}+2\phi =\tan^{-1}\left\{\frac{\dfrac{a}{2} – c\cos\left(\hat{B}\right)}{ R\cos\left(\hat{A}\right) - b\cos\left(\hat{C}\right)\cot\left(\hat{B}\right) }\right\} = \tan^{-1}\left\{\frac{\sin\left(\hat{A}\right)-2\cos\left(\hat{B}\right)\sin\left(\hat{C}\right)}{\cos\left(\hat{A}\right)-2\cos\left(\hat{B}\right)\cos\left(\hat{C}\right)}\right\}}$$
Simplification of this equation leads to, $$\hat{A}+2\phi =\tan^{-1}\left\{\frac{\tan\left(\hat{B}\right) -\tan\left(\hat{C}\right)}{ \tan\left(\hat{B}\right) \tan\left(\hat{C}\right)-3}\right\} \tag{11}$$
Once we substitute (11) in (4) to replace the term $\hat{A}+2\phi$, we can call it a day. $$\cfrac{TK}{TL}=\cfrac{2}{1+\cfrac{\cos\left\{\tan^{-1}\left(\cfrac{\tan\left(\hat{B}\right) -\tan\left(\hat{C}\right)}{ \tan\left(\hat{B}\right) \tan\left(\hat{C}\right)-3}\right)\right\}}{\cos\left(\hat{B}-\hat{C}\right)}}-1$$