|
IBAMR
IBAMR version 0.19.
|
#include <BoxGraphUtilities.h>
Static Public Member Functions | |
| static void | makeBoxesPlusPeriodicBoxes (BoxArray< DIM > &out_boxes, const BoxArray< DIM > &in_boxes, const tbox::Array< tbox::List< IntVector< DIM > > > &shifts) |
| Returns an array of boxes that includes entries for each box that touches a periodic boundary. More... | |
| static void | makeBoxesPlusPeriodicBoxes (BoxArray< DIM > &out_boxes, tbox::Array< int > &out_indices, const BoxArray< DIM > &in_boxes, const tbox::Array< tbox::List< IntVector< DIM > > > &shifts) |
| Returns an array of boxes that includes entries for each box that touches a periodic boundary. More... | |
| static int | countPeriodicBoxes (const tbox::Array< tbox::List< IntVector< DIM > > > &shifts) |
| Returns the sum of shifts[j].getNumberOfItems(). More... | |
| static int | qsortIntCompare (const void *v, const void *w) |
| Compare function for use with qsort when sorting integers in ascending order. More... | |
Class BoxGraphUtilities is a utility class that provides methods for "expanding" an array of boxes when some of the boxes touch periodic boundaries. If a box touches a periodic boundary, then there are one or more "virtual" boxes that "wrap around" to the opposite side(s) of the domain:
* * --------------------------- * | | * | | * | | * |------------- |------------- * | this | | the virtual| * | box touches| | wrap around| * | a periodic | | box | * | boundary | | | * |------------- |------------- * | | * | domain | * | box | * --------------------------- * *
The BoxTop, BoxGraph, and possibly other classes require as input arrays of boxes in which the "virtual" boxes are explicitly represented.
|
static |
The shift array must either have zero length, or have the same length as in_boxes, otherwise an unrecoverable error will be thrown.
| out_boxes | contains all items in the in_boxes array, and contains one or more additional items for any box that touches a periodic boundary. |
| in_boxes | array of input boxes. |
| shifts | shift information for each of the input boxes. |
|
static |
The shift array must either have zero length, or have the same length as in_boxes, otherwise an unrecoverable error will be thrown.
| out_boxes | contains all items in the in_boxes array, and contains one or more additional items for any box that touches a periodic boundary. |
| out_indices | contains an entry for each box in out_boxes; the entry indicates the box, w.r.t in_boxes, from which the box was derived. |
| in_boxes | array of input boxes. |
| shifts | shift information for each of the input boxes. |
|
static |
This function is called by makeBoxesPlusPeriodicBoxes().
| shifts | periodic shift information for each box. |
|
static |
Sample usage:
* intarray[len]; * ... * qsort(array, len, sizeof(int), qsortIntCompare); *
1.8.17