|
发表于 2023-10-3 08:34:13
|
显示全部楼层
下面的程序中,\(λ\),\(μ\), \(η\) 是 \(BC、CA、AB\) 各边上 \(D、E、F\) 点的定比分割系数,即 \(λ=BD/BC\),\(μ=CE/CA\), \(η=AF/AB\)。这三个系数与主帖中的 \(x, y, z\) 有如下关系:
\(x=1-2λ\),\(y=1-2μ\),\(z=1-2η\)。\(λ\),\(μ\), \(η\) 的取值范围都是 0 到 +1, \(x, y, z\) 的取值范围都是 -1 到 +1。
- Clear["Global`*"]; \(*三角形的外接圆为单位圆进行构图以证明PQ\[UpTee]AG,以下是数字验证,如果去掉数字算出的公式极复杂,证明不成功!*)(*令\[CapitalDelta]ABC的外接圆为单位圆O,BC边平行于实轴,因此BC的复斜率为 \1。已知AB、AC的复斜率分别为-ab和-ac *)Clear["Global`*"]; \[Lambda] = 0.6; \[Lambda] = 0.85; \[Lambda] = 0.9; \[Lambda] = \0.45; \[Lambda] = 0.3; \[Lambda] = 0.05; \[Lambda] = 0.27; \[Lambda] \= 0.73; (*\[Lambda]是除0.5外的任给数据*)(*对于以上任一个\[Lambda]数据,程序运行结果都能验证PQ垂直于AG的结论*)a = 0.8 + Sqrt[1 - 0.8^2] I; b = -0.55 - Sqrt[1 - 0.55^2] I; c = 0.55 - Sqrt[1 - 0.55^2] I;(*任给测试数据*)\!\(\*OverscriptBox[\(a\), \(_\)]\) = 0.8 - Sqrt[1 - 0.8^2] I; \!\(\*OverscriptBox[\(b\), \(_\)]\) = -0.55 + Sqrt[1 - 0.55^2] I; \!\(\*OverscriptBox[\(c\), \(_\)]\) = 0.55 + Sqrt[1 - 0.55^2] I;u = -Sqrt[-a b]; v = Sqrt[-a c];(*不用数字计算时 u,v 是两个自由变量*)o = 0; \!\(\*OverscriptBox[\(o\), \(_\)]\) = 0; a = I u v; b = ( I u)/v; c = (I v)/u; \!\(\*OverscriptBox[\(a\), \(_\)]\) = 1/a; \!\(\*OverscriptBox[\(b\), \(_\)]\) = 1/b; \!\(\*OverscriptBox[\(c\), \(_\)]\) = 1/c;Print["a = ", a, ", b = ", b, ", c = ", c];kab = -a b; kac = -a c; (*AB和AC的复斜率,因为A、B、C都在单位圆上,故有此公式*)BC = Simplify[(c - b)/1]; CA = Simplify[(a - c)/Sqrt[kac] ]; AB = Simplify[(b - a)/-Sqrt[kab]]; (*线段BC、CA、AB的长度*)Print["BC = ", Re[BC], ", CA = ", Re[CA], ", AB = ", Re[AB]];(*由于计算有误差,导致算出的边长有很小的虚部,显示时宜将虚部忽略*)x = 1 - 2 \[Lambda]; d = Simplify[b + (c - b) (1 - x)/2]; \!\(\*OverscriptBox[\(d\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(b\), \(_\)]\) + (\!\(\*OverscriptBox[\(c\), \(_\)]\) - \!\(\*OverscriptBox[\(b\), \(_\)]\)) (1 - x)/ 2];(*BC上D点的\[Lambda]=(1-x)/2*)(*直线BC上有一点D,BD/BC=\[Lambda],则D点坐标d=\b+(c-b)\[Lambda]; Overscript[d, _]=Overscript[b, _]+(Overscript[c, \_]-Overscript[b, _])\[Lambda]。上式中的 x 是一个自由变量;*) y = Simplify[(-BC^2 x^2 - CA^2 + AB^2 - Sqrt[(BC^2 x^2 + CA^2 - AB^2)^2 - 4 CA^2 x (BC^2 x - AB^2 x)])/( 2 CA^2 x)]; (*\[Lambda]不能取0.5,否则x=0导致分母为零!*)(*陆教授公式,CA上E的定比分点系数为(1-y)/2*) z = Simplify[(-BC^2 x^2 + CA^2 - AB^2 + Sqrt[(BC^2 x^2 + CA^2 - AB^2)^2 - 4 CA^2 x (BC^2 x - AB^2 x)])/( 2 AB^2 x)];(*AB上F的定比分点系数为(1-z)/2*)e = Simplify[c + (a - c) (1 - y)/2]; \!\(\*OverscriptBox[\(e\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(c\), \(_\)]\) + (\!\(\*OverscriptBox[\(a\), \(_\)]\) - \!\(\*OverscriptBox[\(c\), \(_\)]\)) (1 - y)/2];f = Simplify[a + (b - a) (1 - z)/2]; \!\(\*OverscriptBox[\(f\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(a\), \(_\)]\) + (\!\(\*OverscriptBox[\(b\), \(_\)]\) - \!\(\*OverscriptBox[\(a\), \(_\)]\)) (1 - z)/2];Print["d = ", d, ", e = ", e, ", f = ", f];Jd[k1_, a1_, k2_, a2_] := -((k2 (a1 - k1 \!\(\*OverscriptBox[\(a1\), \(_\)]\)) - k1 (a2 - k2 \!\(\*OverscriptBox[\(a2\), \(_\)]\)))/( k1 - k2));(*复斜率等于k1,过点A1与复斜率等于k2,过点A2的直线交点*)\!\(\*OverscriptBox[\(Jd\), \(_\)]\)[k1_, a1_, k2_, a2_] := -((a1 - k1 \!\(\*OverscriptBox[\(a1\), \(_\)]\) - (a2 - k2 \!\(\*OverscriptBox[\(a2\), \(_\)]\)))/(k1 - k2));p = Simplify[Jd[-1, d, a b, f]]; \!\(\*OverscriptBox[\(p\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(Jd\), \(_\)]\)[-1, d, a b, f]];q = Simplify[Jd[(c - f)/(\!\(\*OverscriptBox[\(c\), \(_\)]\) - \!\(\*OverscriptBox[\(f\), \(_\)]\)), c, (b - e)/(\!\(\*OverscriptBox[\(b\), \(_\)]\) - \!\(\*OverscriptBox[\(e\), \(_\)]\)), b]]; \!\(\*OverscriptBox[\(q\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(Jd\), \(_\)]\)[(c - f)/(\!\(\*OverscriptBox[\(c\), \(_\)]\) - \!\(\*OverscriptBox[\(f\), \(_\)]\)), c, (b - e)/(\!\(\*OverscriptBox[\(b\), \(_\)]\) - \!\(\*OverscriptBox[\(e\), \(_\)]\)), b]];Print["p = ", p, ", q = ", q];m = Simplify[Jd[kac, c, (p - c)/(\!\(\*OverscriptBox[\(c\), \(_\)]\) - \!\(\*OverscriptBox[\(p\), \(_\)]\)), b]]; \!\(\*OverscriptBox[\(m\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(Jd\), \(_\)]\)[kac, c, (p - c)/(\!\(\*OverscriptBox[\(c\), \(_\)]\) - \!\(\*OverscriptBox[\(p\), \(_\)]\)), b]];n = Simplify[Jd[kab, b, (p - b)/(\!\(\*OverscriptBox[\(b\), \(_\)]\) - \!\(\*OverscriptBox[\(p\), \(_\)]\)), c]]; \!\(\*OverscriptBox[\(n\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(Jd\), \(_\)]\)[kab, b, (p - b)/(\!\(\*OverscriptBox[\(b\), \(_\)]\) - \!\(\*OverscriptBox[\(p\), \(_\)]\)), c]];g = Simplify[Jd[1, b, (m - n)/(\!\(\*OverscriptBox[\(m\), \(_\)]\) - \!\(\*OverscriptBox[\(n\), \(_\)]\)), m]]; \!\(\*OverscriptBox[\(g\), \(_\)]\) = Simplify[\!\(\*OverscriptBox[\(Jd\), \(_\)]\)[1, b, (m - n)/(\!\(\*OverscriptBox[\(m\), \(_\)]\) - \!\(\*OverscriptBox[\(n\), \(_\)]\)), m]];Print["m = ", m, ", n = ", n, ", g = ", g];kag = Simplify[(a - g)/(\!\(\*OverscriptBox[\(a\), \(_\)]\) - \!\(\*OverscriptBox[\(g\), \(_\)]\))]; kpq = Simplify[(p - q)/(\!\(\*OverscriptBox[\(p\), \(_\)]\) - \!\(\*OverscriptBox[\(q\), \(_\)]\))];Print["kag = ", kag, ", kpq = ", kpq];If[-0.9999999999999 > Re[kpq/kag] > -1.0000000000001 && Im[Abs[kpq/kag]] < 10^-15, Print["由于PQ与AG的复斜率之比为 -1,所以它们垂直"] ]
复制代码
运行结果是:
- a = 0.8 +0.6 I, b = -0.55-0.835165 I, c = 0.55 -0.835165 IBC = 1.1, CA = 1.45678, AB = 1.97033d = 0.253 -0.835165 I, e = 0.601153 -0.54151 I, f = 0.00378844 -0.246441 Ip = 0.253 -0.480864 I, q = 0.339482 -0.608262 Im = 0.738091 +0.244604 I, n = 0.19878 -0.0391479 I, g = -1.31417-0.835165 Ikag = 0.3691 +0.92939 I, kpq = -0.3691-0.92939 I由于PQ与AG的复斜率之比为 -1,所以它们垂直
复制代码 |
|