4 .. _tuiblockscylinderpipe:
6 =====================================
7 Make blocks for a cylinder and a pipe
8 =====================================
12 Make blocks for a cylinder
13 ==========================
15 .. code-block:: python
17 elts = doc.makeCylinder(cyl, vb, nr, na, nl)
19 cyl: cylinder built using *addCylinder()* function (:ref:`tuicylinder`)
21 vb: vector on the base of the cylinder to start hexahedra.
23 nr: number of blocks on radial.
25 na: number of angular section.
27 nl: number of blocks along the axis of the cylinder.
29 Operations on *elts*: :ref:`tuielements2`
31 The result is an array of hexahedra ranked first by following the
32 radial direction and the angular direction, then according to the
33 layers in the cylinder axis.
36 Example of cylinder construction
37 --------------------------------
39 .. literalinclude:: test_doc/cylinder_pipe/make_cylinder.py
43 .. image:: _static/make_cylinder.png
52 Make blocks for cylinders
53 =========================
55 .. code-block:: python
57 elts = doc.makeCylinders (cylinder1, cylinder2)
59 Operations on *elts*: :ref:`tuielements2`
61 Construction of an element from 2 cylinders:
63 .. literalinclude:: test_doc/cylinder_pipe/make_cylinders.py
67 .. image:: _static/make_cylinders.png
71 Element from 2 cylinders
73 The result is an array of hexahedral.
78 Make blocks for a pipe
79 ======================
81 .. code-block:: python
83 elts = doc.makePipe(pi, vb, nr, na, nl)
85 pi: pipe built using *addPipe()* function (:ref:`tuipipe`)
87 vb: vector on the base of the pipe to start hexahedra.
89 nr: number of blocks on radial.
91 na: number of angular section.
93 nl: number of blocks along the axis of the pipe.
95 Operations on *elts*: :ref:`tuielements2`
97 The result is an array of hexahedral arranged in layers following the
98 first radial and angular layers, and finally the axial layers.
101 Example of pipe construction
102 ----------------------------
104 .. literalinclude:: test_doc/cylinder_pipe/make_pipe.py
108 .. image:: _static/make_pipe.png
116 Make blocks for pipes
117 =====================
119 .. code-block:: python
121 elts = doc.makePipes (pipe1, pipe2)
123 Operations on *elts*: :ref:`tuielements2`
125 Construction of an element from 2 pipes:
128 .. literalinclude:: test_doc/cylinder_pipe/make_pipes.py
132 .. image:: _static/make_pipes.png
138 The result is an array of hexahedra where we first find hexahedra of
139 the first pipe and the second pipe. Each pipe range hexahedra following
140 first radial layers and angular layers, and finally the axial layers.
142 Operations on *elts*: :ref:`tuielements2`
144 GUI command: :ref:`guiblockscylinderpipe`