2D 座標架
Author: 藍邦偉  老師

$ O $

$Q$

$P$

$Step=%v$

$ 過圓上一點的切線方程式 $

$ Sol： $

$又\overline{PQ}⊥L⇒m_{\overline{PQ}}\cdot m_L=-1$

$ 已知P(x_0,y_0)為圓\;C：\;x²+y²$
$+dx+ey+f=0 上一點，\;$
$則過P\;的切線方程式為：$
$x_0x+y_0y+d\cdot \frac{x+x_0}{2}$
$+e\cdot  \frac{y+y_0}{2}+f=0$

y=-1即切線

P_0 = (3.6037225922626015, 1.168545001512193)
O = (0, 0)
Q_2: 0.67 * Corner[1] + 0.33 * Corner[2]
Q_3: (x(Q_2), y(Corner[4]))
poly1, q_1, q_2, q_4, q_3 = Polygon(Corner[1], Q_2, Q_3, Corner[4])
A_0 = (1, 2)
Q = DynamicCoordinates(A_0, floor(x(A_0)), floor(y(A_0)))
P = DynamicCoordinates(P_0, floor(x(P_0)), floor(y(P_0)))
B_0 = (3.8901939210402903, 3.6321988135569314)
r = Segment(Q, P)
α = 0 rad (slider from 0 to 6.283185307179586, step 0.1*°)
P' = Rotate(P, α, Q)
c = CircleArc(Q, P, P')
h: x(Q)
k: y(Q)
s = 0 (slider from 0 to 6, step 1)
C_1 = Circle(Q, r)
D_1 = Circle(Q, r)
L = OrthogonalLine(P, r)
list1 = Coefficients(D_1)
d = Element(list1, 5)
e = Element(list1, 6)
f = Element(list1, 3)
u: (y(P) - y(Q), x(Q) - x(P))
t = 0 (slider from 0 to 10, step 0.01)
P_1: P + t * u
P_2: P - t * u
w = Vector(P, P_1)
z = Vector(P, P_2)
v = Segment(P, Q)
a: x(P)
b: y(P)
text3: "$通過P\;的切線方程式為$
$L：\;y" + (LaTeX[If[b ≟ 0, "", If[b > 0, "-" * b, "+" * (-b)]]]) + "=" + (LaTeX[FractionText[Slope[L]]]) + "(x" + (LaTeX[If[a ≟ 0, "", If[a > 0, "-" * a, "+" * (-a)]]]) + ")$"
text5: "$ ∵C:" + (LaTeX[D_1]) + " $
$⇒C:x^2+y^2" + (LaTeX[If[d ≟ 0, "", If[d > 0, "+" * d * "x", "-" * (-d) * "x"]]]) + "" + (LaTeX[If[e ≟ 0, "", If[e > 0, "+" * e * "y", "-" * (-e) * "y"]]]) + "" + (LaTeX[If[f ≟ 0, "", If[f > 0, "+" * f, "-" * (-f)]]]) + "=0$"
text6: "$ " + (LaTeX[If[a ≟ 0, "", a * "x"]]) + "" + (LaTeX[If[b ≟ 0, "", If[b > 0, "+" * b * "y", "-" * (-b) * "y"]]]) + "$
$ " + (LaTeX[If[d ≟ 0, "", If[d > 0, "+" * d, "-" * (-d)]]]) + "\cdot\frac{x" + (LaTeX[If[a ≟ 0, "", If[a > 0, "+" * a, "-" * (-a)]]]) + "}{2}" + (LaTeX[If[e ≟ 0, "", If[e > 0, "+" * e, "-" * (-e)]]]) + "\cdot\frac{y" + (LaTeX[If[b ≟ 0, "", If[b > 0, "+" * b, "-" * (-b)]]]) + "}{2}" + (LaTeX[If[f ≟ 0, "", If[f > 0, "+" * f, "-" * (-f)]]]) + "=0$"
t_Q: "$ 已知圓C\;以點\;Q\;" + (LaTeX[Q]) + "為圓心，$
$且P\;" + (LaTeX[P]) + "在圓上，\;試求通過P\;點$
$的切線方程式 $"
text1: "$∵m_{\overline{PQ}} =\frac{" + (LaTeX[y(P)]) + "" + (LaTeX[If[y(Q) > 0, "-" + (y(Q)), If[y(Q) < 0, "+" + (abs(y(Q))), ""]]]) + "}{" + (LaTeX[x(P)]) + "" + (LaTeX[If[x(Q) > 0, "-" + (x(Q)), If[x(Q) < 0, "+" + (abs(x(Q))), ""]]]) + "}=" + (LaTeX[FractionText[Slope[Line[P, Q]]]]) + "$"
L_0 = OrthogonalLine(P, v)
L_1: y = y(P)
text12: "x=" + (LaTeX[x(P)]) + "即為切線"
L_2: x = x(P)