Let $F$ be a hyperplane in $\mathbb{R}^n$. Let $0 \neq a = \begin{pmatrix} x_1 \dots x_n \end{pmatrix}^\top$ and $F=\{x\in \mathbb{R}^n \mid a \bullet x=0\}$. If we use $N=\frac{a}{\mid a \mid}$ we have $F=\{x\in \mathbb{R}^n \mid N \bullet x=0\}$.
Now I wanted to prove the formula $d_F(y)=\mid y-P_Fy\mid=\mid y\bullet N \mid$, which is the distance between the vector $y$ and the plane $F$.
The proof follows like this: bcs $y-P_Fy\in F^\perp$ we have $y-P_Fy=\lambda N$, for some $\lambda \in\mathbb{R}$. Multiplaying both sides with $N$ we have $\lambda = (y-P_Fy)\bullet N$, now we have: $$d_F(y)=\mid y-P_Fy\mid=\mid\lambda\mid=\mid (y-P_Fy)\bullet N\mid=\mid y\bullet N\mid$$
My first question: is $\mid y-P_Fy\mid=\mid\lambda\mid$, bcs $y-P_Fy=\lambda N$ and $\mid N \mid =1$.
My second question: why is $\mid (y-P_Fy)\bullet N\mid=\mid y \bullet N \mid$.
$P_Fy$ means the projection of $y$ into $F$, hence $P_F y \cdot N = 0$. Now $|(y - P_F y) \cdot N| = |y \cdot N| = |\lambda|$.