1 # Create a Standalone Group
5 smesh = SMESH_mechanic.smesh
6 mesh = SMESH_mechanic.mesh
7 salome = SMESH_mechanic.salome
9 # Get ids of all faces with area > 100
10 aFilter = smesh.GetFilter(smesh.FACE, smesh.FT_Area, smesh.FT_MoreThan, 100.)
12 anIds = mesh.GetIdsFromFilter(aFilter)
14 # create a group consisting of faces with area > 100
15 aGroup1 = mesh.MakeGroupByIds("Area > 100", smesh.FACE, anIds)
17 # create a group that contains all nodes from the mesh
18 aGroup2 = mesh.CreateEmptyGroup(smesh.NODE, "all nodes")
19 aGroup2.AddFrom(mesh.mesh)
21 salome.sg.updateObjBrowser(1)