NewRad: Add simple support for Llama outer boundary

#9 Merged at b4118f8
Repository
Branch
ianhinder/newrad_llama
Repository
Branch
master
Author
  1. Roland Haas
Reviewers
Description

This implements the radially outgoing boundary condition on Llama's spherical grid. I (Roland) checked that the expressions agree with what CTGamma implements in its CTGRadiativeBC/src/calc_rhs.h, Ian checked that the physics makes sense.

To use the this the user needs to set the parameter z_is_radial explicitly rather than in CTGamma where CTGRadiativeBC decides this on its own based on its knowledge of Llama's coordinate systems. If one really wanted to risk being clever one could likely try and auto-detect this like so:

z_is_radial = (r[CCTK_GFINDEX3D(cctkGH, 0,0,1)] != r[CCTK_GFINDEX3D(cctkGH, 0,0,0)]) &&
              (r[CCTK_GFINDEX3D(cctkGH, 0,1,0)] == r[CCTK_GFINDEX3D(cctkGH, 0,0,0)]) &&
              (r[CCTK_GFINDEX3D(cctkGH, 1,0,0)] == r[CCTK_GFINDEX3D(cctkGH, 0,0,0)]);

though this is obviously not fully safe as it only tests at a single point.

Comments (2)