# Visualize the proof of $\mathcal{H} = M \oplus M^{\perp}$, where $\mathcal{H}$ Hilbert space, $M$ closed subspace

### Solution:

Put $$m=(a,b,c)$$. The set $$K$$ is a copy of a set $$-M$$ shifted by $$x$$, that is $$K=\{x-\mu m:\mu\in\Bbb R\}$$ is a line. By the definition, $$x_2$$ is a point of $$K$$ closest to the origin $$O=(0,0,0)$$. Looking at the plane spanned by $$O$$ and $$K$$, we see that $$x_2$$ is the base of the altitude dropped from $$O$$ to $$K$$, that is $$x_2\in K$$ and $$\langle x_2, m\rangle=0$$. Thus $$x_2=x-\mu m=(u,v,w)-\mu (a,b,c)$$, with $$\mu=\tfrac{ua+vb+wc}{a^2+b^2+c^2}=\frac{\langle m,x\rangle}{\|m\|^2} .$$

And what is the geometric intuition of choosing $$\lambda$$ that way?

In order to obtain the best from the inequality $$\| x_2 \|^2 \le \| x_2 - \lambda y \|^2$$ we pick $$\lambda$$ which minimizes its right hand side. For this we need $$x_2 - \lambda y$$ be the base of the altitude dropped from $$O$$ to the line $$\{x_2-\lambda y:\lambda\in\Bbb R\}$$. Similarly to the above we see that this is attained when $$\lambda := \frac{\langle x_2, y \rangle}{\langle y, y, \rangle}$$.