upxo.meshing.gbconformant.d3v2p0.gmsh_tets module
Conforming tetrahedral meshing and verification of repaired grain shells.
- class upxo.meshing.gbconformant.d3v2p0.gmsh_tets.GrainTetrahedra(points: numpy.ndarray, tetrahedra: numpy.ndarray, grain_ids: numpy.ndarray, quality: numpy.ndarray, report: dict)[source]
Bases:
object
- upxo.meshing.gbconformant.d3v2p0.gmsh_tets.mesh_repaired_rve_gmsh(surface, mesh_size=1.5, verbose=False, optimize_netgen=True, minimum_quality=0.05, netgen_all_volumes=False, optimize_threshold=None, minimum_dihedral=None)[source]
Mesh all grains together; verify exact surface conformity and volumes.
Disconnected grain pieces receive separate Gmsh volumes with the same output grain ID. Negative shells are attached as cavities to their enclosing positive shell. Existing triangles stay fixed. Quality is Gmsh minSICN. Optional Netgen optimization targets only volumes below minimum_quality. Readiness requires conformity, positive volumes, complete grain coverage, volume agreement and the requested quality threshold. This is a meshing verification, not a general surface-intersection certificate. netgen_all_volumes=True runs the Netgen optimization on every volume, not only those below minimum_quality (a volume whose minimum deteriorates still keeps its baseline). optimize_threshold sets Gmsh Mesh.OptimizeThreshold (elements below it are optimized); None keeps the Gmsh default. The report always includes dihedral-angle statistics. minimum_dihedral (degrees) adds a readiness condition: every tet’s smallest dihedral angle must reach it. None leaves readiness on minSICN alone.