Mesh4_2D#

Meshing a 2D bracket.

Mesh4 2D
Mesh4 2D
12 from EasyFEA import Display, ElemType, PyVista
13 from EasyFEA.Geoms import Point, Points
14
15 if __name__ == "__main__":
16     Display.Clear()
17
18     L = 120
19     h = L * 0.3
20     N = 8
21
22     pt1 = Point(isOpen=True, r=-10)
23     pt2 = Point(x=L)
24     pt3 = Point(x=L, y=h)
25     pt4 = Point(x=h, y=h, r=10)
26     pt5 = Point(x=h, y=L)
27     pt6 = Point(y=L)
28     pt7 = Point(x=h, y=h)
29
30     contour = Points([pt1, pt2, pt3, pt4, pt5, pt6], h / N)
31     PyVista.Plot_Geoms(contour).show()
32
33     # "TRI3", "TRI6", "TRI10", "TRI15", "QUAD4", "QUAD8",  "QUAD9"
34     elemType = ElemType.TRI10
35     mesh = contour.Mesh_2D([], elemType)
36     PyVista.Plot_Mesh(mesh).show()

Total running time of the script: (0 minutes 0.524 seconds)

Gallery generated by Sphinx-Gallery