zoomy_core.mesh.mesh_util module

zoomy_core.mesh.mesh_util module#

Module zoomy_core.mesh.mesh_util.

zoomy_core.mesh.mesh_util.convert_mesh_type_to_meshio_mesh_type(mesh_type)#

Convert mesh type to meshio mesh type.

Parameters:

mesh_type (str) –

Return type:

str

zoomy_core.mesh.mesh_util.get_extruded_mesh_type(mesh_type)#

Get extruded mesh type.

Parameters:

mesh_type (str) –

Return type:

str

zoomy_core.mesh.mesh_util.get_global_cell_index_from_vertices(cells, coordinates, return_first=True, offset=0)#

Get global cell index from vertices.

zoomy_core.mesh.mesh_util.get_element_neighbors(element_vertices, current_elem, mesh_type)#

Get element neighbors.

zoomy_core.mesh.mesh_util.face_normals(coordinates, element, mesh_type)#

Face normals.

Return type:

float

zoomy_core.mesh.mesh_util.face_areas(coordinates, element, mesh_type)#

Face areas.

Return type:

float

zoomy_core.mesh.mesh_util.center(coordinates, element)#

Center.

Return type:

float

zoomy_core.mesh.mesh_util.volume(coordinates, element, mesh_type)#

Volume.

Return type:

float

zoomy_core.mesh.mesh_util.inradius(coordinates, element, mesh_type)#

Inradius.

Return type:

float

zoomy_core.mesh.mesh_util.edge_length(coordinates, edge)#

Edge length.

Return type:

float

zoomy_core.mesh.mesh_util.find_edge_index(element, edge_vertices, element_type)#

Find edge index.

zoomy_core.mesh.mesh_util.compute_subvolume(face_vertices, cell_center, dim)#

Computes the subvolume of a face given its vertices and the cell center.

Parameters: face_vertices (np.ndarray): The coordinates of the vertices of the face. cell_center (np.ndarray): The coordinates of the cell center. dim (int): The dimensionality of the problem (1, 2, or 3).

Returns: float: The subvolume of the face.