1 # -*- coding: utf-8 -*-
2 # Copyright (C) 2009-2016 CEA/DEN, EDF R&D
4 # This library is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU Lesser General Public
6 # License as published by the Free Software Foundation; either
7 # version 2.1 of the License, or (at your option) any later version.
9 # This library is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 # Lesser General Public License for more details.
14 # You should have received a copy of the GNU Lesser General Public
15 # License along with this library; if not, write to the Free Software
16 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 ####### Rind Grid Test ##########
26 doc = hexablock.addDocument ("Rind Grid Test")
36 rind0 = doc.makeRindTop(nr, na, nh)
37 rind0.saveVtk("makeRindTop.vtk")
41 center = doc.addVertex (0, 0, 0)
42 vplan = doc.addVertex (0, 0, -0.5)
43 vx = doc.addVector (1, 0, 0)
44 vz = doc.addVector (0, 0, 1)
50 rind1 = doc.makeRindUni(center, vx, vz, rtrou, rint, rext, angle, vplan, nr, na, nh)
51 rind1.saveVtk("makeRindUni.vtk")
63 for nro in range(nr+1):
64 trad.append(rint + nro*dr)
66 for nro in range(na+1):
67 tang.append(nro*dtheta)
69 for nro in range(nh+1):
70 tphi.append(-90 + nro*dphi)
72 rind2 = doc.makeRind(center, vx, vz, trad, tang, tphi)
73 rind2.saveVtk("makeRind.vtk")