平面三角形外心坐标推导

1. 基于向量法的外心推导

1.1 原点三角形

假设在\(\triangle ABC\)中, \(A\)点坐标为\((0,0)\),其余点坐标分别为\(B(x_1,y_1),C(x_2,y_2)\), 我们称\(\triangle ABC\)为原点三角形。对于非原点三角形,可以对\(A,B,C\)都减去\(A\)点坐标,从而转化成原点三角形。在原点三角形\(\triangle ABC\)中,设外心\(P\)坐标为\((x,y)\)。

1.2 外心定义的向量性质

\(\triangle ABC\)外心的定义为: 外心\(P\)到\(\triangle ABC\)各顶点的距离相等,用向量表示为:

\(|\overrightarrow{PA}|=|\overrightarrow{PB}|=|\overrightarrow{PC}|\)

由以上性质可得:

\(\left\{\begin{aligned} |\overrightarrow{PA}|=|\overrightarrow{PB}| \Longrightarrow \triangle ABP是等腰三角形 \\ |\overrightarrow{PA}|=|\overrightarrow{PC}| \Longrightarrow \triangle ACP是等腰三角形 \\ |\overrightarrow{PB}|=|\overrightarrow{PC}| \Longrightarrow \triangle BCP是等腰三角形 \end{aligned}\right.\)

一般的,在等腰三角形\(\triangle ABP\)中,\(\overrightarrow{AP}\)在\(\overrightarrow{AB}\)上的投影为:

\(\cfrac{\overrightarrow{AP}\cdot\overrightarrow{AB}}{|\overrightarrow{AB}|} = \cfrac{|\overrightarrow{AB}|}{2} \Longrightarrow \overrightarrow{AP}\cdot\overrightarrow{AB} = \cfrac{|\overrightarrow{AB}|^2}{2}\)

因此,我们可以得到\(\triangle ABC\)外接圆向量性质:

\(\left\{\begin{aligned} \overrightarrow{AP}\cdot\overrightarrow{AB} = \cfrac{|\overrightarrow{AB}|^2}{2} \\ \overrightarrow{AP}\cdot\overrightarrow{AC} = \cfrac{|\overrightarrow{AC}|^2}{2} \\ \overrightarrow{BP}\cdot\overrightarrow{BC} = \cfrac{|\overrightarrow{BC}|^2}{2} \end{aligned}\right.\) 式1

1.3 原点三角形外心坐标推导

由原点三角形\(\triangle ABC\)定义可得:
\(\left\{\begin{aligned} \overrightarrow{AP} = (x,y) \\ \overrightarrow{AB} = (x_1,y_1)\\ \overrightarrow{AC} = (x_2,y_2) \end{aligned}\right.\)

由1.2中推导的外接圆向量性质,将上式代入取公式中的第1,2项,可得:

\(\left\{\begin{aligned} (x,y)\cdot(x_1,y_1) = \cfrac{|(x_1,y_1)|^2}{2} \\ (x,y)\cdot(x_2,y_2) = \cfrac{|(x_2,y_2)|^2}{2} \end{aligned}\right.\)
\(\Longrightarrow\left\{\begin{aligned} x_1\cdot x+y_1\cdot y = \cfrac{x_1^2+y_1^2}{2} \\ x_2\cdot x+y_2\cdot y = \cfrac{x_2^2+y_2^2}{2} \end{aligned}\right.\)

令\(b_1=\cfrac{x_1^2+y_1^2}{2}, b_2=\cfrac{x_2^2+y_2^2}{2}\)

\(\Longrightarrow\left\{\begin{aligned} x_1\cdot x+y_1\cdot y = b_1 \\ x_2\cdot x+y_2\cdot y = b_2 \end{aligned}\right.\)

上式可以使用线性方程Cramer法则求解,得:

\(D=\left|\begin{array}{cccc} x_1 & y_1\\ x_2 & y_2 \end{array}\right| = x_1\cdot y_2 - x_2\cdot y_1\)

\(\Longrightarrow\left\{\begin{aligned} x=\cfrac{\left|\begin{array}{cccc} b_1 & y_1\\ b_2 & y_2 \end{array}\right|}{D} \\ y = \cfrac{\left|\begin{array}{cccc} x_1 & b_1\\ x_2 & b_2 \end{array}\right|}{D} \end{aligned}\right.\)

最终,我们得到了外心的坐标公式:

\(\Longrightarrow\left\{\begin{aligned} x=\cfrac{b_1\cdot y_2 - b_2\cdot y_1}{D} \\ y = \cfrac{x_1\cdot b_2 - x_2\cdot b_1}{D} \end{aligned}\right.\) 式2

1.4 一般三角形外心坐标推导

对一般三角形\(\triangle A^{'}B^{'}C^{'}\),顶点分别坐标为\(A(x_0^{'},y_0^{'}),B(x_1^{'},y_1^{'}),C(x_2^{'},y_2^{'})\),将各顶点坐标都减去\(A\)点坐标,得到原点三角形\(\triangle ABC\)及其各顶点坐标\(A(0,0),B(x_1,y_1),C(x_2,y_2)\)。

应用式2,我们得到了三角形外心坐标公式

\(\Longrightarrow\left\{\begin{aligned} x = \cfrac{b_1\cdot y_2 - b_2\cdot y_1}{D}+(x_0^{'}-x_0) \\ y = \cfrac{x_1\cdot b_2 - x_2\cdot b_1}{D}+(y_0^{'}-y_0) \end{aligned}\right.\) 式3

2. 使用坐标法推导原点三角形外心

对原点三角形\(\triangle ABC\),利用外接圆定义有:

\(\left\{\begin{aligned} x^2 + y^2 = (x_1 - x)^2 + (y_1 - y)^2\\ x^2 + y^2 = (x_2 - x)^2 + (y_2 - y)^2 \end{aligned}\right.\)

\(\Rightarrow\left\{\begin{aligned} x^2 + y^2 = x_1^2 - 2x_1x + x^2 + y_1^2 - 2y_1y + y^2\\ x^2 + y^2 = x_2^2 - 2x_2x + x^2 + y_2^2 - 2y_2y + y^2 \end{aligned}\right.\)

\(\Rightarrow\left\{\begin{aligned} 0 = x_1^2 - 2x_1x + y_1^2 - 2y_1y\\ 0 = x_2^2 - 2x_2x + y_2^2 - 2y_2y \end{aligned}\right.\)

\(\Rightarrow\left\{\begin{aligned} 2x_1x + 2y_1y = x_1^2 + y_1^2\\ 2x_2x + 2y_2y = x_2^2 + y_2^2 \end{aligned}\right.\)

\(\Rightarrow\left\{\begin{aligned} x_1\cdot x + y_1\cdot y = \cfrac{x_1^2 + y_1^2}{2}\\ x_2\cdot x + y_2\cdot y = \cfrac{x_2^2 + y_2^2}{2} \end{aligned}\right.\)

到这里,得到了与向量法推导的一样的结果\(♡\)。

上一篇:机器学习(5)- 支持向量机


下一篇:PatchMatch小详解