mymesh.converter.surf2tris#
- mymesh.converter.surf2tris(NodeCoords, NodeConn, return_ids=False, return_inv=False)[source]#
Decompose all elements of a surface mesh to triangles.
- Parameters:
NodeCoords (list) – List of nodal coordinates.
NodeConn (list) – Nodal connectivity list.
return_ids (bool, optional) – Element IDs of the tris connected to the original elements, by default False
return_inv (bool, optional) – If True, return element IDs of the original elements that correspond to the triangular elements, by default False
- Returns:
TriCoords (list) – Nodal coordinates of the generated triangles.
TriConn (list) – Nodal connectivity list of generated triangles.
ElemIds (list, optional) – If return_ids = True, a list of the element ids of the new triangles for each of the original elements.
inv (np.ndarray, optional) – Array of indices that point from the triangular mesh back to the original mesh