Next: Metropolis Code in
Up: Parallel Metropolis Algorithms
Previous: Red/Black or Checkerboard
Parallel Metropolis using a checkerboard update is a data parallel
SIMD algorithm.
It is very simple to code in Fortran 90 and High Performance Fortran (HPF).
-
Use standard domain decomposition and distribute the 2-d lattice
among processors using (BLOCK,BLOCK) form.
-
Use a logical mask ( black) which only activates
the appropriate (abstract) processors which deal with black sites.
Then change the mask (black = .NOT.black) and update the other sites.
-
To get data from neighboring sites,
use periodic shift operations (CSHIFT) for
periodic boundary conditions.
Paul Coddington, Northeast Parallel Architectures Center at Syracuse University, paulc@npac.syr.edu