Go backward to Communication Types Go up to Top Go forward to Global Communication |
$X(t+1)$_{i,j}=(4X^{(t)}_{i,j}+X^{(t)}_{i-1,j}+X^{(t)}_{i+1,j}+X^{(t)}_{i,j-1}+X^{(t)}_{i,j+1})/(8)
Easy parallelization, but many iterations.for t = 0 to T-1 send X(t)(i,j) to each neighbor receive from neighbors X(t)(i-1,j), X(t)(i+1,j), X(t)(i,j-1), X(t)(i,j+1) compute X(t+1)(i,j) end
Improvement: Gauss-Seidel strategy
$X(t+1)$_{i,j}=(4X^{(t)}_{i,j}+X^{(t+1)}_{i-1,j}+X^{(t)}_{i+1,j}+X^{(t+1)}_{i,j-1}+X^{(t)}_{i,j+1})/(8)Elements are updated in a particular order.
(See Foster, Figures 2.4 and 2.5)