Salome HOME
Synchronize adm files
[modules/hexablock.git] / doc / tui_cylgrid.rst
1 :tocdepth: 3
2
3
4 .. _tuicylgrid:
5
6 ======================
7 Make cylindrical grids
8 ======================
9
10 To add a regular cylindrical grid, the following data are required:
11
12 - the coordinates (vertex) of the cylinder base center: *pt*
13 - the vectors defining the axis and the direction of the cylinder: *vex, vez*
14 - the radial, angular and axial sizes: *dr, da, dl*
15 - the radial, angular and axial elements number: *nr, na, nl*
16 - to fill or not the central part of hexahedra: *fill*
17
18 To add an irregular cylindrical grid, the following data are required:
19
20 - the coordinates (vertex) of the cylinder base center: *pt*
21 - the vectors defining the axis and the direction of the cylinder: *vex, vez*
22 - the radial, angular and axial sizes: *dr (a list of radius), da (a list of angles), dl (a list of heights)*
23 - to fill or not the central part of hexahedra: *fill*
24
25 Make a regular cylindrical grid::
26
27     elts = doc.makeCylindrical(pt, vex, vez, dr, da, dl, nr, na, nl, fill)
28
29 Make an irregular cylindrical grid::
30
31         elts = doc.makeCylindricals (pt, vex, vez, dr, da, dl, False)
32         
33 Operations on *elts*: :ref:`tuielements2`
34
35
36 The result is an array of hexahedra which are arranged along the
37 radial axis first, then the angular axis, then according to the layers
38 and then possibly hexahedra filling the central part.
39
40
41 The filling the central part of the cylinder is made â€‹accordingly to the two following cases:
42
43 .. image:: _static/cyl_grid2.png
44    :align: center
45
46 .. centered::
47    Filling of the central part of the cylinder in the case the number of angular elements is odd na = 5.
48
49 .. image:: _static/cyl_grid1.png
50    :align: center
51
52 .. centered::
53    Filling of the central part of the cylinder in the case the number of angular elements is even na = 4.
54
55
56 Example (regular mode)
57 ----------------------
58
59 Filling rule is illustrated by different case-tests:
60
61
62 .. literalinclude:: test_doc/grid/cylindrical_grid.py
63    :linenos:
64
65
66 .. image:: _static/cylindrical_grids.png
67    :align: center
68
69 .. centered::
70    Cylindrical Grids (regular)
71
72
73 Example (irregular mode)
74 ------------------------
75
76 .. literalinclude:: test_doc/grid/irregular_cylindrical.py
77    :linenos:
78
79
80 .. image:: _static/irregular_cylindrical.png
81    :align: center
82
83 .. centered::
84    Irregular cylindrical grid
85    
86    
87 GUI command: :ref:`guicylgrid`