308 CHAPTER 12. INNER PRODUCT SPACES, LEAST SQUARES
since xn+xm2 ∈ K, ∣∣∣∣xn− xm
2
∣∣∣∣2 ≤ 12|xn− y|2 + 1
2|xm− y|2−λ
2
and as n,m→ ∞, the right side converges to 0 by definition. Hence {xn} is a Cauchysequence as claimed. By completeness, it converges to some x ∈ H. Since K is closed, itfollows that x ∈ K. Then from the triangle inequality,
limn→∞|y− xn|= |y− x|= λ .■
In the above theorem, denote by Py the vector x ∈ K closest to y. It turns out thereis an easy way to characterize Py. For a given z ∈ K, one can consider the function t →|x+ t (z− x)− y|2 for x ∈ K. By properties of the inner product, this is
t→ |x− y|2 +2t Re(z− x,x− y)+ t2 |z− x|2
according to whether Re(z− x,x− y) ≥ 0. Thus elementary considerations yield the twopossibilities shown in the graph. Either this function is increasing on [0,1] or it is not. Inthe case Re(z− x,x− y)< 0 the graph shows that x ̸= Py because there is a positive valueof t such that the function is less than |x− y|2 and in case Re(z− x,x− y) ≥ 0, we obtainx = Py if this is always true for any z ∈ K. Note that by convexity, x+ t (z− x) ∈ K for allt ∈ [0,1] since it equals (1− t)x+ tz.
0 1t
|x−y|2
Re(z−x,x−y)< 0 0 1t
Re(z−x,x−y)≥ 0
Theorem 12.1.4 Let x ∈ K and y ∈ H. Then there exists a closest point of K to y denotedby Py. Then x = Py if and only if
Re(z− x,y− x)≤ 0 (12.1)
for all z ∈ K.
Kz θ
yx
Proof: First suppose 12.1 so Re(z− x,x− y)≥ 0. Then for arbitrary z ∈ K,
|x+ t (z− x)− y|2 = |x− y|2 +2t Re(z− x,x− y)+ t2 |z− x|2
and is an increasing function on [0,1]. Thus it has its minimum at t = 0. In particular|x− y|2 ≤ |z− y|2 . Since z is arbitrary, this shows x = Py.