mymesh.utils.MergeMesh#

mymesh.utils.MergeMesh(NodeCoords1, NodeConn1, NodeCoords2, NodeConn2, NodeVals1=[], NodeVals2=[], cleanup=True)[source]#

Merge two meshes together

Parameters:
  • NodeCoords1 (list) – List of nodal coordinates for mesh 1.

  • NodeConn1 (list) – List of nodal connectivities for mesh 1.

  • NodeCoords2 (list) – List of nodal coordinates for mesh 2.

  • NodeConn2 (list) – List of nodal connectivities for mesh 2.

  • NodeVals1 (list, optional) – List of node data associated with mesh 1, by default []

  • NodeVals2 (list, optional) – List of node data associated with mesh 2, by default []

  • cleanup (bool, optional) – If true, duplicate nodes will be deleted and renumbered accordingly, by default True.

Returns:

  • MergedCoords (list) – List of nodal coordinates of the merged mesh. Nodes from mesh 1 appear first, followed by those of mesh 2.

  • MergedConn (list) – List of nodal connectivities of the merged mesh.

  • MergedVals (list, optional) – If provided, merged list of NodeVals.