next up previous contents
Next: Staggertypes Up: Staggering Previous: Staggering   Contents

Indexing, ghostzones, etc.

Note that staggering does not make any changes to the indexing of a grid function: the black solid circles in diagram B7.2 and their associated staggered grid functions (connected by arrows) have the same index!

Since the grid function does not ``know'' anything about the physical location (it's only addressed by indices), why add staggering if the indexing is the same?

Indeed, you could roll your own, but there compelling reasons: Readability and the fact that you are able to query the staggertype of a grid function. More important: In the way the grid is laid out, there is one grid point less for M and P staggered grid functions. This is illustrated in Figure B7.2, which shows 15 gridpoints distributed across 3 processors. The solid black circles show the default location of the grid functions, the grey circles depict the ghostzones. Note that the number of center staggered gridpoints (fat crosses) corresponds to the number of default gridpoints on all processors but the last one. (The same is true for full staggered gridpoints).


next up previous contents
Next: Staggertypes Up: Staggering Previous: Staggering   Contents