2018-11-27 19:21:06 +05:00
|
|
|
# Creating groups of faces separated by sharp edges
|
|
|
|
|
|
|
|
import salome
|
2021-08-12 14:38:10 +05:00
|
|
|
salome.salome_init_without_session()
|
2022-04-11 18:28:01 +05:00
|
|
|
|
2018-11-27 19:21:06 +05:00
|
|
|
from salome.geom import geomBuilder
|
|
|
|
from salome.smesh import smeshBuilder
|
2022-04-11 18:28:01 +05:00
|
|
|
|
|
|
|
geom_builder = geomBuilder.New()
|
|
|
|
smesh_builder = smeshBuilder.New()
|
2018-11-27 19:21:06 +05:00
|
|
|
|
|
|
|
# create a mesh on a box
|
2022-04-11 18:28:01 +05:00
|
|
|
box = geom_builder.MakeBoxDXDYDZ( 10,10,10, theName="Box" )
|
|
|
|
mesh = smesh_builder.Mesh(box,"Mesh")
|
2018-11-27 19:21:06 +05:00
|
|
|
mesh.AutomaticHexahedralization()
|
|
|
|
|
|
|
|
# create groups of faces of each side of the box
|
|
|
|
groups = mesh.FaceGroupsSeparatedByEdges( 89 )
|