Consider the (Laplace) Finite Difference Equation:
N is a parameter that sets the number of points in the difference grid.
The exact solution to this FDE system is:
In this assignment you will test the following iterative methods to approximate the solution of the above FDE system:
Problem 1.
Beginning with the sample codes jacobi.c, and red_black.c, develop codes for
a) every 10 iterations, it writes the residual and error of maximum absolute value.
b) there is a hard upper limit on the total number of iterations
c) the iterations terminate when the error of maximum absolute value is less than .005.
When your codes are running,
| Method | CPU Time | Megaflops |
| Jacobi | ||
| Gauss-Seidel | ||
| Optimal SOR | ||
| Red-Black | ||
| Optimal Red-Black SOR |