Thorn CarpetInterp provides a parallel interpolator for Carpet.
CarpetInterp works similar to PUGHInterp, the interpolation thorn of the standard unigrid driver in Cactus.
Firstly, the points to interpolate at (which can vary from processor to processor) are mapped onto processors. Each processor accumulates the number of coordinates it needs to send to other processors (which own the corresponding points).
In a collective communication step, all processors exchange the coordinates of the interpolation points which are not located locally.
After each processor received the coordinates of (local) points to interpolate at, it maps them onto components (also counting the number of points for each component).
Now all processors do – in parallel – the actual interpolation by calling the local interpolator (via CCTK_InterpLocalUnform()) on each component.
Finally, the interpolation results are sent back to the requesting processors in another collective communication step.
CarpetInterp overloads the flesh interpolation C API routine
int CCTK_InterpGridArrays (const cGH *GH, int N_dims, int local_interp_handle, int param_table_handle, int coord_system_handle, int N_interp_points, int interp_coords_type, const void *const interp_coords[], int N_input_arrays, const CCTK_INT input_array_indices[], int N_output_arrays, const CCTK_INT output_array_types[], void *const output_arrays[])
which is described in detail in the Cactus Reference Manual.
It also provides an equivalent aliased function
CCTK_INT FUNCTION DriverInterpolate (CCTK_POINTER_TO_CONST IN cctkGH, CCTK_INT IN N_dims, CCTK_INT IN local_interp_handle, CCTK_INT IN param_table_handle, CCTK_INT IN coord_system_handle, CCTK_INT IN N_interp_points, CCTK_INT IN interp_coords_type, CCTK_POINTER_TO_CONST ARRAY IN interp_coords, CCTK_INT IN N_input_arrays, CCTK_INT ARRAY IN input_array_indices, CCTK_INT IN N_output_arrays, CCTK_INT ARRAY IN output_array_types, CCTK_POINTER ARRAY IN output_arrays)
which can be called by symmetry thorns to implement symmetry interpolations (see the thorn documentation of CactusBase/SymBase for details).
The current implementation of CarpetInterp supports only 3-dimensional grid variables as inputs (N_dims \(==\) 3).
Interpolation coordinates and output arrays must be of type CCTK_VARIABLE_REAL.
A valid handle for a parameter table must be passed in so that CarpetInterp can store in it the overall status code of the local interpolator.
barriers | Scope: private | BOOLEAN |
Description: Insert barriers at strategic places for debugging purposes (slows down execution)
| ||
Default: no | ||
check_tree_search | Scope: private | BOOLEAN |
Description: Cross-check the result of the tree search
| ||
Default: no | ||
ipoison | Scope: private | REAL |
Description: Integer poison value
| ||
Range | Default: -420042 | |
*:* | ||
poison | Scope: private | REAL |
Description: Poison value
| ||
Range | Default: -4.20042e+30 | |
*:* | ||
tree_search | Scope: private | BOOLEAN |
Description: Use a tree search to find the source processor
| ||
Default: yes | ||
Implements:
interp
Uses header:
nompi.h
data.hh
bbox.hh
data.hh
defs.hh
dist.hh
ggf.hh
timestat.hh
typecase.hh
typeprops.hh
vect.hh
carpet.hh
Provides:
DriverInterpolate to
This section lists all the variables which are assigned storage by thorn Carpet/CarpetInterp. Storage can either last for the duration of the run (Always means that if this thorn is activated storage will be assigned, Conditional means that if this thorn is activated storage will be assigned for the duration of the run if some condition is met), or can be turned on for the duration of a schedule function.
NONE
CCTK_STARTUP
carpetinterpstartup
startup routine
Language: | c | |
Type: | function | |