Note
Go to the end to download the full example code.
Mesh3_2D#
Meshing a 2D domain with hole.


12 from EasyFEA import Display, ElemType, PyVista
13 from EasyFEA.Geoms import Domain, Circle
14
15 if __name__ == "__main__":
16 Display.Clear()
17
18 contour = Domain((0, 0), (1, 1), 1 / 10)
19 circle = Circle((1 / 2, 1 / 2), 1 / 3, 1 / 10, isHollow=True)
20 PyVista.Plot_Geoms([contour, circle]).show()
21
22 # "TRI3", "TRI6", "TRI10", "TRI15", "QUAD4", "QUAD8", "QUAD9"
23 elemType = ElemType.TRI6
24 mesh = contour.Mesh_2D([circle], elemType)
25 PyVista.Plot_Mesh(mesh).show()
Total running time of the script: (0 minutes 0.563 seconds)