Salome HOME
ad5f15e65f5eda18e608abea4b3be6a9c4a2243e
[modules/smesh.git] / doc / salome / gui / SMESH / input / sewing_meshes.doc
1 /*!
2
3 \page sewing_meshes_page Sewing meshes
4
5 \n In SMESH you can sew elements of a mesh. The current
6 functionality allows you to sew:
7 <ul>
8 <li>\ref free_borders_anchor "Free borders"</li>
9 <li>\ref conform_free_borders_anchor "Conform free borders"</li>
10 <li>\ref border_to_side_anchor "Border to side"</li>
11 <li>\ref side_elements_anchor "Side elements"</li>
12 </ul>
13
14 \image html sewing.png "Sewing button"
15
16 <em>To sew elements of a mesh:</em>
17 <ol>
18 <li>From the \b Modification menu choose the \b Transformation item
19 and from its sub-menu select the \b Sewing item.</li>
20 <li>Check in the dialog box one of the radio buttons corresponding to
21 the type of sewing operation you would like to perform.</li>
22 <li>Fill the other fields available in the dialog box.</li>
23 <li>Click the \b Apply or <b>Apply and Close</b> button to perform the operation of sewing.</li>
24 </ol>
25
26 <br>
27 \anchor free_borders_anchor
28 <h2>Sew free borders</h2>
29
30 This functionality allows you to unite two free borders of a 2D mesh.
31
32 \image html sewing1.png
33
34 For sewing free borders you should define three points on each border:
35 first, second and the last node:
36 <ul>
37 <li>the first node specifies beginning of the border;</li>
38 <li>the second node specifies the part of the border which should be
39 considered (as far as the free border usually forms a closed
40 contour);</li>
41 <li>the last node specifies the end of the border.</li>
42 </ul>
43
44 You can select these nodes in the 3D viewer or define by its id.
45
46 The first and the second nodes should belong to the same link of a
47 face. The second and the last nodes of a border can be the same. The
48 first and the last nodes of two borders can be the same. The
49 corresponding end nodes of two borders will be merged. Intermediate
50 nodes of two borders will be either merged or inserted into faces of
51 the opposite border.
52
53 In practice the borders to sew often coincide and in this case it is
54 difficult to specify the first and the last nodes of a border since
55 they coincide with the first and the last nodes of the other
56 border. To cope with this, manually \ref merging_nodes_page to fuse
57 each pair of coincident nodes into one.
58
59 The sewing algorithm is as follows:
60 <ol>
61 <li>The parameter (U) of each node within a border is computed. So
62 that the first node has U=0.0, the last node has U=1.0, for the rest
63 nodes 0.0 < U < 1.0;</li>
64 <li>Compare node parameters of the two borders. If two nodes of the
65 opposite borders have close parameters, they are merged, i.e. a node
66 of the first border is replaced in all elements by a node of the
67 second border. If a node has no node with a close parameter in the
68 opposite border, it is inserted into an edge of element of the
69 opposite border, an element is split. Two nodes are considered close
70 enough to merge, if difference of their parameters is less than one
71 fifth of minimum length of adjacent face edges on the borders.</li>
72 </ol>
73
74 \image html image22.jpg "Sewing free borders"
75
76 <b>See Also</b> a sample TUI Script of a 
77 \ref tui_sew_free_borders "Sew Free Borders" operation.
78
79 <br>
80 \anchor conform_free_borders_anchor
81 <h2>Sew conform free borders</h2>
82
83 This functionality can be used to unite two free borders of a 2D mesh.
84
85 \image html sewing2.png
86
87 The borders of meshes for sewing are defined as for "Sew free borders"
88 except that the second free border is not limited and can be defined
89 by the first and the second nodes only. The first nodes of two borders
90 can be the same.
91
92 The algorithm is following: counting nodes starting at the first ones,
93 the n-th node of the first border is merged with the n-th node of the
94 other border, until the end of either of borders. Nodes of the first
95 border are replaced in all elements with corresponding nodes of the
96 second border.
97 \n For sewing conform free borders you should define three points on
98 the first border and two points on the second one. User can select
99 these nodes in 3D viewer or define node by its id.
100
101 \image html image23.jpg "Sewing conform free borders"
102
103 <b>See Also</b> a sample TUI Script of a 
104 \ref tui_sew_conform_free_borders "Sew Conform Free Borders"
105 operation.
106
107 <br>
108 \anchor border_to_side_anchor
109 <h2>Sew border to side</h2>
110
111 "Sew border to side" is intended to sew a free border to a mesh
112 surface.
113 \n The free border is defined as for "Sewing of free borders". The
114 place where to sew the border is defined by two nodes, between which
115 the border faces are placed, so that the first border node is merged
116 with the first node on the side and the last node of the border is
117 merged with the second specified node on the side.
118
119 \image html sewing3.png
120
121 The algorithm is following.
122 <ol>
123 <li>Find a sequence of linked nodes on the side such that the found
124 links to be most co-directed with the links of the free border.</li>
125 <li>Sew two sequences of nodes using algorithm of "Sewing of free berders".
126 \n For sewing border to side you should define three points on the
127 border and two points on the side. User can select these nodes in 3D
128 viewer or define node by its id.</li>
129 </ol>
130
131 \image html image30.jpg "Sewing border to side"
132
133 <b>See Also</b> a sample TUI Script of a 
134 \ref tui_sew_meshes_border_to_side "Sew Border to Side" operation.  
135
136 <br>
137 \anchor side_elements_anchor
138 <h2>Sew side elements</h2>
139
140 This operation is intended to unite two mesh surfaces.
141
142 \image html sewing4.png 
143
144 Surfaces may be defined by either 2d or 3d elements. The number of
145 given elements of the sides must be the same. The sets of given
146 elements must be topologically equal, i.e. each node of one element
147 set must have a corresponding node in the other element set and
148 corresponding nodes must be equally linked. If there are 3d elements
149 in a set, only their free faces must obey to that rule.
150 \n Two corresponding nodes on each side must be specified. They must
151 belong to one element and must be located on an element set boundary.
152
153 Sewing algorithm finds and merges the corresponding nodes starting
154 from the specified ones.
155
156 \image html image31.jpg "Step-by-step sewing process"
157
158 \image html image32.jpg "The result of side elements sewing"
159
160 For sewing side elements you should define elements for sewing and two
161 nodes for merging on the each side. User can select these elements and
162 nodes in 3D viewer or define them by its id.
163
164 <b>See Also</b> a sample TUI Script of a 
165 \ref tui_sew_side_elements "Sew Side Elements" operation.  
166
167 */