iMOAB
|
#include "imoab_protos.h"
Go to the source code of this file.
Defines | |
#define | iMOAB_AppID int* |
#define | iMOAB_String char* |
#define | iMOAB_GlobalID int |
#define | iMOAB_LocalID int |
#define | ErrCode int |
Enumerations | |
enum | MOAB_TAG_TYPE { DENSE_INTEGER = 0, DENSE_DOUBLE, DENSE_ENTITYHANDLE, SPARSE_INTEGER, SPARSE_DOUBLE, SPARSE_ENTITYHANDLE } |
Functions | |
ErrCode | iMOAB_Initialize (int argc, iMOAB_String *argv) |
Initialize the iMOAB interface implementation. | |
ErrCode | iMOAB_InitializeFortran () |
Initialize the iMOAB interface implementation from Fortran driver. | |
ErrCode | iMOAB_Finalize () |
Finalize the iMOAB interface implementation. | |
ErrCode | iMOAB_RegisterApplication (iMOAB_String app_name, MPI_Comm *comm, iMOAB_AppID pid) |
Register application - Create a unique application ID and bootstrap interfaces for further queries. | |
ErrCode | iMOAB_RegisterFortranApplication (iMOAB_String app_name, int *comm, iMOAB_AppID pid, int app_name_length) |
Register a Fortran-based application - Create a unique application ID and bootstrap interfaces for further queries. | |
ErrCode | iMOAB_DeregisterApplication (iMOAB_AppID pid) |
De-Register application: delete mesh (set) associated with the application ID. | |
ErrCode | iMOAB_ReadHeaderInfo (iMOAB_String filename, int *num_global_vertices, int *num_global_elements, int *num_dimension, int *num_parts, int filename_length) |
Get global information from the file. | |
ErrCode | iMOAB_LoadMesh (iMOAB_AppID pid, iMOAB_String filename, iMOAB_String read_options, int *num_ghost_layers, int filename_length, int read_options_length) |
Load a MOAB mesh file in parallel and exchange ghost layers as requested. | |
ErrCode | iMOAB_WriteMesh (iMOAB_AppID pid, iMOAB_String filename, iMOAB_String write_options, int filename_length, int write_options_length) |
Write a MOAB mesh along with the solution tags to a file. | |
ErrCode | iMOAB_GetMeshInfo (iMOAB_AppID pid, int *num_visible_vertices, int *num_visible_elements, int *num_visible_blocks, int *num_visible_surfaceBC, int *num_visible_vertexBC) |
Obtain local mesh information based on the loaded file. | |
ErrCode | iMOAB_GetVertexID (iMOAB_AppID pid, int *vertices_length, iMOAB_GlobalID *global_vertex_ID) |
Get the global vertex IDs for all locally visible (owned and shared/ghosted) vertices. | |
ErrCode | iMOAB_GetVertexOwnership (iMOAB_AppID pid, int *vertices_length, int *visible_global_rank_ID) |
Get vertex ownership information. | |
ErrCode | iMOAB_GetVisibleVerticesCoordinates (iMOAB_AppID pid, int *coords_length, double *coordinates) |
Get vertex coordinates for all local (owned and ghosted) vertices. | |
ErrCode | iMOAB_GetBlockID (iMOAB_AppID pid, int *block_length, iMOAB_GlobalID *global_block_IDs) |
Get the global block IDs for all locally visible (owned and shared/ghosted) blocks. | |
ErrCode | iMOAB_GetBlockInfo (iMOAB_AppID pid, iMOAB_GlobalID *global_block_ID, int *vertices_per_element, int *num_elements_in_block) |
Get the global block information and number of visible elements of belonging to a block (MATERIAL SET). | |
ErrCode | iMOAB_GetVisibleElementsInfo (iMOAB_AppID pid, int *num_visible_elements, iMOAB_GlobalID *element_global_IDs, int *ranks, iMOAB_GlobalID *block_IDs) |
Get the visible elements information. | |
ErrCode | iMOAB_GetBlockElementConnectivities (iMOAB_AppID pid, iMOAB_GlobalID *global_block_ID, int *connectivity_length, int *element_connectivity) |
Get the connectivities for elements within a certain block. | |
ErrCode | iMOAB_GetElementConnectivity (iMOAB_AppID pid, iMOAB_LocalID *elem_index, int *connectivity_length, int *element_connectivity) |
Get the connectivity for one element only. | |
ErrCode | iMOAB_GetElementOwnership (iMOAB_AppID pid, iMOAB_GlobalID *global_block_ID, int *num_elements_in_block, int *element_ownership) |
Get the element ownership within a certain block i.e., processor ID of the element owner. | |
ErrCode | iMOAB_GetElementID (iMOAB_AppID pid, iMOAB_GlobalID *global_block_ID, int *num_elements_in_block, iMOAB_GlobalID *global_element_ID, iMOAB_LocalID *local_element_ID) |
Get the global IDs for all locally visible elements belonging to a particular block. | |
ErrCode | iMOAB_GetPointerToSurfaceBC (iMOAB_AppID pid, int *surface_BC_length, iMOAB_LocalID *local_element_ID, int *reference_surface_ID, int *boundary_condition_value) |
Get the surface boundary condition information. | |
ErrCode | iMOAB_GetPointerToVertexBC (iMOAB_AppID pid, int *vertex_BC_length, iMOAB_LocalID *local_vertex_ID, int *boundary_condition_value) |
Get the vertex boundary condition information. | |
ErrCode | iMOAB_DefineTagStorage (iMOAB_AppID pid, iMOAB_String tag_storage_name, int *tag_type, int *components_per_entity, int *tag_index, int tag_storage_name_length) |
Define a MOAB Tag corresponding to the application depending on requested types. | |
ErrCode | iMOAB_SetIntTagStorage (iMOAB_AppID pid, iMOAB_String tag_storage_name, int *num_tag_storage_length, int *entity_type, int *tag_storage_data, int tag_storage_name_length) |
Store the specified values in a MOAB integer Tag. | |
ErrCode | iMOAB_GetIntTagStorage (iMOAB_AppID pid, iMOAB_String tag_storage_name, int *num_tag_storage_length, int *entity_type, int *tag_storage_data, int tag_storage_name_length) |
Get the specified values in a MOAB integer Tag. | |
ErrCode | iMOAB_SetDoubleTagStorage (iMOAB_AppID pid, iMOAB_String tag_storage_name, int *num_tag_storage_length, int *entity_type, double *tag_storage_data, int tag_storage_name_length) |
Store the specified values in a MOAB double Tag. | |
ErrCode | iMOAB_GetDoubleTagStorage (iMOAB_AppID pid, iMOAB_String tag_storage_name, int *num_tag_storage_length, int *entity_type, double *tag_storage_data, int tag_storage_name_length) |
Retrieve the specified values in a MOAB double Tag. | |
ErrCode | iMOAB_SynchronizeTags (iMOAB_AppID pid, int *num_tag, int *tag_indices, int *ent_type) |
Exchange tag values for given tags. | |
ErrCode | iMOAB_GetNeighborElements (iMOAB_AppID pid, iMOAB_LocalID *local_index, int *num_adjacent_elements, iMOAB_LocalID *adjacent_element_IDs) |
retrieve the adjacencies for the element entities. | |
ErrCode | iMOAB_GetNeighborVertices (iMOAB_AppID pid, iMOAB_LocalID *local_vertex_ID, int *num_adjacent_vertices, iMOAB_LocalID *adjacent_vertex_IDs) |
Get the adjacencies for the vertex entities. (not implemented yet) |
iMOAB: a language-agnostic, lightweight interface to MOAB
Supports usage from C/C++, Fortran (77/90/2003), Python
Definition in file iMOAB.h.
#define iMOAB_AppID int* |
#define iMOAB_GlobalID int |
#define iMOAB_LocalID int |
#define iMOAB_String char* |
enum MOAB_TAG_TYPE |
ErrCode iMOAB_DefineTagStorage | ( | iMOAB_AppID | pid, |
iMOAB_String | tag_storage_name, | ||
int * | tag_type, | ||
int * | components_per_entity, | ||
int * | tag_index, | ||
int | tag_storage_name_length | ||
) |
Define a MOAB Tag corresponding to the application depending on requested types.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | tag_storage_name | (iMOAB_String) The tag name to store/retrieve the data in MOAB |
[in] | tag_type | (int*) The type of MOAB tag (Dense/Sparse, Double/Int/EntityHandle), enum MOAB_TAG_TYPE |
[in] | components_per_entity | (int*) The total size of vector dimension per entity for the tag (e.g., number of doubles per entity) |
[out] | tag_index | (int*) The tag index which can be used as identifier in synchronize methods |
[in] | tag_storage_name_length | (int) The length of the tag_storage_name string |
De-Register application: delete mesh (set) associated with the application ID.
The associated communicator will be released, and all associated mesh entities and sets will be deleted from the mesh data structure. Associated tag storage data will be freed too.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
Finalize the iMOAB interface implementation.
It will delete the internally reference counted MOAB instance, if the reference count reaches 0.
Operations: Collective
ErrCode iMOAB_GetBlockElementConnectivities | ( | iMOAB_AppID | pid, |
iMOAB_GlobalID * | global_block_ID, | ||
int * | connectivity_length, | ||
int * | element_connectivity | ||
) |
Get the connectivities for elements within a certain block.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | global_block_ID | (iMOAB_GlobalID*) The global block ID of the set being queried |
[in] | connectivity_length | (int*) The allocated size of array (typical size := vertices_per_element*num_elements_in_block ) |
[out] | element_connectivity | (int*) The connectivity array to store element ordering in MOAB canonical numbering scheme (array allocated by client); array contains vertex indices in the local numbering order for vertices elements are in the same order as provided by GetElementOwnership and GetElementID |
ErrCode iMOAB_GetBlockID | ( | iMOAB_AppID | pid, |
int * | block_length, | ||
iMOAB_GlobalID * | global_block_IDs | ||
) |
Get the global block IDs for all locally visible (owned and shared/ghosted) blocks.
Block IDs are corresponding to MATERIAL_SET tags for material sets. Usually the block ID is exported from Cubit as a unique integer value. First blocks are local, and next blocks are fully ghosted. First blocks have at least one owned cell/element, ghost blocks have only ghost cells. Internally, a block corresponds to a mesh set with a MATERIAL_SET tag value equal to the block ID.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | block_length | (int*) The allocated size of array (typical size := num_visible_blocks ) |
[out] | global_block_IDs | (iMOAB_GlobalID*) The global IDs for all locally visible blocks (array allocated by client) |
ErrCode iMOAB_GetBlockInfo | ( | iMOAB_AppID | pid, |
iMOAB_GlobalID * | global_block_ID, | ||
int * | vertices_per_element, | ||
int * | num_elements_in_block | ||
) |
Get the global block information and number of visible elements of belonging to a block (MATERIAL SET).
A block has to be homogeneous, it can contain elements of a single type
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | global_block_ID | (iMOAB_GlobalID) The global block ID of the set to be queried |
[out] | vertices_per_element | (int*) The number of vertices per element |
[out] | num_elements_in_block | (int*) The number of elements in block |
ErrCode iMOAB_GetDoubleTagStorage | ( | iMOAB_AppID | pid, |
iMOAB_String | tag_storage_name, | ||
int * | num_tag_storage_length, | ||
int * | entity_type, | ||
double * | tag_storage_data, | ||
int | tag_storage_name_length | ||
) |
Retrieve the specified values in a MOAB double Tag.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | tag_storage_name | (iMOAB_String) The tag name to store/retreive the data in MOAB |
[in] | num_tag_storage_length | (int) The size of tag storage data (e.g., num_visible_vertices*components_per_entity or num_visible_elements*components_per_entity) |
[in] | entity_type | (int*) type 0 for vertices, 1 for primary elements |
[out] | tag_storage_data | (double*) The array data of type double to be copied from the internal tag memory; The data is assumed to be contiguous over the local set of visible entities (either vertices or elements) |
[in] | tag_storage_name_length | (int) The length of the tag_storage_name string |
ErrCode iMOAB_GetElementConnectivity | ( | iMOAB_AppID | pid, |
iMOAB_LocalID * | elem_index, | ||
int * | connectivity_length, | ||
int * | element_connectivity | ||
) |
Get the connectivity for one element only.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID. |
[in] | elem_index | (iMOAB_LocalID *) Local element index. |
[in,out] | connectivity_length | (int *) On input, maximum length of connectivity. On output, actual length. |
[out] | element_connectivity | (int*) The connectivity array to store connectivity in MOAB canonical numbering scheme. Array contains vertex indices in the local numbering order for vertices |
ErrCode iMOAB_GetElementID | ( | iMOAB_AppID | pid, |
iMOAB_GlobalID * | global_block_ID, | ||
int * | num_elements_in_block, | ||
iMOAB_GlobalID * | global_element_ID, | ||
iMOAB_LocalID * | local_element_ID | ||
) |
Get the global IDs for all locally visible elements belonging to a particular block.
The method will return also the local index of each element, in the local range that contains all visible elements
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | global_block_ID | (iMOAB_GlobalID*) The global block ID of the set being queried |
[in] | num_elements_in_block | (int*) The allocated size of global element ID array, same as num_elements_in_block returned from GetBlockInfo() |
[out] | global_element_ID | (iMOAB_GlobalID*) The global IDs for all locally visible elements (array allocated by client) |
[out] | local_element_ID | (iMOAB_LocalID*) (Optional ) The local IDs for all locally visible elements (index in the range of all primary elements in the rank) |
ErrCode iMOAB_GetElementOwnership | ( | iMOAB_AppID | pid, |
iMOAB_GlobalID * | global_block_ID, | ||
int * | num_elements_in_block, | ||
int * | element_ownership | ||
) |
Get the element ownership within a certain block i.e., processor ID of the element owner.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | global_block_ID | (iMOAB_GlobalID) The global block ID of the set being queried |
[in] | num_elements_in_block | (int*) The allocated size of ownership array, same as num_elements_in_block returned from GetBlockInfo() |
[out] | element_ownership | (int*) The ownership array to store processor ID for all elements (array allocated by client) |
ErrCode iMOAB_GetIntTagStorage | ( | iMOAB_AppID | pid, |
iMOAB_String | tag_storage_name, | ||
int * | num_tag_storage_length, | ||
int * | entity_type, | ||
int * | tag_storage_data, | ||
int | tag_storage_name_length | ||
) |
Get the specified values in a MOAB integer Tag.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | tag_storage_name | (iMOAB_String) The tag name to store/retreive the data in MOAB |
[in] | num_tag_storage_length | (int*) The size of tag storage data (e.g., num_visible_vertices*components_per_entity or num_visible_elements*components_per_entity) |
[in] | entity_type | (int*) type 0 for vertices, 1 for primary elements |
[out] | tag_storage_data | (int*) The array data of type int to be copied from the internal tag memory; The data is assumed to be contiguous over the local set of visible entities (either vertices or elements) |
[in] | tag_storage_name_length | (iMOAB_String) The length of the tag_storage_name string |
ErrCode iMOAB_GetMeshInfo | ( | iMOAB_AppID | pid, |
int * | num_visible_vertices, | ||
int * | num_visible_elements, | ||
int * | num_visible_blocks, | ||
int * | num_visible_surfaceBC, | ||
int * | num_visible_vertexBC | ||
) |
Obtain local mesh information based on the loaded file.
Number of visible vertices and cells include ghost entities. All arrays returned have size 3. Local entities are first, then ghost entities are next. Shared vertices can be owned in MOAB sense by different tasks. Ghost vertices and cells are always owned by other tasks.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[out] | num_visible_vertices | (int*) The number of vertices in the current partition/process arranged as: owned/shared only, ghosted, total_visible (array allocated by client, size := 3 ) |
[out] | num_visible_elements | (int*) The number of elements in current partition/process arranged as: owned only, ghosted/shared, total_visible (array allocated by client, size := 3 ) |
[out] | num_visible_blocks | (int*) The number of material sets in local mesh in current partition/process arranged as: owned only, ghosted/shared, total_visible (array allocated by client, size := 3 ) |
[out] | num_visible_surfaceBC | (int*) The number of mesh surfaces that have a NEUMANN_SET BC defined in local mesh in current partition/process arranged as: owned only, ghosted/shared, total_visible (array allocated by client, size := 3 ) |
[out] | num_visible_vertexBC | (int*) The number of vertices that have a DIRICHLET_SET BC defined in local mesh in current partition/process arranged as: owned only, ghosted/shared, total_visible (array allocated by client, size := 3 ) |
ErrCode iMOAB_GetNeighborElements | ( | iMOAB_AppID | pid, |
iMOAB_LocalID * | local_index, | ||
int * | num_adjacent_elements, | ||
iMOAB_LocalID * | adjacent_element_IDs | ||
) |
retrieve the adjacencies for the element entities.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | local_index | (iMOAB_LocalID*) The local element ID for which adjacency information is needed |
[out] | num_adjacent_elements | (int*) The total number of adjacent elements |
[out] | adjacent_element_IDs | (iMOAB_LocalID*) The local element IDs of all adjacent elements to the current one (typically, num_total_sides for internal elements or num_total_sides-num_sides_on_boundary for boundary elements) |
ErrCode iMOAB_GetNeighborVertices | ( | iMOAB_AppID | pid, |
iMOAB_LocalID * | local_vertex_ID, | ||
int * | num_adjacent_vertices, | ||
iMOAB_LocalID * | adjacent_vertex_IDs | ||
) |
Get the adjacencies for the vertex entities. (not implemented yet)
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | local_vertex_ID | (iMOAB_LocalID*) The local vertex ID for which adjacency information is needed |
[out] | num_adjacent_vertices | (int*) The total number of adjacent vertices |
[out] | adjacent_vertex_IDs | (iMOAB_LocalID*) The local element IDs of all adjacent vertices to the current one (typically, num_total_sides for internal elements or num_total_sides-num_sides_on_boundary for boundary elements) |
ErrCode iMOAB_GetPointerToSurfaceBC | ( | iMOAB_AppID | pid, |
int * | surface_BC_length, | ||
iMOAB_LocalID * | local_element_ID, | ||
int * | reference_surface_ID, | ||
int * | boundary_condition_value | ||
) |
Get the surface boundary condition information.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | surface_BC_length | (int*) The allocated size of surface boundary condition array, same as num_visible_surfaceBC returned by GetMeshInfo() |
[out] | local_element_ID | (iMOAB_LocalID*) The local element IDs that contains the side with the surface BC |
[out] | reference_surface_ID | (int*) The surface number with the BC in the canonical reference element (e.g., 1 to 6 for HEX, 1-4 for TET) |
[out] | boundary_condition_value | (int*) The boundary condition type as obtained from the mesh description (value of the NeumannSet defined on the element) |
ErrCode iMOAB_GetPointerToVertexBC | ( | iMOAB_AppID | pid, |
int * | vertex_BC_length, | ||
iMOAB_LocalID * | local_vertex_ID, | ||
int * | boundary_condition_value | ||
) |
Get the vertex boundary condition information.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | vertex_BC_length | (int) The allocated size of vertex boundary condition array, same as num_visible_vertexBC returned by GetMeshInfo() |
[out] | local_vertex_ID | (iMOAB_LocalID*) The local vertex ID that has Dirichlet BC defined |
[out] | boundary_condition_value | (int*) The boundary condition type as obtained from the mesh description (value of the Dirichlet_Set tag defined on the vertex) |
ErrCode iMOAB_GetVertexID | ( | iMOAB_AppID | pid, |
int * | vertices_length, | ||
iMOAB_GlobalID * | global_vertex_ID | ||
) |
Get the global vertex IDs for all locally visible (owned and shared/ghosted) vertices.
The array should be allocated by the client, sized with the total number of visible vertices from iMOAB_GetMeshInfo method.
Operations: Not collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | vertices_length | (int*) The allocated size of array (typical size := num_visible_vertices ) |
[out] | global_vertex_ID | (iMOAB_GlobalID*) The global IDs for all locally visible vertices (array allocated by client) |
ErrCode iMOAB_GetVertexOwnership | ( | iMOAB_AppID | pid, |
int * | vertices_length, | ||
int * | visible_global_rank_ID | ||
) |
Get vertex ownership information.
For each vertex based on the local ID, return the process that owns the vertex (local, shared or ghost)
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | vertices_length | (int*) The allocated size of array (typically size := num_visible_vertices ) |
[out] | visible_global_rank_ID | (int*) The processor rank owning each of the local vertices |
ErrCode iMOAB_GetVisibleElementsInfo | ( | iMOAB_AppID | pid, |
int * | num_visible_elements, | ||
iMOAB_GlobalID * | element_global_IDs, | ||
int * | ranks, | ||
iMOAB_GlobalID * | block_IDs | ||
) |
Get the visible elements information.
Return for all visible elements the global IDs, ranks they belong to, block ids they belong to.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | num_visible_elements | (int*) The number of visible elements (returned by GetMeshInfo) |
[out] | element_global_IDs | (iMOAB_GlobalID*) element global ids |
[out] | ranks | (int*) The owning ranks of elements |
[out] | block_IDs | (iMOAB_GlobalID*) The block ids the elements belong to |
ErrCode iMOAB_GetVisibleVerticesCoordinates | ( | iMOAB_AppID | pid, |
int * | coords_length, | ||
double * | coordinates | ||
) |
Get vertex coordinates for all local (owned and ghosted) vertices.
Operations: Not Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | coords_length | (int*) The size of the allocated coordinate array (array allocated by client, size := 3*num_visible_vertices ) |
[out] | coordinates | (double*) The pointer to client allocated memory that will be filled with interleaved coordinates |
ErrCode iMOAB_Initialize | ( | int | argc, |
iMOAB_String * | argv | ||
) |
Initialize the iMOAB interface implementation.
Will create the MOAB instance, if not created already (reference counted).
Operations: Collective
[in] | argc | (int) Number of command line arguments |
[in] | argv | (iMOAB_String*) Command line arguments |
Initialize the iMOAB interface implementation from Fortran driver.
It will create the MOAB instance, if not created already (reference counted).
Operations: Collective
ErrCode iMOAB_LoadMesh | ( | iMOAB_AppID | pid, |
iMOAB_String | filename, | ||
iMOAB_String | read_options, | ||
int * | num_ghost_layers, | ||
int | filename_length, | ||
int | read_options_length | ||
) |
Load a MOAB mesh file in parallel and exchange ghost layers as requested.
All communication is MPI-based, and read options include parallel loading information, resolving shared entities. Local MOAB instance is populated with mesh cells and vertices in the corresponding local partitions.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | filename | (iMOAB_String) The MOAB mesh file (H5M) to load onto the internal application mesh set |
[in] | read_options | (iMOAB_String) Additional options for reading the MOAB mesh file in parallel |
[in] | num_ghost_layers | (int*) The total number of ghost layers to exchange during mesh loading |
[in] | filename_length | (int) Length of the filename string |
[in] | read_options_length | (int) Length of the read options string |
ErrCode iMOAB_ReadHeaderInfo | ( | iMOAB_String | filename, |
int * | num_global_vertices, | ||
int * | num_global_elements, | ||
int * | num_dimension, | ||
int * | num_parts, | ||
int | filename_length | ||
) |
Get global information from the file.
It should be called on master task only, and information obtained could be broadcasted by the user. It is a fast lookup in the header of the file.
Operations: Not collective
[in] | filename | (iMOAB_String) The MOAB mesh file (H5M) to probe for header information |
[out] | num_global_vertices | (int*) The total number of vertices in the mesh file |
[out] | num_global_elements | (int*) The total number of elements (of highest dimension only) |
[out] | num_dimension | (int*) The highest dimension of elements in the mesh (Edge=1, Tri/Quad=2, Tet/Hex/Prism/Pyramid=3) |
[out] | num_parts | (int*) The total number of partitions available in the mesh file, typically partitioned with mbpart during pre-processing |
[in] | filename_length | (int) Length of the file name string |
ErrCode iMOAB_RegisterApplication | ( | iMOAB_String | app_name, |
MPI_Comm * | comm, | ||
iMOAB_AppID | pid | ||
) |
Register application - Create a unique application ID and bootstrap interfaces for further queries.
Operations: Collective
[in] | app_name | (iMOAB_String) Application name (PROTEUS, NEK5000, etc) |
[in] | comm | (MPI_Comm*) MPI communicator to be used for all mesh-related queries originating from this application |
[out] | pid | (iMOAB_AppID) The unique pointer to the application ID |
ErrCode iMOAB_RegisterFortranApplication | ( | iMOAB_String | app_name, |
int * | comm, | ||
iMOAB_AppID | pid, | ||
int | app_name_length | ||
) |
Register a Fortran-based application - Create a unique application ID and bootstrap interfaces for further queries.
Operations: Collective
[in] | app_name | (iMOAB_String) Application name (PROTEUS, NEK5000, etc) |
[in] | comm | (int*) Fortran MPI communicator to be used for all mesh-related queries originating from this application |
[out] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | app_name_length | (int) Length of application name string. |
ErrCode iMOAB_SetDoubleTagStorage | ( | iMOAB_AppID | pid, |
iMOAB_String | tag_storage_name, | ||
int * | num_tag_storage_length, | ||
int * | entity_type, | ||
double * | tag_storage_data, | ||
int | tag_storage_name_length | ||
) |
Store the specified values in a MOAB double Tag.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | tag_storage_name | (iMOAB_String) The tag name to store/retreive the data in MOAB |
[in] | num_tag_storage_length | (int*) The size of tag storage data (e.g., num_visible_vertices*components_per_entity or num_visible_elements*components_per_entity) |
[in] | entity_type | (int*) type 0 for vertices, 1 for primary elements |
[out] | tag_storage_data | (double*) The array data of type double to replace the internal tag memory; The data is assumed to be contiguous over the local set of visible entities (either vertices or elements) |
[in] | tag_storage_name_length | (iMOAB_String) The length of the tag_storage_name string |
ErrCode iMOAB_SetIntTagStorage | ( | iMOAB_AppID | pid, |
iMOAB_String | tag_storage_name, | ||
int * | num_tag_storage_length, | ||
int * | entity_type, | ||
int * | tag_storage_data, | ||
int | tag_storage_name_length | ||
) |
Store the specified values in a MOAB integer Tag.
Values are set on vertices or elements, depending on entity_type
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | tag_storage_name | (iMOAB_String) The tag name to store/retreive the data in MOAB |
[in] | num_tag_storage_length | (int*) The size of tag storage data (e.g., num_visible_vertices*components_per_entity or num_visible_elements*components_per_entity) |
[in] | entity_type | (int*) type 0 for vertices, 1 for primary elements |
[out] | tag_storage_data | (int*) The array data of type int to replace the internal tag memory; The data is assumed to be contiguous over the local set of visible entities (either vertices or elements) |
[in] | tag_storage_name_length | (iMOAB_String) The length of the tag_storage_name string |
ErrCode iMOAB_SynchronizeTags | ( | iMOAB_AppID | pid, |
int * | num_tags, | ||
int * | tag_indices, | ||
int * | ent_type | ||
) |
Exchange tag values for given tags.
Operations: Collective
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | num_tags | (int*) Number of tags to exchange |
[in] | tag_indices | (int*) Array with tag indices of interest (size = *num_tags) |
[in] | ent_type | (int*) type of entity for tag exchange |
ErrCode iMOAB_WriteMesh | ( | iMOAB_AppID | pid, |
iMOAB_String | filename, | ||
iMOAB_String | write_options, | ||
int | filename_length, | ||
int | write_options_length | ||
) |
Write a MOAB mesh along with the solution tags to a file.
Operations: Collective for parallel write, non collective for serial write.
[in] | pid | (iMOAB_AppID) The unique pointer to the application ID |
[in] | filename | (iMOAB_String) The MOAB mesh file (H5M) to write all the entities contained in the internal application mesh set |
[in] | write_options | (iMOAB_String) Additional options for writing the MOAB mesh in parallel |
[in] | filename_length | (int) Length of the filename string |
[in] | write_options_length | (int) Length of the write options string |