Salome HOME
Minor doc changes
[modules/smesh.git] / doc / salome / gui / SMESH / input / constructing_submeshes.doc
1 /*!
2
3 \page constructing_submeshes_page Constructing sub-meshes
4
5 \tableofcontents
6
7 By purpose, the sub-mesh is an object used to assign to a sub-shape
8 different meshing parameters than those assigned to the main shape.
9
10 Structurally, the sub-mesh is a mesh on a certain sub-shape, or a group of
11 sub-shapes, possibly generated using different meshing algorithms
12 and/or hypotheses than those used to generate the mesh on other
13 sub-shapes.
14
15 Creation of a sub-mesh allows to control individually meshing of a
16 certain sub-shape, thus to get a locally coarser or finer mesh, to get
17 elements of different types in the same mesh, etc.
18
19 \section submesh_shape_section How to get a sub-shape for sub-mesh construction
20
21 A sub-shape to create a sub-mesh on should be retrieved from the main shape
22 in one of the following ways: <ul>
23 <li> In Geometry module, via <em>New Entity > Explode</em> menu.</li>
24 <li> In Geometry module, by creation of a group (<em>New Entity >
25     Group > Create Group</em> menu).</li> 
26 <li> In Mesh module, by
27   \ref subshape_by_mesh_elem "selecting a mesh element" generated on a
28   sub-shape of interest. This way is accessible if the mesh is
29   already computed.</li> 
30 <li> In Mesh module, by clicking <em>Publish Sub-shape</em> button in a
31       dialog showing \ref meshing_failed_anchor "meshing errors".</li> 
32 </ul>
33
34 \section submesh_priority How hypotheses are selected among sub-meshes
35
36 Internally, definition of meshing parameters to apply for
37 discretization of a certain sub-shape, for example an edge of a
38 compound of solids, starts from searching an algorithm, 1D as for the
39 edge. The following sub-shapes are sequentially checked for presence
40 of a sub-mesh where 1D algorithm is assigned:
41 <ul>
42 <li> the \b edge itself</li>
43 <li> <b>groups of edges</b> containing the edge, if any</li>
44 <li> \b wires sharing the edge</li>
45 <li> \b faces sharing the edge</li>
46 <li> <b>groups of faces</b> sharing the edge, if any</li>
47 <li> \b shells sharing the edge</li>
48 <li> \b solids sharing the edge</li>
49 <li> <b>groups of solids</b> sharing the edge, if any</li>
50 <li> the <b>main shape</b></li>
51 </ul>
52 (This sequence of sub-shapes defines the priority of sub-meshes. Thus more
53 local, i.e. assigned to sub-shape of lower dimension, algorithms and
54 hypotheses have higher priority during the search of hypotheses to
55 apply.)
56
57 As soon as a 1D algorithm is found, the search stops and the same
58 sequence of sub-shapes is checked to find the main and additional 1D
59 hypotheses, which can be taken into account by the found 1D algorithm. 
60
61 The multi-dimensional algorithms have a higher priority than
62 uni-dimensional ones if they are assigned to sub-meshes of the
63 same priority.
64
65 If meshing parameters are defined on sub-meshes of the same priority,
66 for example, different 1D hypotheses are assigned to two faces sharing
67 an edge, the hypothesis assigned to a sub-shape with a lower ID will
68 be used for meshing. You can \ref submesh_order_anchor "change" mutual
69 priority of such concurrent sub-meshes. 
70
71 \section submesh_definition How to construct a sub-mesh
72
73 \n Construction of a sub-mesh consists of:
74 <ul>
75 <li>Selecting a mesh which will encapsulate the sub-mesh</li>
76 <li>Selecting a sub-shape for meshing</li>
77 <li>Applying one or several
78 \ref about_hypo_page "hypotheses" and 
79 \ref basic_meshing_algos_page "meshing algorithms" which will be used
80 for discretization of this sub-shape.</li>
81 </ul>
82
83 <br><em>To construct a sub-mesh:</em>
84 \par
85 From the \b Mesh menu select <b>Create Sub-mesh</b> or click <em>"Create
86 Sum-mesh"</em> button in the toolbar.
87
88 <center>
89   \image html image33.gif
90   <em>"Create Sub-mesh" button</em>
91 </center>
92
93 \par
94 The following dialog box will appear:
95
96 \par
97 \image html createmesh-inv2.png
98
99 It allows to define the \b Name, the parent \b Mesh and the \b
100 Geometry (e.g. a face if the parent mesh has been built on box) of the
101 sub-mesh. You can define meshing algorithms and hypotheses in the same way as
102 in \ref constructing_meshes_page "Create mesh" dialog. 
103
104 Later you can change the applied hypotheses or their parameters in 
105 \ref editing_meshes_page "Edit mesh/sub-mesh" dialog. Mesh entities
106 generated using changed hypotheses are automatically removed.
107
108 \anchor subshape_by_mesh_elem
109 If the parent mesh is already computed, then you can define the
110 \b Geometry by picking mesh elements computed on a sub-shape of interest
111 in the 3D Viewer, i.e. you do not have to extract this sub-shape
112 in Geometry module beforehand. To start element selection, press \a
113 Selection button to the right of \b Geometry label. If this button is
114 already down, then click it to release and then click it again. The
115 following pop-up menu allowing to choose a way of geometry definition will
116 appear.
117
118 \image html choose_geom_selection_way.png
119
120 <b>Direct geometry selection</b> enables selecting the sub-shape in the Object
121 Browser.
122 <b>Find geometry by mesh element selection</b> activates the following dialog.
123
124 \image html find_geom_by_mesh_elem.png
125
126 In this dialog, <b> Element Type </b> defines a kind of element to pick in the
127 Viewer.
128 Instead of picking an element in the Viewer, you can type its
129 ID in <b> Element ID</b> field. 
130 <b> Geometry name </b> field allows defining a name of the sub-shape, 
131 with which the sub-shape will appear in the Object Browser (if not yet
132 there).
133
134 \section submesh_tree Sub-mesh in the Object Browser
135
136 In the Object Browser the structure of the new sub-mesh will be
137 displayed as follows:
138
139 \image html image10.jpg
140
141 It contains:
142 <ul>
143 <li>a sub-mesh name (\a SubMeshFace1)
144 <li>a reference to the geometrical object on the basis of which the
145   sub-mesh has been constructed (<em>Cylindrical Face_1</em>);</li>
146 <li><em>Applied hypotheses</em> folder containing references to
147 hypotheses assigned to the sub-mesh;</li>
148 <li><em>Applied algorithms</em> folder containing references to
149 algorithms assigned to the sub-mesh.</li>
150 </ul>
151
152 <br><b>See Also</b> a sample TUI Script of a 
153 \ref tui_construction_submesh "Construct Sub-mesh" operation.
154
155 */