We have derived all the important relations in CG. We need one more step to make computing the search directions a little bit computationally more efficient.
Recall the basic three-term recurrence for the search directions:
p(k+1)=r(k)+Οkβp(k)Οkβ=β(p(k))TAp(k)(p(k))TAr(k)βΟkβ=β(p(k))TAp(k)(p(k))TAr(k)β=β(p(k))TAp(k)(Ap(k))Tr(k)βββ
Letβs substitute Ap(k). From our previous derivations:
x(k)βx(kβ1)=ΞΌkβp(k)Ax(k)βAx(kβ1)=ΞΌkβAp(k)βr(k)+r(kβ1)=ΞΌkβAp(k)βAp(k)=ΞΌkβr(k)βr(kβ1)βββ
Substitute in Οkβ:
Οkβ=ΞΌkβ(p(k))TAp(k)(r(k)βr(kβ1))Tr(k)β
Recall that r(k)β₯r(kβ1):
Οkβ=ΞΌkβ(p(k))TAp(k)β₯r(k)β₯22ββ
Use the equation for ΞΌkβ:
ΞΌkβ=(p(k))TAp(k)β₯r(kβ1)β₯22ββ
So:
ΞΌkβ(p(k))TAp(k)=β₯r(kβ1)β₯22β
Substitute back in Οkβ:
Οkβ=β₯r(kβ1)β₯22ββ₯r(k)β₯22ββ
We have proved that:
Theorem. The optimal search directions in CG are given by:
p(k+1)=r(k)+Οkβp(k)Οkβ=β₯r(kβ1)β₯22ββ₯r(k)β₯22ββββ