mymesh.improvement.TetImprove#

mymesh.improvement.TetImprove(M, h, schedule='scfS', repeat=1, labels=None, smoother='SmartLaplacianSmoothing', smooth_kwargs={}, verbose=True, FeatureAngle=25, ContractIter=5)[source]#

Tetrahedral mesh quality improvement using multiple local operations.

Parameters:
  • M (mymesh.mesh) – Tetrahedral mesh to be improved

  • h (float) – Target element size/edge length

  • schedule (str, optional) –

    Order of operations to perform, specified as a string with each character indicating an operation, by default ‘scfS’.

    Possible operations:

  • repeat (int, optional) – Number of times to repeat the schedule, by default 1

  • labels (str, array_like, or NoneType, optional) – Element labels indicating different regions. If specified, region interfaces will be preserved. This can be specified as an array_like with M.NElem entries or a string corresponding to an entry in M.ElemData, by default None.

  • smoother (str, optional) – Specify which smoothing operation to use, by default ‘SmartLaplacianSmoothing’

  • smooth_kwargs (dict, optional) – Key word arguments to be passed to the smoother, by default {}

  • verbose (bool, optional) – If True, will display progress, by default True

  • FeatureAngle (int, optional) – FeatureAngle : int, optional Angle (in degrees) used to identify features, by default 25. See DetectFeatures() for more information., by default 25

  • ContractIter (int, optional) – Maximum number of iterations to perform in the contraction step, by default 5

Returns:

Mnew – Tetrahedral mesh after quality improvement

Return type:

mymesh.mesh