Salome HOME
ParaView 4.1 / VTK 6.1 porting
[modules/hexablock.git] / doc / tui_cartgrid.rst
1 :tocdepth: 3
2
3
4 .. _tuicartgrid:
5
6 ====================
7 Make cartesian grids
8 ====================
9
10 .. _tuicartgridsimple:
11
12 Simple Cartesian Grid
13 =====================
14
15 To add a simple cartesian grid to the model, the following data are required:
16
17 - *nb X*: The number of hexahedra along the X axis
18 - *nb Y*: The number of hexahedra along the Y axis
19 - *nb Z*: The number of hexahedra along the Z axis
20
21
22 Make a Simple Cartesian Grid::
23
24     elts = doc.makeCartesianTop(nbX, nbY, nbZ)
25
26 GUI command: :ref:`guicartgridsimple`
27
28
29 .. _tuicartgriduniform:
30
31 Uniform Cartesian Grid
32 ======================
33
34 To add a uniform cartesian grid to the model, the following data are required:
35
36 - *origin*: The vertex of the origin
37 - *vec X* : The X vector
38 - *vec Y* : The Y vector
39 - *vec Z* : The Z vector
40 - *len X* : The length of an hexahedra on the X axis
41 - *len Y* : The length of an hexahedra on the Y axis
42 - *len Z* : The length of an hexahedra on the Z axis
43 - *nb X*  : The number of hexahedra on the X axis
44 - *nb Y*  : The number of hexahedra on the Y axis
45 - *nb Z*  : The number of hexahedra on the Z axis
46
47 Make a Uniform Cartesian Grid::
48
49     elts = doc.makeCartesianUni(orig, vecX, vecY, vecZ, lenX, lenY, lenZ, nbX, nbY, nbZ)
50   
51 GUI command: :ref:`guicartgriduniform`  
52
53
54 .. _tuicartgridcustom:
55
56 Custom Cartesian Grid
57 =====================
58
59 To add a custom cartesian grid to the model, the following data are required:
60
61 - *origin*: The vertex of the origin
62 - *vec X* : The X vector
63 - *vec Y* : The Y vector
64 - *vec Z* : The Z vector
65 - *tx*    : A list of x coordinates in ascendant order
66 - *ty*    : A list of y coordinates in ascendant order
67 - *tz*    : A list of z coordinates in ascendant order
68
69 Make a Custom Cartesian Grid::
70
71     elts = doc.makeCartesian(orig, vecX, vecY, vecZ, tx, ty, tz)
72     
73 GUI command: :ref:`guicartgridcustom`
74
75
76 Operations on *elts*: :ref:`tuielements2`
77
78
79 Example
80 =======
81
82 .. literalinclude:: test_doc/cartesian_grid/cartesian_grid.py
83    :linenos: