Types and operations for discrete integer index space in AMReX.
More...
|
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::grow (const BoxND< dim > &b, int i) noexcept |
| | Grow BoxND in all directions by given amount.
|
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::grow (const BoxND< dim > &b, const IntVectND< dim > &v) noexcept |
| | Grow BoxND in all directions by given amount.
|
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::grow (const BoxND< dim > &b, int idir, int n_cell) noexcept |
| | Grow BoxND in given direction by given amount.
|
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::grow (const BoxND< dim > &b, Direction d, int n_cell) noexcept |
| | Grow BoxND in given direction by given amount.
|
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::coarsen (const BoxND< dim > &b, int ref_ratio) noexcept |
| | Coarsen BoxND by given (positive) coarsening ratio.
|
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::coarsen (const BoxND< dim > &b, const IntVectND< dim > &ref_ratio) noexcept |
| | Coarsen BoxND by given (positive) coarsening ratio.
|
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::refine (const BoxND< dim > &b, int ref_ratio) noexcept |
| |
| template<int dim> |
| __host__ __device__ BoxND< dim > | amrex::refine (const BoxND< dim > &b, const IntVectND< dim > &ref_ratio) noexcept |
| | Refine BoxND by given (positive) refinement ratio.
|
| |
Types and operations for discrete integer index space in AMReX.
These types define the integer space on which AMReX data structures are defined. They are independent of physical coordinates and units.
Central types include:
Common operations include:
◆ coarsen() [1/2]
| __host__ __device__ BoxND< dim > amrex::coarsen |
( |
const BoxND< dim > & |
b, |
|
|
const IntVectND< dim > & |
ref_ratio |
|
) |
| |
|
inlinenoexcept |
Coarsen BoxND by given (positive) coarsening ratio.
NOTE: if type(dir) = CELL centered: lo <- lo/ratio and hi <- hi/ratio. NOTE: if type(dir) = NODE centered: lo <- lo/ratio and hi <- hi/ratio + ((hiratio)==0 ? 0 : 1). That is, refinement of coarsened BoxND must contain the original BoxND.
- Parameters
-
| b | input Box |
| ref_ratio | coarsening ratio |
- Returns
- the coarsened Box
◆ coarsen() [2/2]
| __host__ __device__ BoxND< dim > amrex::coarsen |
( |
const BoxND< dim > & |
b, |
|
|
int |
ref_ratio |
|
) |
| |
|
inlinenoexcept |
Coarsen BoxND by given (positive) coarsening ratio.
NOTE: if type(dir) = CELL centered: lo <- lo/ratio and hi <- hi/ratio. NOTE: if type(dir) = NODE centered: lo <- lo/ratio and hi <- hi/ratio + ((hiratio)==0 ? 0 : 1). That is, refinement of coarsened BoxND must contain the original BoxND.
- Parameters
-
| b | input Box |
| ref_ratio | coarsening ratio |
- Returns
- the coarsened Box
◆ grow() [1/4]
| __host__ __device__ BoxND< dim > amrex::grow |
( |
const BoxND< dim > & |
b, |
|
|
const IntVectND< dim > & |
v |
|
) |
| |
|
inlinenoexcept |
Grow BoxND in all directions by given amount.
Note that a negative number shrinks the BoxND by that number of cells.
- Parameters
-
| b | input Box |
| v | number of cells to grow |
- Returns
- the grown Box
◆ grow() [2/4]
Grow BoxND in given direction by given amount.
Note that a negative number shrinks the BoxND by that number of cells.
- Parameters
-
| b | input Box |
| d | direction to grow |
| n_cell | number of cells to grow |
- Returns
- the grown Box
◆ grow() [3/4]
| __host__ __device__ BoxND< dim > amrex::grow |
( |
const BoxND< dim > & |
b, |
|
|
int |
i |
|
) |
| |
|
inlinenoexcept |
Grow BoxND in all directions by given amount.
Note that a negative shrinks the BoxND by that number of cells.
- Parameters
-
| b | input Box |
| i | number of cells to grow |
- Returns
- the grown Box
◆ grow() [4/4]
| __host__ __device__ BoxND< dim > amrex::grow |
( |
const BoxND< dim > & |
b, |
|
|
int |
idir, |
|
|
int |
n_cell |
|
) |
| |
|
inlinenoexcept |
Grow BoxND in given direction by given amount.
Note that a negative number shrinks the BoxND by that number of cells.
- Parameters
-
| b | input Box |
| idir | direction to grow |
| n_cell | number of cells to grow |
- Returns
- the grown Box
◆ refine() [1/2]
| __host__ __device__ BoxND< dim > amrex::refine |
( |
const BoxND< dim > & |
b, |
|
|
const IntVectND< dim > & |
ref_ratio |
|
) |
| |
|
inlinenoexcept |
Refine BoxND by given (positive) refinement ratio.
NOTE: if type(dir) = CELL centered: lo <- lo*ratio and hi <- (hi+1)*ratio - 1. NOTE: if type(dir) = NODE centered: lo <- lo*ratio and hi <- hi*ratio.
- Parameters
-
| b | input Box |
| ref_ratio | refinement ratio |
- Returns
- the coarsened Box
◆ refine() [2/2]
| __host__ __device__ BoxND< dim > amrex::refine |
( |
const BoxND< dim > & |
b, |
|
|
int |
ref_ratio |
|
) |
| |
|
inlinenoexcept |
Refine BoxND by given (positive) refinement ratio.
NOTE: if type(dir) = CELL centered: lo <- lo*ratio and hi <- (hi+1)*ratio - 1. NOTE: if type(dir) = NODE centered: lo <- lo*ratio and hi <- hi*ratio.
- Parameters
-
| b | input Box |
| ref_ratio | refinement ratio |
- Returns
- the coarsened Box