[Carpet] Postregrid

Ian Hinder hinder at gravity.psu.edu
Mon Mar 17 22:47:10 CET 2008


Hi,

In the notes for the new version of Carpet,

  http://www.carpetcode.org/version-4.html

it says:

"There are new schedule bins CCTK_PREREGRIDINITIAL  and
CCTK_POSTREGRIDINITIAL, called before and after regridding during
initial data setup, respectively. As a rule of thumb, routines scheduled
in CCTK_BASEGRID must also be scheduled in both CCTK_POSTREGRID  and
CCTK_POSTREGRIDINITIAL. You can use poisoning (see above) to catch
errors in your schedule.ccl files."

I don't understand this.  What is the purpose of the BASEGRID bin?
In the Cactus documentation, it says:

        This timebin is executed very early after a driver thorn
        constructs grid; this bin should only be used to set up
        coordinate systems on the newly created grids.

Concerning POSTREGRID, it says:

        This timebin is used in mesh refinement settings.  It is
        ignored for unigrid runs.  This bin is executed whenever the
        grid hierarchy or patch setup has changed during evolution;
        see {\tt CCTK\_POSTREGRIDINITIAL}.  It is, e.g.,
        necessary to re-apply the boundary conditions or recalculate
        the grid points' coordinates after every changing the grid
        hierarchy.

So it seems that only the coordinates are supposed to be set in
BASEGRID.  However, many other functions are scheduled in BASEGRID, for
example

      ADMBase: Set the shift_state variable to 1
      CarpetIOASCII: Initialisation routine
      CarpetIOBasic: Initialisation routine
      CarpetIOHDF5: Initialisation routine
      CarpetIOScalar: Initialisation routine
      CartGrid3D: Set up ranges for spatial 3D Cartesian coordinates
      CartGrid3D: Set up spatial 3D Cartesian coordinates on the GH
      SphericalSurface: Calculate surface coordinate descriptors
      Dissipation: Ensure that there are enough ghost zones
      GROUP MaskBase_SetupMask: Set up the weight function
        CarpetReduce: Initialise the weight function
        GROUP SetupMask: Set up the weight function (schedule other
routines in here)
          CarpetReduce: Set up the outer boundaries of the weight function
          CarpetReduce: Set up the weight function for the restriction
regions
      SymBase: Check whether the driver set up the grid consistently
      Time: Initialise Time variables
      Time: Set timestep based on Courant condition (courant_static)



It seems that BASEGRID is a place where you can do initialization of
grid variables which will happen in both initial data and recovery runs,
not just setting up the coordinates.  Is this correct?


-- 
Ian Hinder
hinder at gravity.psu.edu
http://www.gravity.psu.edu/~hinder


More information about the developers mailing list