mymesh.converter.solid2faces#

mymesh.converter.solid2faces(NodeCoords, NodeConn, return_FaceConn=False, return_FaceElem=False, ElemType='auto')[source]#

Convert solid mesh to faces. The will be one face for each side of each element, i.e. there will be duplicate faces for non-surface faces. Use faces2surface(Faces) to extract only the surface faces or face2unique(Faces) to remove duplicates.

Parameters:
  • NodeCoords (list) – List of nodal coordinates.

  • NodeConn (list) – Nodal connectivity list.

  • return_FaceConn (bool, optional) – If true, will return FaceConn, the Face Connectivity of each element. For each element, FaceConn has the indices of the faces connected to that element, by default False

  • return_FaceElem (bool, optional) – If true, will return FaceElem, the Element Connectivity of each face. For each face, FaceElem has the index of the element that the face is a part of, by default False

  • ElemType (str, optional) –

    Specifies the element type contained within the mesh, by default ‘auto’.

    • ’auto’ or ‘mixed’ - Will detect element type by the number of nodes present in each element using identify_type().

    • ’surf’ - Will detect element type by the number of nodes present in each

    element, assuming four node elements are quads

    • ’vol’ - Will detect element type by the number of nodes present in each

    element, assuming four node elements are tets (functionally the ame as ‘auto’)

    • ’tri’ - All elements treated as 3-node triangular elements.

    • ’quad’ - All elements treated as 4-node quadrilateral elements.

    • ’tet’ - All elements treated as 4-node tetrahedral elements.

    • ’pyramid’ - All elements treated as 5-node wedge elements.

    • ’wedge’ - All elements treated as 6-node quadrilateral elements.

    • ’hex’ - All elements treated as 8-node quadrilateral elements.

Returns:

  • Faces (list) – List of mesh faces.

  • FaceConn (list, optional) – The face connectivity of each element.

  • FaceElem (list, optional) – The element index that each face is taken from.