Page page 0


MPI Parallelization of a Simple Advection Code

A Mini-tutorial with Exercises

Rosalinda de Fainchtein, Ph.D; CSC/Code 931
Steven T. Zalesak; Code 931


This mini-tutorial evolved from a parallelization exercise designed for the 2001 HPCC Summer School for Advanced Computing on Space and Earth Sciences by Steven Zalesak.

During the Summer School, a simple 2D finite difference advection code -- advection_2D -- was presented to the students, which they were then asked to parallelize.

Starting from the scalar version of advection_2D, this mini-tutorial will guide you with step by step instructions, as you parallelize advection_2D using MPI_CART routines (which are part of the MPI Standard*). A parallel version of advection_2D is also provided, as well as general advise on the parallelization of more complex advection codes.

Before beginning, you might find it useful to review, and perhaps go over the exercises in the tutorial Intermediate MPI:Domain Decomposition, if you are not already familiar with the MPI_CART routines.

*Note that while the use of MPI_CART routines can greatly simplify the parallelization of uniform grid advection codes, it is also possible to parallelize advection_2D using only basic MPI routines.




NEXT PAGE