The top and bottom processors have one less row of interior points than the other processors (see the figure in the assignment).

If you use sqrt, don't forget to include in your file and link with -lm.