WOLFRAM

RepairMesh[mreg]

repairs defects in the mesh region mreg.

RepairMesh[mreg,{def1,}]

repairs only the specified defects def1,.

Details and Options

  • RepairMesh repairs defects in mesh-based regions.
  • Possible geometrical defects on surface include:
  • "HoleEdges"close holes in the surface
    "TJunctionEdges"remove T junctions
    "TinyFaces"fix faces with near-zero area
    "OverlappingFaces"fix faces that overlap
  • Possible topological defects include:
  • "IsolatedVertices"remove vertices without incident edges
    "DanglingEdges"remove edges without incident faces
    "SingularEdges"fix edges with more than two incident faces
    "SingularVertices"fix vertices with a non-disc neighborhood
    "TinyComponents"remove tiny connected mesh components
    "FlippedFaces"fix faces that point inward
  • RepairMesh has the same options as MeshRegion.

Examples

open allclose all

Basic Examples  (1)Summary of the most common use cases

Fill holes:

Out[2]=2

Scope  (8)Survey of the scope of standard use cases

Specification  (8)

"DanglingEdges":

Out[1]=1

"FlippedFaces":

Out[1]=1

"HoleEdges:

Out[1]=1

"IsolatedVertices":

Out[1]=1

"SingularVertices":

Out[1]=1

"TinyComponents":

Out[1]=1

"TinyFaces":

Out[1]=1

"TJunctionEdges":

Out[1]=1

Options  (11)Common values & functionality for each option

MeshCellHighlight  (2)

MeshCellHighlight allows you to specify highlighting for parts of a MeshRegion:

Out[2]=2

Individual cells can be highlighted using their cell index:

Out[2]=2

Or by the cell itself:

Out[4]=4

MeshCellLabel  (2)

MeshCellLabel can be used to label parts of a MeshRegion:

Out[2]=2

Individual cells can be labeled using their cell index:

Out[2]=2

Or by the cell itself:

Out[4]=4

MeshCellMarker  (1)

MeshCellMarker can be used to assign values to parts of a MeshRegion:

Out[2]=2

Use MeshCellLabel to show the markers:

Out[2]=2

MeshCellShapeFunction  (2)

MeshCellShapeFunction allows you to specify functions for parts of a MeshRegion:

Out[2]=2

Individual cells can be drawn using their cell index:

Out[2]=2

Or by the cell itself:

Out[4]=4

MeshCellStyle  (2)

MeshCellStyle allows you to specify functions for parts of a MeshRegion:

Out[2]=2

Individual cells can be highlighted using their cell index:

Out[2]=2

Or by the cell itself:

Out[4]=4

PlotTheme  (2)

Use a theme with grid lines and a legend:

Out[1]=1

Use a theme to draw a wireframe:

Out[1]=1
Wolfram Research (2016), RepairMesh, Wolfram Language function, https://reference.wolfram.com/language/ref/RepairMesh.html.
Wolfram Research (2016), RepairMesh, Wolfram Language function, https://reference.wolfram.com/language/ref/RepairMesh.html.

Text

Wolfram Research (2016), RepairMesh, Wolfram Language function, https://reference.wolfram.com/language/ref/RepairMesh.html.

Wolfram Research (2016), RepairMesh, Wolfram Language function, https://reference.wolfram.com/language/ref/RepairMesh.html.

CMS

Wolfram Language. 2016. "RepairMesh." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/RepairMesh.html.

Wolfram Language. 2016. "RepairMesh." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/RepairMesh.html.

APA

Wolfram Language. (2016). RepairMesh. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RepairMesh.html

Wolfram Language. (2016). RepairMesh. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RepairMesh.html

BibTeX

@misc{reference.wolfram_2025_repairmesh, author="Wolfram Research", title="{RepairMesh}", year="2016", howpublished="\url{https://reference.wolfram.com/language/ref/RepairMesh.html}", note=[Accessed: 20-March-2025 ]}

@misc{reference.wolfram_2025_repairmesh, author="Wolfram Research", title="{RepairMesh}", year="2016", howpublished="\url{https://reference.wolfram.com/language/ref/RepairMesh.html}", note=[Accessed: 20-March-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_repairmesh, organization={Wolfram Research}, title={RepairMesh}, year={2016}, url={https://reference.wolfram.com/language/ref/RepairMesh.html}, note=[Accessed: 20-March-2025 ]}

@online{reference.wolfram_2025_repairmesh, organization={Wolfram Research}, title={RepairMesh}, year={2016}, url={https://reference.wolfram.com/language/ref/RepairMesh.html}, note=[Accessed: 20-March-2025 ]}