HASEonGPU.Gmsh

class HASEonGPU.Gmsh(nodes, elements, physical_names=<factory>, source=None)

Bases: object

gmsh-backed mesh data accepted by MeshTopology.

HASEonGPU currently only accepts two-dimensional triangle meshes and later extrudes them through numberOfLevels with a fixed thickness. Physical surface names containing cladding can populate claddingCellTypes on a GainMedium.

Parameters:
  • nodes (dict[int, tuple[float, float, float]])

  • elements (list[GmshElement])

  • physical_names (dict[int, dict[int, str]])

  • source (str | None)

nodes: dict[int, tuple[float, float, float]]

Node id to (x, y, z) coordinate mapping.

elements: list[GmshElement]

All gmsh elements read from the file.

physical_names: dict[int, dict[int, str]]

Physical names grouped by gmsh dimension and tag.

source: str | None = None

Original gmsh filename, if loaded from disk.

classmethod fromFile(filename)

Read a gmsh .msh file using the gmsh Python package.

topology(*, numberOfLevels=None, thickness=None)

Convert planar triangle elements into an extruded MeshTopology.

claddingCellTypes(topology)

Return triangle-wise cladding tags inferred from physical names.