If $P_{1}$ and $P_{2}$ are points in $R^{2}$ or $R^{3}$, then the length of the vector $\overrightarrow{P_{1} P_{2}}$ is equal to the distance $d$ between the two points. Specifically, if $P_{1}\left(x_{1}, y_{1}\right)$ and $P_{2}\left(x_{2}, y_{2}\right)$ are points in $R^{2}$, then $$ d=\left\|\overrightarrow{P_{1} P_{2}}\right\|=\sqrt{\left(x_{2}-x_{1}\right)^{2}+\left(y_{2}-y_{1}\right)^{2}} $$ This is the familiar distance formula from analytic geometry. Similarly, the distance between the points $P_{1}\left(x_{1}, y_{1}, z_{1}\right)$ and $P_{2}\left(x_{2}, y_{2}, z_{2}\right)$ in 3 -space is $$ d(\mathbf{u}, \mathbf{v})=\left\|\overrightarrow{P_{1} P_{2}}\right\|=\sqrt{\left(x_{2}-x_{1}\right)^{2}+\left(y_{2}-y_{1}\right)^{2}+\left(z_{2}-z_{1}\right)^{2}} $$