Salome HOME
Increment version: 8.1.0
[modules/hexablock.git] / doc / mesh.rst
1 :tocdepth: 3
2
3 .. _mesh:
4
5 ======================
6 Meshing with Hexahedra
7 ======================
8
9 The main stages to mesh with HexaBlock are:
10
11 - Define all discretization laws, a law is characterized by:
12
13     - A number of nodes
14     - A distribution (uniform, arithmetic, etc.)
15
16 - Apply a law on a set of edges
17
18     - This set of edges has the propagation property
19     - This set is defined directly on the model of blocks
20
21 - Define all groups directly on the model of blocks:
22
23     - Groups of nodes
24     - Groups of segments, of quadrangles, of hexahedra
25
26 - Parametrization of the mesh generation
27
28 Generate the mesh
29 =================
30 Once the model and its association to the geometry created, the hexahedral mesh can be generated by mentioning:
31
32 - the discretization of the edges thanks to discretization laws
33 - the potential groups
34
35 To discretize, the application proceeds in three steps:
36
37 - the application computes a partition of the model edges, where each sub-set of edges corresponds to the edges related to the propagation,
38
39 - the user defines the needed discretization laws, a law is characterized by:
40
41     * the name of this law,
42     * the number of nodes to compute
43     * a distribution (uniform, arithmetic, etc.)
44
45 - the user (working on the model) apply a discretization law on each sub-set of propagation edges
46
47 The groups are defined on the model of blocks and the main types of groups are:
48
49 - groups of hexahedra
50 - groups of quadrangles
51 - groups of edges
52 - groups of nodes
53
54 Functionalities
55 ===============
56 - Build a model of blocks:
57
58     - Build a hexahedron
59     - Build grids: cartesian, cylindrical, spherical
60     - Build standard model of blocks:
61
62         - cylinder, pipe
63         - 2 intersected cylinders and pipes
64
65     - Operations: cut, merge, prism, join
66     - Operations: transform, disconnect, remove
67
68 - Associate the model of blocks to the geometry:
69     - Associate all vertices
70     - Associate the needed edges
71     - Associate the needed quadrangles
72
73 - Define the mesh:
74     - Define the groups on the model of blocks
75     - Define the laws for discretization
76     - Define the discretization on the model of blocks
77
78
79 Mesh Algorithm
80 ===============
81
82 Node generation process follows four steps:
83
84 1. generate all the nodes corresponding to the vertices of the model
85 2. generate all the nodes corresponding to the edges of the model
86 3. generate all the nodes corresponding to the faces of the model
87 4. generate all the nodes corresponding to the blocks of the model
88
89 The nodes generated by the meshing of the edges are determined by the discretization law associate to this edge. 
90 The coordinates of these nodes are computed on the geometric edges series associate to this edge. To do so/ a curvilinear abscissa is calculated and based on total length of the 1D geometry associate. The geometric modeler (GEOM of SALOME or CasCade) enables to compute this length.
91
92 The nodes that are generated by meshing of faces are computed in two stages:
93 1. meshing by linear approximation
94 2. refining by projection on the geometry if this geometry exists.
95
96 The meshing by linear approximation performs the three following calculations:
97
98 - computation of node coordinates according to the *i* direction taking into account the discretization law on the *j* direction
99 - computation of node coordinates according to the *j* direction taking into account the discretization law on the *i* direction
100 - the node coordinates are the coordinates of the midpoint of the segment that is formed from the two previous points
101 - if there is a projection step, then the normal at this node is computed 
102
103 The computation of the normal at a node (i,j) is performed thanks to the neighbor nodes:
104
105 - computation of the plan passing through this node and orthogonal to the straight line connecting the nodes (i-1,j) and (i,j+1)
106 - computation of the plan passing through this node and orthogonal to the straight line connecting the nodes (i-1,j) and (i,j+1)
107 - the normal passing through the intersection of the two previous plans
108
109 If the node belongs to a border, the node itself is taken to build the line determining the plan which is perpendicular to it.
110
111 If there is a geometric face (or a list of faces) associate to one face of the model, then an additional projection step (taking into account the normal to the node of the previous step) is computed in order to obtain a node on the geometric face. The coordinates of this node are computed using the intersection of the normal with this face (or this list of faces).
112
113 The nodes generated by the meshing of blocks are determined by the algorithm << i, j, k >> included in the SMESH module of SALOME.
114
115 Examples
116 ----------
117 Linear approximation of the discretization of faces
118 '''''''''''''''''''''''''''''''''''''''''''''''''''''
119
120 .. image:: _static/meshing1.png
121    :align: center
122
123
124 Geometric face and meshing by approximation
125 ''''''''''''''''''''''''''''''''''''''''''''
126
127 .. image:: _static/meshing2.png
128    :align: center
129
130
131 Geometric face and meshing by approximation and projection
132 ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
133
134 .. image:: _static/meshing3.png
135    :align: center
136