Why the distance from the point to the line is $\frac{|(P-Q)\cdot N|}{\|N\|}$?

48 Views Asked by At

$P$ is a point in the line $L$, $N$ is a vector normal to $L$ and $Q$ is a point out of the line. I know that taking the subtraction of $(P-Q)$, I create a vector that goes from $P$ to $Q$ but I don't know why I need to take the dot product and then divide by the norm of $N$. I read the explanation on Apostol's Calculus but I didn't understand.

2

There are 2 best solutions below

4
On BEST ANSWER

The distance of $Q$ to $L$ is the lenght of the projection of $P-Q$ in the line passing through $Q$ with direction $N$. Said projection is: $${\rm proj}_N(P-Q) = \frac{(P-Q)\cdot N}{N \cdot N}N = \frac{(P-Q)\cdot N}{\|N\|^2}N$$With this: $$\|{\rm proj}_N(P-Q)\| = \left\|\frac{(P-Q)\cdot N}{\|N\|^2}N\right\| = \frac{|(P-Q)\cdot N|}{\|N\|^2}\|N\| = \frac{|(P-Q)\cdot N|}{\|N\|}.$$Recall that given two vectors ${\bf u},{\bf v}$ in an arbitrary vector space with an inner product $\langle\cdot,\cdot\rangle$, we have: $${\rm proj}_{\bf u}{\bf v} = \frac{\langle{\bf v},{\bf u} \rangle}{\langle {\bf u},{\bf u}\rangle}\,{\bf u}.$$

0
On

That is because if $\vec n$ is a unit vector orthogonal to the line, $\bigl((P-Q)\cdot cn\bigr)n$ is the orthogonal projection onto the perpendicular to the line though $P$, hence this distance is the absolute value of the inner product $(P-Q)\cdot n$, and $\,n=\dfrac N{\lVert N\rVert}$.