PLUTO
4.4-patch2
|
#include <structs.h>
Data Fields | |
int | ibeg |
int | iend |
int | jbeg |
int | jend |
int | kbeg |
int | kend |
int | di |
int | dj |
int | dk |
int | vpos |
int * | n |
int * | t |
int * | b |
int * | nbeg |
int * | nend |
int * | tbeg |
int * | tend |
int * | bbeg |
int * | bend |
The RBox (= Rectangular Box) defines a rectangular portion of the domain in terms of the grid indices [ibeg,jbeg,kbeg]
corresponding to the lower corner and [iend,jend,kend]
corresponding to the upper corner. The integer vpos
specifies the variable location with respect to the grid (e.g. center/staggered).
With some macros it is possible to sweep along the box by changing the direction order (e.g. yxz rather than xyz), see ::BOX_TRANSVERSE_LOOP. In this case the index pointers n, t, b
(normal, tangent and bitangent) and the corresponding lower and upper bounds must be set properly using the RBoxSetDirections() function. These are normally used as hidden indices inside the macro.
box->ibeg > box->iend
). In this case the macro BOX_LOOP automatically reset the directional increment (box->di
) to -1. int* b |
Pointer to binormal index when looping along a specified direction (e.g. k
when dir = IDIR
) Set manually or using a macro.
int* bbeg |
Pointer to lower index in the binormal direction. Set by the RBoxSetDirections() function.
int* bend |
Pointer to upper index in the binormal direction. Set by the RBoxSetDirections() function.
int di |
Directional increment (+1 or -1) when looping over the 1st dimension of the box. Automatically set by the BOX_LOOP macro.
int dj |
Directional increment (+1 or -1) when looping over the 2nd dimension of the box. Automatically set by the BOX_LOOP macro.
int dk |
Directional increment (+1 or -1) when looping over the 3rd dimension of the box. Automatically set by the BOX_LOOP macro.
int ibeg |
Lower corner index in the x1 direction.
int iend |
Upper corner index in the x1 direction.
int jbeg |
Lower corner index in the x2 direction.
int jend |
Upper corner index in the x2 direction.
int kbeg |
Lower corner index in the x3 direction.
int kend |
Upper corner index in the x3 direction.
int* n |
Pointer to the normal index when looping along a specified direction. Set manually or using a macro.
int* nbeg |
Pointer to lower index in the normal direction. Set by the RBoxSetDirections() function.
int* nend |
Pointer to upper index in the normal direction. Set by the RBoxSetDirections() function.
int* t |
Pointer to tangent index when looping along a specified direction (e.g. j
when dir = IDIR
). Set manually or using a macro.
int* tbeg |
Pointer to lower index in the tangent direction. Set by the RBoxSetDirectionsl() function.
int* tend |
Pointer to upper index in the tangent direction. Set by the RBoxSetDirections() function.
int vpos |
Location of the variable inside the cell.