Characterization of the orthogonal projection in a Hilbert space Let be $H$ a Hilbert space and $P:H\rightarrow{H}$ a linear continuous operator.
Prove thar $P$ is the orthogonal proyection onto P(H) if and only if $P^2=P$ and $(Px|y)=(x|Py)$
$\forall{x,y}\in{H}$
 A: Since $P^2=P$, it is enough to show that $H=Ker(P)\oplus Im(P)$ and $Ker(P)$ and $Im(P)$ are orthogonal.
Let $x\in Ker(P), y\in Im(P)$, there exists $z$ such that $y=P(z)), (x|y)=(xP(z))=(P(x)|z)=(0|z)=0$.
Let $x\in H$, $x={{x+P(x)}\over 2}+{{x-P(x)}\over 2}$. Let $u={{x-+P(x)}\over 2}, v={{x-P(x)}\over 2}$.
$P(u)=0, P(v)=v$.
On the other hand, suppose that $P$ is an orthogonal projection, let $x,y\in H$, write $x=x_1+x_2, y=y_1+y_2$ where $x_1,y_1\in Ker(H), x_2,y_2\in Im(H)$. $P(x)=x_2, P(y)=y_2$.
This implies that $((P(x)|y)=(x_2|y_1+y_2)=(x_2|y_2)$
$(x|P(y))=(x_1+x_2|y_2)=(x_2|y_2)$.
A: $Px$ is the orthogonal projection of $x$ onto $P(H)$ iff $(x-Px)\perp P(H)$ for all $x\in H$. So the condition of being an orthogonal projection onto $P(H)$ is equivalent to
$$
                            \langle x-Px,Py\rangle =0,\;\;\; x,y\in H.
$$
That is,
$$
                  \langle Px,Py\rangle = \langle x,Py\rangle.
$$
Swapping $x,y$ gives
$$
                 \langle Py,Px\rangle = \langle y,Px\rangle \\
                 \langle Px,Py\rangle = \langle Px,y\rangle.
$$
Therefore $\langle Px,y\rangle = \langle Px,Py\rangle = \langle x,Py\rangle$ must hold for all $x,y$ for an orthogonal projection, and this is equivalent to $P$ being an orthogonal projection. Therefore $P$ is an orthogonal projection iff $\langle Px,y\rangle =\langle x,Py\rangle$ for all $x,y$ and $P^2=P$.
