Version: 6.5.0
Home
 All Data Structures Namespaces Files Functions Variables Groups
Functions
Creating groups
Grouping elements

Functions

def CreateEmptyGroup
 Creates an empty mesh group.
def Group
 Creates a mesh group based on the geometric object grp and gives a name,
if this parameter is not defined the name is the same as the geometric group name
Note: Works like GroupOnGeom().
def GroupOnGeom
 Creates a mesh group based on the geometrical object grp and gives a name,
if this parameter is not defined the name is the same as the geometrical group name.
def GroupOnFilter
 Creates a mesh group with given name based on the filter which is a special type of group dynamically updating it's contents during mesh modification.
def MakeGroupByIds
 Creates a mesh group by the given ids of elements.
def MakeGroup
 Creates a mesh group by the given conditions.
def MakeGroupByCriterion
 Creates a mesh group by the given criterion.
def MakeGroupByCriteria
 Creates a mesh group by the given criteria (list of criteria)
def MakeGroupByFilter
 Creates a mesh group by the given filter.
def GetGroups
 Gets the list of groups existing in the mesh.
def NbGroups
 Gets the number of groups existing in the mesh.
def GetGroupNames
 Gets the list of names of groups existing in the mesh.

Detailed Description

Function Documentation

def CreateEmptyGroup (   self,
  elementType,
  name 
)

Creates an empty mesh group.

Parameters
elementTypethe type of elements in the group
namethe name of the mesh group
Returns
SMESH_Group
def Group (   self,
  grp,
  name = "" 
)

Creates a mesh group based on the geometric object grp and gives a name,
if this parameter is not defined the name is the same as the geometric group name
Note: Works like GroupOnGeom().

Parameters
grpa geometric group, a vertex, an edge, a face or a solid
namethe name of the mesh group
Returns
SMESH_GroupOnGeom

References Mesh.GroupOnGeom().

def GroupOnGeom (   self,
  grp,
  name = "",
  typ = None 
)

Creates a mesh group based on the geometrical object grp and gives a name,
if this parameter is not defined the name is the same as the geometrical group name.

Parameters
grpa geometrical group, a vertex, an edge, a face or a solid
namethe name of the mesh group
typthe type of elements in the group. If not set, it is automatically detected by the type of the geometry
Returns
SMESH_GroupOnGeom

References Mesh._groupTypeFromShape(), and smesh.AssureGeomPublished().

def GroupOnFilter (   self,
  typ,
  name,
  filter 
)

Creates a mesh group with given name based on the filter which is a special type of group dynamically updating it's contents during mesh modification.

Parameters
typthe type of elements in the group
namethe name of the mesh group
filterthe filter defining group contents
Returns
SMESH_GroupOnFilter
def MakeGroupByIds (   self,
  groupName,
  elementType,
  elemIDs 
)

Creates a mesh group by the given ids of elements.

Parameters
groupNamethe name of the mesh group
elementTypethe type of elements in the group
elemIDsthe list of ids
Returns
SMESH_Group

References Mesh.MakeGroup().

def MakeGroup (   self,
  groupName,
  elementType,
  CritType = FT_Undefined,
  Compare = FT_EqualTo,
  Threshold = "",
  UnaryOp = FT_Undefined,
  Tolerance = 1e-07 
)

Creates a mesh group by the given conditions.

Parameters
groupNamethe name of the mesh group
elementTypethe type of elements in the group
CritTypethe type of criterion( FT_Taper, FT_Area, FT_RangeOfIds, FT_LyingOnGeom etc. )
Comparebelongs to {FT_LessThan, FT_MoreThan, FT_EqualTo}
Thresholdthe threshold value (range of id ids as string, shape, numeric)
UnaryOpFT_LogicalNOT or FT_Undefined
Tolerancethe tolerance used by FT_BelongToGeom, FT_BelongToSurface, FT_LyingOnGeom, FT_CoplanarFaces criteria
Returns
SMESH_Group

References Mesh.MakeGroupByCriterion().

def MakeGroupByCriterion (   self,
  groupName,
  Criterion 
)

Creates a mesh group by the given criterion.

Parameters
groupNamethe name of the mesh group
Criterionthe instance of Criterion class
Returns
SMESH_Group

References Mesh.MakeGroupByFilter().

def MakeGroupByCriteria (   self,
  groupName,
  theCriteria 
)

Creates a mesh group by the given criteria (list of criteria)

Parameters
groupNamethe name of the mesh group
theCriteriathe list of criteria
Returns
SMESH_Group

References Mesh.MakeGroupByFilter().

def MakeGroupByFilter (   self,
  groupName,
  theFilter 
)

Creates a mesh group by the given filter.

Parameters
groupNamethe name of the mesh group
theFilterthe instance of Filter class
Returns
SMESH_Group

References Mesh.CreateEmptyGroup(), and Mesh.mesh.

def GetGroups (   self)

Gets the list of groups existing in the mesh.

Returns
a sequence of SMESH_GroupBase
def NbGroups (   self)

Gets the number of groups existing in the mesh.

Returns
the quantity of groups as an integer value
def GetGroupNames (   self)

Gets the list of names of groups existing in the mesh.

Returns
list of strings

References Mesh.GetGroups().

Copyright © 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE
Copyright © 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS