Defines regions where boundary conditions are applied. Regions must be 2D planes in 3D simulations, defined by their extent xlo, xhi, and the normal to the plane (which gives side and dir) E.g.: a region with normal '+x1' (dir=1,side=BC_LEFT) looks like this:
side side
BC_LEFT BC_RIGHT
______
xhi(2) | | | | ilo(2)=3 |__| | | | | ilo(2)=2 |_| | | | | ilo(1)=1 xlo(2) ||____> dir=1 ^ Region on this side
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(bc_obj), | public, | allocatable | :: | BC(:) |
Variables on this region |
||
integer, | public | :: | count | = | 0 |
Count of variables defined on this region |
|
integer, | public | :: | dir |
Normal direction (=1,2,3) |
|||
integer, | public | :: | hi(3) | = | -100 |
Grid hi bound |
|
integer, | public | :: | lo(3) | = | -100 |
Grid low bound |
|
character(len=:), | public, | allocatable | :: | name |
Name of this region |
||
type(block_obj), | public | :: | region |
Block/grid for this region |
|||
integer, | public | :: | side |
Side (BC_LEFT or BC_RIGHT) |
|||
real(kind=wp), | public | :: | xhi(3) |
Position of upper right corner |
|||
real(kind=wp), | public | :: | xlo(3) |
Position of lower left corner |
|||
type(hashtbl_obj), | private | :: | tbl |
Hash table |
Adds a new variable to region
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(region_obj), | intent(inout) | :: | this |
A Region |
||
character(len=*), | intent(in) | :: | name |
Region name |
||
integer, | intent(in) | :: | type |
BC type |
||
type(extent_obj), | intent(in) | :: | extents |
Region extents |
Resize array to accomodate a new element
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(region_obj), | intent(inout) | :: | this |
A Region |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(region_obj), | intent(inout) | :: | this |
A Region |
Returns index of a variable in this region, or -1 if not found.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(region_obj), | intent(in) | :: | this |
A Region |
||
character(len=*), | intent(in) | :: | name |
Name of region |
Initializes a region
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(region_obj), | intent(inout) | :: | this |
A Region |
||
character(len=*), | intent(in) | :: | name |
Name of region |
||
real(kind=wp), | intent(in) | :: | xlo(3) |
Position of low left corner |
||
real(kind=wp), | intent(in) | :: | xhi(3) |
Position of high right corner |
||
integer, | intent(in) | :: | dir |
Direction of normal |
||
integer, | intent(in) | :: | side |
Side (left or right) of the cell |