1 # Viscous layers construction
4 SetCurrentStudy(salome.myStudy)
6 X = geompy.MakeVectorDXDYDZ( 1,0,0 )
7 O = geompy.MakeVertex( 100,50,50 )
8 plane = geompy.MakePlane( O, X, 200 ) # plane YZ
10 box = geompy.MakeBoxDXDYDZ(200,100,100)
12 shape = geompy.MakeHalfPartition( box, plane )
14 faces = geompy.SubShapeAllSorted(shape, geompy.ShapeType["FACE"])
16 ignoreFaces = [ faces[0], faces[-1]]
18 geompy.addToStudy( shape, "shape" )
19 geompy.addToStudyInFather( shape, face1, "face1")
22 mesh = Mesh(shape, "CFD")
24 mesh.Segment().NumberOfSegments( 4 )
27 mesh.Quadrangle(face1)
29 algo3D = mesh.Tetrahedron()
34 layersHyp = algo3D.ViscousLayers(thickness,numberOfLayers,stretchFactor,ignoreFaces)
38 mesh.MakeGroup("Tetras",VOLUME,FT_ElemGeomType,"=",Geom_TETRA)
39 mesh.MakeGroup("Pyras",VOLUME,FT_ElemGeomType,"=",Geom_PYRAMID)
40 mesh.MakeGroup("Prims",VOLUME,FT_ElemGeomType,"=",Geom_PENTA)