Distance Between Point and Line Given: point P at $(x_p, y_p)$ function $f(x) = ax + b$ Distance d between P and line described with f(x) equals: $$ d = \frac{\left| ax_p - y_p + b \right|}{\sqrt{1 + a^2}} $$