This is due Thursday, October 2 in class. Please e-mail your Matlab
script(s) to
Assume that A is real, symmetric, positive definite, and N by N.
Use the definition of the conjugate gradient method for solving
Ax+b=0 given in class:
| 1. | x0 arbitrary | (approximate solution) |
| r0 = Ax0 + b | (approximate residual) | |
| w0 = r0 | (search direction) | |
| 2. | For k=0,1,... | |
| alphak = -(rk,wk)/(wk,Awk) | ||
| xk+1 = xk + alphak wk | ||
| rk+1 = rk + alphak Awk | ||
| betak = -(rk+1,Awk)/(wk,Awk) | ||
| wk+1 = rk+1 + betak wk | ||
| End |
Rigorously prove the results below, where indicated.
Lemma 2: The parameter betak is chosen so that (wk+1,Awk)=0.
Lemma 3: For 0<=q<=k,
| (a) | (rk+1,wq)=0 |
| (b) | (rk+1,rq)=0 |
| (c) | (wk+1,Awq)=0 |
Lemma 4: alphak = (rk+1,rk+1) / (rk+1,Ark).
Lemma 5: betak = (rk+1,rk+1) / (rk,rk).
Assume that M=n2, where n>1.
For your calculations, use n=4.
Use a matrix A that is block tridiagonal.
Both block matrices are n by n.
Let
You should run the CG algorithm until the residual norm has been reduced by
a factor of 10-6, i.e., run until
Cheers,
Craig C. Douglas