二次曲線的切線方程式


公式

二次曲線圖形包括拋物線、橢圓、雙曲線,以及它們的旋轉。
代數式皆可表示成如下的形式:

\[\boxed{ ax^2 + bxy + cy^2 + dx + ey + f = 0. }\]

若我們想求這個二次曲線圖形過點 $P(x_0, y_0)$ 的切線方程式,透過「換一半」「一半的變數換常數」的代換口訣可以快速得到。具體代換規則如下:

\[\begin{aligned} x^2 = xx &\rightarrow x_0x \\ y^2 = yy &\rightarrow y_0y \\ xy = \frac{xy + xy}{2} &\rightarrow \frac{x_0y + xy_0}{2} \\ x = \frac{x + x}{2} &\rightarrow \frac{x_0 + x}{2} \\ y = \frac{y + y}{2} &\rightarrow \frac{y_0 + y}{2} \end{aligned}\]

因此,任意二次函數在點 $P(x_0, y_0)$ 的切線方程式為

\[\boxed{ ax_0x + b\frac{x_0y + xy_0}{2} + cy_0y + d\frac{x_0 + x}{2} + e\frac{y_0 + y}{2} + f = 0. }\]

例如,圓 $(x-h)^2 + (y-k)^2 = r^2$ 的切線方程式為(若 $P(x_0, y_0)$ 在圓上):

\[(x_0-h)(x-h) + (y_0-k)(y-k) = r^2.\]


證明

若想求 $f(x, y)$ 的切線方程式,我們需先對函數微分,求此函數的斜率方程式:

\[\begin{aligned} (ax^2 + bxy + cy^2 + dx + ey + f)' &= (0)' \\ 2ax + by + bxy' + 2cyy' + d + ey' &= 0 \\ y'(bx + 2cy + e) &= -2ax - by - d \\ y' &= -\frac{2ax + by + d}{bx + 2cy + e} \end{aligned}\]

因此,在點 $P(x_0, y_0)$ 的斜率為:

\[y' = -\frac{2ax_0 + by_0 + d}{bx_0 + 2cy_0 + e}\]

所以切線方程式為

\[y - y_0 = y'(x - x_0)\]

化簡:

\[\begin{aligned} (y - y_0)(bx_0 + 2cy_0 + e) &= -(2ax_0 + by_0 + d)(x - x_0) \\ y(bx_0 + 2cy_0 + e) + x(2ax_0 + by_0 + d) &= y_0(bx_0 + 2cy_0 + e) + x_0(2ax_0 + by_0 + d) \\ y(bx_0 + 2cy_0 + e) + x(2ax_0 + by_0 + d) &= 2ax_0^2 + 2bx_0y_0 + 2cy_0^2 + dx_0 + ey_0 \end{aligned}\]

由於點 $P(x_0, y_0)$ 在曲線上,我們有條件式:

\[ax_0^2 + bx_0y_0 + cy_0^2 + dx_0 + ey_0 + f = 0\]

所以切線方程式可以改寫成:

\[\begin{aligned} y(bx_0 + 2cy_0 + e) + x(2ax_0 + by_0 + d) + dx_0 + ey_0 + 2f &= 0 \\ 2axx_0 + b(xy_0 + x_0y) + 2cyy_0 + d(x + x_0) + e(y + y_0) + 2f &= 0 \\ axx_0 + b\frac{x_0y + xy_0}{2} + cyy_0 + d\frac{x + x_0}{2} + e\frac{y + y_0}{2} + f &= 0 \end{aligned}\]

得證。


當點不在曲線上

若點 $P(x_0, y_0)$ 是平面上的任意點,用此公式必定可求得一直線。 P點稱作極點,該線稱作極線。


矩陣形式

二次函數也可用矩陣形式表示:

\[F(x, y) = ax^2 + bxy + cy^2 + dx + ey + f = 0\]

可改寫為

\[\boxed{ F(\mathbf{x}) = \mathbf{x}^T A \mathbf{x} + \mathbf{b}^T \mathbf{x} + f = 0 }\]

其中

\[\mathbf{x} = \begin{bmatrix} x \\ y \end{bmatrix}, \quad A = \begin{bmatrix} a & \frac{b}{2} \\ \frac{b}{2} & c \end{bmatrix}, \quad \mathbf{b} = \begin{bmatrix} d \\ e \end{bmatrix}\]

對 $\mathbf{x}$ 取梯度(偏微分),可求出圖形在任意點 $\mathbf{x}$ 的法向量:

\[\nabla F(\mathbf{x}) = 2A\mathbf{x} + \mathbf{b}\]

在切點 $P(\mathbf{x}_0)$ 上,切線的法向量為 $2A\mathbf{x}_0 + \mathbf{b}$。 所以切線方程式為:

\[\begin{aligned} (2A\mathbf{x}_0 + \mathbf{b})^T (\mathbf{x} - \mathbf{x}_0) = 0 \\ 2\mathbf{x}_0^T A^T \mathbf{x} - 2\mathbf{x}_0^T A^T \mathbf{x}_0 + \mathbf{b}^T \mathbf{x} - \mathbf{b}^T \mathbf{x}_0 = 0 \\ 2\mathbf{x}_0^T A \mathbf{x} - 2\mathbf{x}_0^T A \mathbf{x}_0 + \mathbf{b}^T \mathbf{x} - \mathbf{b}^T \mathbf{x}_0 = 0 \end{aligned}\]

由於切點 $P(\mathbf{x}_0)$ 在曲線上,必滿足原方程式 $\mathbf{x}_0^T A \mathbf{x}_0 + \mathbf{b}^T \mathbf{x}_0 + f = 0$,得:

\[2\mathbf{x}_0^T A \mathbf{x} + \mathbf{b}^T (\mathbf{x} + \mathbf{x}_0) + 2f = 0\]

等號兩邊同除以 2,即得到切線方程式,亦符合「換一半」的口訣:

\[\boxed{ \mathbf{x}_0^T A \mathbf{x} + \mathbf{b}^T \frac{\mathbf{x} + \mathbf{x}_0}{2} + f = 0. }\]


相關文章

Duality in Quadratic Curves