Encapsulate mesh connectivity, component parts, metrics, surfaces, and linear algebraic descriptors
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(vector), | public, | allocatable | :: | af(:) | |||
real(kind=psb_dpk_), | public, | allocatable | :: | area(:) | |||
type(connectivity), | public | :: | c2c | ||||
type(connectivity), | public | :: | c2g | ||||
type(keytable), | public | :: | c2ov_sup | ||||
type(vector), | public, | allocatable | :: | cell_cntr(:) | |||
type(cell), | public, | allocatable | :: | cells(:) | |||
type(psb_desc_type), | public | :: | desc_c | ||||
type(psb_desc_type), | public | :: | desc_f | ||||
type(psb_desc_type), | public | :: | desc_v | ||||
type(vector), | public, | allocatable | :: | df(:) | |||
real(kind=psb_dpk_), | public, | allocatable | :: | dist(:) | |||
type(connectivity), | public | :: | f2b | ||||
type(connectivity), | public | :: | f2c | ||||
type(connectivity), | public | :: | f2f | ||||
type(keytable), | public | :: | f2ov_sup | ||||
type(vector), | public, | allocatable | :: | face_cntr(:) | |||
type(face), | public, | allocatable | :: | faces(:) | |||
character(len=nlen), | public | :: | id | ||||
real(kind=psb_dpk_), | public, | allocatable | :: | interp(:) | |||
type(least_squares), | public, | allocatable | :: | lsr(:) | |||
integer, | public | :: | nbc | ||||
integer, | public | :: | ncd | ||||
integer, | public | :: | ngp | ||||
type(keytable), | public | :: | ov2c_sup | ||||
type(keytable), | public | :: | ov2f_sup | ||||
logical, | public | :: | set | = | .false. | ||
type(surface), | public, | allocatable | :: | surf(:) | |||
type(connectivity), | public | :: | v2b | ||||
type(connectivity), | public | :: | v2c | ||||
type(connectivity), | public | :: | v2f | ||||
type(connectivity), | public | :: | v2v | ||||
type(vertex), | public, | allocatable | :: | verts(:) | |||
real(kind=psb_dpk_), | public, | allocatable | :: | vol(:) |
Check routines
----- Constructors -----
Scans through numerous connectivities, ensuring that in each one, all faces & cells are referenced at least once.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(mesh), | intent(in) | :: | msh |
Constructor
----- Constructors -----
Global constructor
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(mesh), | intent(out) | :: | msh | |||
character(len=*), | intent(in) | :: | input_file | |||
character(len=*), | intent(in) | :: | sec |
Destructor
----- Constructors -----
----- Destructor -----
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(mesh), | intent(inout) | :: | msh |
Mark the object as user-defined
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(object), | intent(inout) | :: | this |
----- Constructors -----
Return a boolean result indicating whether this object has been initialized since its declaration
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(object), | intent(in) | :: | this |
----- Constructors -----
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(mesh), | intent(in) | :: | msh |
TYPE, EXTENDS(grid) :: mesh
!! Encapsulate mesh connectivity, component parts, metrics, surfaces, and linear algebraic descriptors
LOGICAL :: set = .FALSE. ! Indicates if the mesh been created yet
CHARACTER(len=nlen) :: id ! Mesh ID
INTEGER :: nbc ! Number of BCs
INTEGER :: ngp ! Number of element groups
INTEGER :: ncd ! Dimensionality of the mesh (2d or 3d)
! Connectivity data
TYPE(connectivity) :: v2c, v2f, f2c, c2g ! From mesh importing
TYPE(connectivity) :: v2v, f2f, c2c ! Adjacency graphs
TYPE(keytable) :: ov2c_sup,c2ov_sup ! Supplemental v2c/c2v connectivity
TYPE(keytable) :: ov2f_sup,f2ov_sup ! Supplemental v2f/f2v connectivity
TYPE(connectivity) :: v2b, f2b ! Boundary related
! Mesh sub-elements
TYPE(vertex), ALLOCATABLE :: verts(:) ! Vertex coordinates
TYPE(face), ALLOCATABLE :: faces(:) ! Faces description
TYPE(cell), ALLOCATABLE :: cells(:) ! Cells description
! PSBLAS descriptors
TYPE(psb_desc_type) :: desc_v ! Vertices
TYPE(psb_desc_type) :: desc_f ! Faces
TYPE(psb_desc_type) :: desc_c ! Cells
! Face-related metrics (see below for details)
REAL(psb_dpk_), ALLOCATABLE :: area(:)
REAL(psb_dpk_), ALLOCATABLE :: dist(:)
REAL(psb_dpk_), ALLOCATABLE :: interp(:)
TYPE(vector), ALLOCATABLE :: face_cntr(:)
TYPE(vector), ALLOCATABLE :: af(:)
TYPE(vector), ALLOCATABLE :: df(:)
! Cell-related metrics (see below for details)
REAL(psb_dpk_), ALLOCATABLE :: vol(:)
TYPE(vector), ALLOCATABLE :: cell_cntr(:)
! Metrics for cell-centered Least Squares Regression
TYPE(least_squares), ALLOCATABLE :: lsr(:)
! Surface geometry and location
TYPE(surface), ALLOCATABLE :: surf(:)
CONTAINS
PROCEDURE :: create_mesh !! Constructor
PROCEDURE :: free_mesh !! Destructor
PROCEDURE :: check_mesh_unused_el !! Check routines
PROCEDURE, PRIVATE :: nemo_mesh_sizeof
GENERIC, PUBLIC :: nemo_sizeof => nemo_mesh_sizeof
! PROCEDURE :: check_mesh_consistency
END TYPE mesh