diff options
author | korobkin <korobkin@f69c4107-0314-4c4f-9ad4-17e986b73f4a> | 2008-04-29 16:46:25 +0000 |
---|---|---|
committer | korobkin <korobkin@f69c4107-0314-4c4f-9ad4-17e986b73f4a> | 2008-04-29 16:46:25 +0000 |
commit | 79e94f35fe2d6ee03652166f3c6405802171492c (patch) | |
tree | 43eb649d1bd9662f17dad40556aa7dfc32df9504 | |
parent | b5246b635fd29c06c6f1d71aa76662b8c20a52bb (diff) |
(+) get_offset.c
git-svn-id: https://svn.cct.lsu.edu/repos/numrel/LSUThorns/SummationByParts/trunk@107 f69c4107-0314-4c4f-9ad4-17e986b73f4a
-rw-r--r-- | src/get_offset.c | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/src/get_offset.c b/src/get_offset.c new file mode 100644 index 0000000..d1a35d9 --- /dev/null +++ b/src/get_offset.c @@ -0,0 +1,38 @@ +#include "cctk.h" +#include "cctk_Arguments.h" +#include "cctk_Functions.h" +#include "cctk_Parameters.h" + +void CCTK_FCALL CCTK_FNAME(get_grid_offsets) (CCTK_INT *offset) { + + DECLARE_CCTK_PARAMETERS; + + int i, type; + + const CCTK_INT* shiftout_x_lower = (const CCTK_INT*) CCTK_ParameterGet ( "boundary_shiftout_x_lower", "coordbase", &type ); + if (shiftout_x_lower != NULL ) { + offset[0] = *shiftout_x_lower; + } + const CCTK_INT* shiftout_x_upper = (const CCTK_INT*) CCTK_ParameterGet ( "boundary_shiftout_x_upper", "coordbase", &type ); + if (shiftout_x_upper != NULL ) { + offset[1] = *shiftout_x_upper; + } + const CCTK_INT* shiftout_y_lower = (const CCTK_INT*) CCTK_ParameterGet ( "boundary_shiftout_y_lower", "coordbase", &type ); + if (shiftout_y_lower != NULL ) { + offset[2] = *shiftout_y_lower; + } + const CCTK_INT* shiftout_y_upper = (const CCTK_INT*) CCTK_ParameterGet ( "boundary_shiftout_y_upper", "coordbase", &type ); + if (shiftout_y_upper != NULL ) { + offset[3] = *shiftout_y_upper; + } + const CCTK_INT* shiftout_z_lower = (const CCTK_INT*) CCTK_ParameterGet ( "boundary_shiftout_z_lower", "coordbase", &type ); + if (shiftout_z_lower != NULL ) { + offset[4] = *shiftout_z_lower; + } + const CCTK_INT* shiftout_z_upper = (const CCTK_INT*) CCTK_ParameterGet ( "boundary_shiftout_z_upper", "coordbase", &type ); + if (shiftout_z_upper != NULL ) { + offset[5] = *shiftout_z_upper; + } + + +} |