<s>[INST] Distance Between A Point And A Line Any Hint on proving that the distance between the point $(x_{1},y_{1})$ and the line $Ax + By + C = 0$ is,
$$\text{Distance} = \frac{\left | Ax_{1} + By_{1} + C\right |}{\sqrt{A^2 + B^2} }$$
What do I use to get started? All I know is the distance formula $\sqrt{(x_{2}-x_{1})^2+(y_{2}-y_{1})^2}$.
Kindly Help
 [/INST] Nothing to see here, just me preparing for my Calc 3 final by attempting this.
We can Lagrange this. Let $f(x) = \sqrt{(x - x_1)^2 + (y - y_1)^2}$ be the distance of $(x_1, y_1)$ from some $(x, y)$ on the line $Ax + By + C = 0$. Also, let $g(x) = Ax + By + C = 0$ be our constraint function, and $(f(x, y))^2 = (x - x_1)^2 + (y - y_1)^2$ be our target function. We want to minimize the distance of the point to the line, basically.
Observe that $\nabla (f(x, y))^2 = \langle 2(x - x_1),2(y - y_1) \rangle$, and $\nabla g(x, y) = \langle A, B \rangle$. Because of the way the gradient behaves around critical points, $\nabla (f(x, y))^2 = \nabla g(x, y)$, so $\langle 2(x - x_1),2(y - y_1) \rangle = \lambda \langle A, B \rangle$. The solutions to this equation are $x = x_1 + \dfrac{\lambda A}{2}$ and $y = y_1 + \dfrac{\lambda B}{2}$ (this is nice because then $x - x_1 = \dfrac{\lambda}{2}A$ and $y - y_1 = \dfrac{\lambda}{2}B$, both of which are helpful later). Plug this back into $Ax + By + C = 0$, and you obtain $\lambda = \dfrac{2Ax_1 + 2By_1 + 2C}{A^2 + B^2}$.
The distance $f(x) = \sqrt{(x - x_1)^2 + (y - y_1)^2} = \sqrt{\left(\dfrac{\lambda A}{2}\right)^2 + \left(\dfrac{\lambda B}{2}\right)^2} = \dfrac{|\lambda|}{2} \sqrt{A^2 + B^2}$. Putting in the expression for $\lambda$, the closest distance is $$\min f(x) = \dfrac{1}{2}\left|\dfrac{2Ax_1 + 2By_1 + 2C}{A^2 + B^2}\right|\sqrt{A^2 + B^2} = \dfrac{|Ax_1 + By_1 + C|}{\sqrt{A^2 + B^2}},$$as desired.
</s>