wiki:SetGhost

Version 7 (modified by trac, 12 years ago) ( diff )

SUBROUTINE SetGhost(INTEGER level)


Defined In:

contrib/astro/bearez.f90


Inputs:

INTEGER :: level. The level whose ghost zone overlaps are being managed.


Description:

Goes through each grid on the level level looking for ghost zone regions that overlap with other grids. The core grid cells of these overlapping grids are then copied into the ghost zones. This procedure takes five steps:

  1. Enforce the boundary conditions on each level-level grid. This is done using a call to SetBC().
  1. Swap all the ghost zones on non-periodic boundaries. This includes reflecting and extrapolated (open) boundaries as well as internal boundaries.
  1. Swap the ghost zones along the edges of periodic boundaries.
  1. Swap ghost zones at the corners of periodic boundaries. This handles ghost zones at the corners of ghost regions, above or below all boundaries of the core grid.

This routine executes some very communication-intensive subroutines; as such, we clock the time spent within SetGhost() using the tghost accumulator.


Called In:

BearEZ :: BEARStep()

BearEZ :: AMR()

BearEZ :: GridAdapt()

BearEZ :: SynchLevels()


Modules Used:

None explicitly declared, but if the preprocessor tag MPIBEAR is defined, then the mpi_exec version of ExecMode will be used extensively. The SetBC module is used as well.


Files Included:

None.

Note: See TracWiki for help on using the wiki.