let be the orthogonal complement of in we know that so: for some unique now let be any element

of then: (note that because and )

so we showed that for all now are constants. thus is minimum if and only if is minimum, i.e. but then

conversely if for some then thus hence and as we showed: