VTK  9.7.1
vtkMeshQuality.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2003-2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
54 #ifndef vtkMeshQuality_h
55 #define vtkMeshQuality_h
56 
57 #include "vtkDataSetAlgorithm.h"
58 #include "vtkDeprecation.h" // For deprecation macro
59 #include "vtkFiltersVerdictModule.h" // For export macro
60 
61 #include <functional> // For std::function
62 
63 VTK_ABI_NAMESPACE_BEGIN
64 class vtkCell;
65 class vtkDataArray;
66 class vtkDoubleArray;
67 
68 class VTKFILTERSVERDICT_EXPORT vtkMeshQuality : public vtkDataSetAlgorithm
69 {
70 private:
71  class vtkMeshQualityFunctor;
72 
73 public:
74  void PrintSelf(ostream& os, vtkIndent indent) override;
76  static vtkMeshQuality* New();
77 
79 
85  vtkSetMacro(SaveCellQuality, vtkTypeBool);
86  vtkGetMacro(SaveCellQuality, vtkTypeBool);
87  vtkBooleanMacro(SaveCellQuality, vtkTypeBool);
89 
91 
98  vtkSetMacro(LinearApproximation, bool);
99  vtkGetMacro(LinearApproximation, bool);
100  vtkBooleanMacro(LinearApproximation, bool);
102 
108  static void ComputeAverageCellSize(vtkDataSet* dataset);
109 
163  {
164  AREA = 28,
165  ASPECT_FROBENIUS = 3,
166  ASPECT_GAMMA = 27,
167  ASPECT_RATIO = 1,
168  COLLAPSE_RATIO = 7,
169  CONDITION = 9,
170  DIAGONAL = 21,
171  DIMENSION = 22,
172  DISTORTION = 15,
173  EDGE_RATIO = 0,
174  EQUIANGLE_SKEW = 29,
175  EQUIVOLUME_SKEW = 30,
176  JACOBIAN = 25,
177  INRADIUS = 37,
178  MAX_ANGLE = 8,
179  MAX_ASPECT_FROBENIUS = 5,
180  MAX_EDGE_RATIO = 16,
181  MAX_STRETCH = 31,
182  MEAN_ASPECT_FROBENIUS = 32,
183  MEAN_RATIO = 33,
184  MED_ASPECT_FROBENIUS = 4,
185  MIN_ANGLE = 6,
186  NODAL_JACOBIAN_RATIO = 34,
187  NORMALIZED_INRADIUS = 35,
188  ODDY = 23,
189  RADIUS_RATIO = 2,
190  RELATIVE_SIZE_SQUARED = 12,
191  SCALED_JACOBIAN = 10,
192  SHAPE = 13,
193  SHAPE_AND_SIZE = 14,
194  SHEAR = 11,
195  SHEAR_AND_SIZE = 24,
196  SKEW = 17,
197  SQUISH_INDEX = 36,
198  STRETCH = 20,
199  TAPER = 18,
200  VOLUME = 19,
201  WARPAGE = 26,
202  TOTAL_QUALITY_MEASURE_TYPES = 38,
203  NONE = TOTAL_QUALITY_MEASURE_TYPES
204  };
205 
209  static const char* QualityMeasureNames[];
210 
212 
219  vtkSetEnumMacro(TriangleQualityMeasure, QualityMeasureTypes);
220  virtual void SetTriangleQualityMeasure(int measure)
221  {
222  this->SetTriangleQualityMeasure(static_cast<QualityMeasureTypes>(measure));
223  }
224  vtkGetEnumMacro(TriangleQualityMeasure, QualityMeasureTypes);
226  {
227  this->SetTriangleQualityMeasure(QualityMeasureTypes::AREA);
228  }
230  {
231  this->SetTriangleQualityMeasure(QualityMeasureTypes::EDGE_RATIO);
232  }
234  {
235  this->SetTriangleQualityMeasure(QualityMeasureTypes::ASPECT_RATIO);
236  }
238  {
239  this->SetTriangleQualityMeasure(QualityMeasureTypes::RADIUS_RATIO);
240  }
242  {
243  this->SetTriangleQualityMeasure(QualityMeasureTypes::ASPECT_FROBENIUS);
244  }
246  {
247  this->SetTriangleQualityMeasure(QualityMeasureTypes::MIN_ANGLE);
248  }
250  {
251  this->SetTriangleQualityMeasure(QualityMeasureTypes::MAX_ANGLE);
252  }
254  {
255  this->SetTriangleQualityMeasure(QualityMeasureTypes::CONDITION);
256  }
258  {
259  this->SetTriangleQualityMeasure(QualityMeasureTypes::SCALED_JACOBIAN);
260  }
262  {
263  this->SetTriangleQualityMeasure(QualityMeasureTypes::RELATIVE_SIZE_SQUARED);
264  }
266  {
267  this->SetTriangleQualityMeasure(QualityMeasureTypes::SHAPE);
268  }
270  {
271  this->SetTriangleQualityMeasure(QualityMeasureTypes::SHAPE_AND_SIZE);
272  }
274  {
275  this->SetTriangleQualityMeasure(QualityMeasureTypes::DISTORTION);
276  }
278  {
279  this->SetTriangleQualityMeasure(QualityMeasureTypes::EQUIANGLE_SKEW);
280  }
282  {
283  this->SetTriangleQualityMeasure(QualityMeasureTypes::NORMALIZED_INRADIUS);
284  }
286 
288 
300  vtkSetEnumMacro(QuadQualityMeasure, QualityMeasureTypes);
301  virtual void SetQuadQualityMeasure(int measure)
302  {
303  this->SetQuadQualityMeasure(static_cast<QualityMeasureTypes>(measure));
304  }
305  vtkGetEnumMacro(QuadQualityMeasure, QualityMeasureTypes);
307  {
308  this->SetQuadQualityMeasure(QualityMeasureTypes::EDGE_RATIO);
309  }
311  {
312  this->SetQuadQualityMeasure(QualityMeasureTypes::ASPECT_RATIO);
313  }
315  {
316  this->SetQuadQualityMeasure(QualityMeasureTypes::RADIUS_RATIO);
317  }
319  {
320  this->SetQuadQualityMeasure(QualityMeasureTypes::MED_ASPECT_FROBENIUS);
321  }
323  {
324  this->SetQuadQualityMeasure(QualityMeasureTypes::MAX_ASPECT_FROBENIUS);
325  }
327  {
328  this->SetQuadQualityMeasure(QualityMeasureTypes::MAX_EDGE_RATIO);
329  }
330  void SetQuadQualityMeasureToSkew() { this->SetQuadQualityMeasure(QualityMeasureTypes::SKEW); }
331  void SetQuadQualityMeasureToTaper() { this->SetQuadQualityMeasure(QualityMeasureTypes::TAPER); }
333  {
334  this->SetQuadQualityMeasure(QualityMeasureTypes::WARPAGE);
335  }
336  void SetQuadQualityMeasureToArea() { this->SetQuadQualityMeasure(QualityMeasureTypes::AREA); }
338  {
339  this->SetQuadQualityMeasure(QualityMeasureTypes::STRETCH);
340  }
342  {
343  this->SetQuadQualityMeasure(QualityMeasureTypes::MIN_ANGLE);
344  }
346  {
347  this->SetQuadQualityMeasure(QualityMeasureTypes::MAX_ANGLE);
348  }
349  void SetQuadQualityMeasureToOddy() { this->SetQuadQualityMeasure(QualityMeasureTypes::ODDY); }
351  {
352  this->SetQuadQualityMeasure(QualityMeasureTypes::CONDITION);
353  }
355  {
356  this->SetQuadQualityMeasure(QualityMeasureTypes::JACOBIAN);
357  }
359  {
360  this->SetQuadQualityMeasure(QualityMeasureTypes::SCALED_JACOBIAN);
361  }
362  void SetQuadQualityMeasureToShear() { this->SetQuadQualityMeasure(QualityMeasureTypes::SHEAR); }
363  void SetQuadQualityMeasureToShape() { this->SetQuadQualityMeasure(QualityMeasureTypes::SHAPE); }
365  {
366  this->SetQuadQualityMeasure(QualityMeasureTypes::RELATIVE_SIZE_SQUARED);
367  }
369  {
370  this->SetQuadQualityMeasure(QualityMeasureTypes::SHAPE_AND_SIZE);
371  }
373  {
374  this->SetQuadQualityMeasure(QualityMeasureTypes::SHEAR_AND_SIZE);
375  }
377  {
378  this->SetQuadQualityMeasure(QualityMeasureTypes::DISTORTION);
379  }
381  {
382  this->SetQuadQualityMeasure(QualityMeasureTypes::EQUIANGLE_SKEW);
383  }
385 
387 
394  vtkSetEnumMacro(TetQualityMeasure, QualityMeasureTypes);
395  virtual void SetTetQualityMeasure(int measure)
396  {
397  this->SetTetQualityMeasure(static_cast<QualityMeasureTypes>(measure));
398  }
399  vtkGetEnumMacro(TetQualityMeasure, QualityMeasureTypes);
401  {
402  this->SetTetQualityMeasure(QualityMeasureTypes::EDGE_RATIO);
403  }
405  {
406  this->SetTetQualityMeasure(QualityMeasureTypes::ASPECT_RATIO);
407  }
409  {
410  this->SetTetQualityMeasure(QualityMeasureTypes::RADIUS_RATIO);
411  }
413  {
414  this->SetTetQualityMeasure(QualityMeasureTypes::ASPECT_FROBENIUS);
415  }
417  {
418  this->SetTetQualityMeasure(QualityMeasureTypes::INRADIUS);
419  }
421  {
422  this->SetTetQualityMeasure(QualityMeasureTypes::MIN_ANGLE);
423  }
425  {
426  this->SetTetQualityMeasure(QualityMeasureTypes::COLLAPSE_RATIO);
427  }
429  {
430  this->SetTetQualityMeasure(QualityMeasureTypes::ASPECT_GAMMA);
431  }
432  void SetTetQualityMeasureToVolume() { this->SetTetQualityMeasure(QualityMeasureTypes::VOLUME); }
434  {
435  this->SetTetQualityMeasure(QualityMeasureTypes::CONDITION);
436  }
438  {
439  this->SetTetQualityMeasure(QualityMeasureTypes::JACOBIAN);
440  }
442  {
443  this->SetTetQualityMeasure(QualityMeasureTypes::SCALED_JACOBIAN);
444  }
445  void SetTetQualityMeasureToShape() { this->SetTetQualityMeasure(QualityMeasureTypes::SHAPE); }
447  {
448  this->SetTetQualityMeasure(QualityMeasureTypes::RELATIVE_SIZE_SQUARED);
449  }
451  {
452  this->SetTetQualityMeasure(QualityMeasureTypes::SHAPE_AND_SIZE);
453  }
455  {
456  this->SetTetQualityMeasure(QualityMeasureTypes::DISTORTION);
457  }
459  {
460  this->SetTetQualityMeasure(QualityMeasureTypes::EQUIANGLE_SKEW);
461  }
463  {
464  this->SetTetQualityMeasure(QualityMeasureTypes::EQUIVOLUME_SKEW);
465  }
467  {
468  this->SetTetQualityMeasure(QualityMeasureTypes::MEAN_RATIO);
469  }
471  {
472  this->SetTetQualityMeasure(QualityMeasureTypes::NORMALIZED_INRADIUS);
473  }
475  {
476  this->SetTetQualityMeasure(QualityMeasureTypes::SQUISH_INDEX);
477  }
479 
481 
486  vtkSetEnumMacro(PyramidQualityMeasure, QualityMeasureTypes);
487  virtual void SetPyramidQualityMeasure(int measure)
488  {
489  this->SetPyramidQualityMeasure(static_cast<QualityMeasureTypes>(measure));
490  }
491  vtkGetEnumMacro(PyramidQualityMeasure, QualityMeasureTypes);
493  {
494  this->SetPyramidQualityMeasure(QualityMeasureTypes::EQUIANGLE_SKEW);
495  }
497  {
498  this->SetPyramidQualityMeasure(QualityMeasureTypes::JACOBIAN);
499  }
501  {
502  this->SetPyramidQualityMeasure(QualityMeasureTypes::SCALED_JACOBIAN);
503  }
505  {
506  this->SetPyramidQualityMeasure(QualityMeasureTypes::SHAPE);
507  }
509  {
510  this->SetPyramidQualityMeasure(QualityMeasureTypes::VOLUME);
511  }
513 
515 
521  vtkSetEnumMacro(WedgeQualityMeasure, QualityMeasureTypes);
522  virtual void SetWedgeQualityMeasure(int measure)
523  {
524  this->SetWedgeQualityMeasure(static_cast<QualityMeasureTypes>(measure));
525  }
526  vtkGetEnumMacro(WedgeQualityMeasure, QualityMeasureTypes);
528  {
529  this->SetWedgeQualityMeasure(QualityMeasureTypes::CONDITION);
530  }
532  {
533  this->SetWedgeQualityMeasure(QualityMeasureTypes::DISTORTION);
534  }
536  {
537  this->SetWedgeQualityMeasure(QualityMeasureTypes::EDGE_RATIO);
538  }
540  {
541  this->SetWedgeQualityMeasure(QualityMeasureTypes::EQUIANGLE_SKEW);
542  }
544  {
545  this->SetWedgeQualityMeasure(QualityMeasureTypes::JACOBIAN);
546  }
548  {
549  this->SetWedgeQualityMeasure(QualityMeasureTypes::MAX_ASPECT_FROBENIUS);
550  }
552  {
553  this->SetWedgeQualityMeasure(QualityMeasureTypes::MAX_STRETCH);
554  }
556  {
557  this->SetWedgeQualityMeasure(QualityMeasureTypes::MEAN_ASPECT_FROBENIUS);
558  }
560  {
561  this->SetWedgeQualityMeasure(QualityMeasureTypes::SCALED_JACOBIAN);
562  }
563  void SetWedgeQualityMeasureToShape() { this->SetWedgeQualityMeasure(QualityMeasureTypes::SHAPE); }
565  {
566  this->SetWedgeQualityMeasure(QualityMeasureTypes::VOLUME);
567  }
569 
571 
579  vtkSetEnumMacro(HexQualityMeasure, QualityMeasureTypes);
580  virtual void SetHexQualityMeasure(int measure)
581  {
582  this->SetHexQualityMeasure(static_cast<QualityMeasureTypes>(measure));
583  }
584  vtkGetEnumMacro(HexQualityMeasure, QualityMeasureTypes);
586  {
587  this->SetHexQualityMeasure(QualityMeasureTypes::EDGE_RATIO);
588  }
590  {
591  this->SetHexQualityMeasure(QualityMeasureTypes::MED_ASPECT_FROBENIUS);
592  }
594  {
595  this->SetHexQualityMeasure(QualityMeasureTypes::MAX_ASPECT_FROBENIUS);
596  }
598  {
599  this->SetHexQualityMeasure(QualityMeasureTypes::MAX_EDGE_RATIO);
600  }
601  void SetHexQualityMeasureToSkew() { this->SetHexQualityMeasure(QualityMeasureTypes::SKEW); }
602  void SetHexQualityMeasureToTaper() { this->SetHexQualityMeasure(QualityMeasureTypes::TAPER); }
603  void SetHexQualityMeasureToVolume() { this->SetHexQualityMeasure(QualityMeasureTypes::VOLUME); }
604  void SetHexQualityMeasureToStretch() { this->SetHexQualityMeasure(QualityMeasureTypes::STRETCH); }
606  {
607  this->SetHexQualityMeasure(QualityMeasureTypes::DIAGONAL);
608  }
610  {
611  this->SetHexQualityMeasure(QualityMeasureTypes::DIMENSION);
612  }
613  void SetHexQualityMeasureToOddy() { this->SetHexQualityMeasure(QualityMeasureTypes::ODDY); }
615  {
616  this->SetHexQualityMeasure(QualityMeasureTypes::CONDITION);
617  }
619  {
620  this->SetHexQualityMeasure(QualityMeasureTypes::JACOBIAN);
621  }
623  {
624  this->SetHexQualityMeasure(QualityMeasureTypes::SCALED_JACOBIAN);
625  }
626  void SetHexQualityMeasureToShear() { this->SetHexQualityMeasure(QualityMeasureTypes::SHEAR); }
627  void SetHexQualityMeasureToShape() { this->SetHexQualityMeasure(QualityMeasureTypes::SHAPE); }
629  {
630  this->SetHexQualityMeasure(QualityMeasureTypes::RELATIVE_SIZE_SQUARED);
631  }
633  {
634  this->SetHexQualityMeasure(QualityMeasureTypes::SHAPE_AND_SIZE);
635  }
637  {
638  this->SetHexQualityMeasure(QualityMeasureTypes::SHEAR_AND_SIZE);
639  }
641  {
642  this->SetHexQualityMeasure(QualityMeasureTypes::DISTORTION);
643  }
645  {
646  this->SetHexQualityMeasure(QualityMeasureTypes::EQUIANGLE_SKEW);
647  }
649  {
650  this->SetHexQualityMeasure(QualityMeasureTypes::NODAL_JACOBIAN_RATIO);
651  }
653 
659  static double TriangleArea(vtkCell* cell, bool linearApproximation = false);
660 
672  static double TriangleAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
673 
683  static double TriangleAspectRatio(vtkCell* cell, bool linearApproximation = false);
684 
690  static double TriangleCondition(vtkCell* cell, bool linearApproximation = false);
691 
698  static double TriangleDistortion(vtkCell* cell, bool linearApproximation = false);
699 
709  static double TriangleEdgeRatio(vtkCell* cell, bool linearApproximation = false);
710 
716  static double TriangleEquiangleSkew(vtkCell* cell, bool linearApproximation = false);
717 
723  static double TriangleMaxAngle(vtkCell* cell, bool linearApproximation = false);
724 
730  static double TriangleMinAngle(vtkCell* cell, bool linearApproximation = false);
731 
739  static double TriangleNormalizedInradius(vtkCell* cell, bool linearApproximation = false);
740 
750  static double TriangleRadiusRatio(vtkCell* cell, bool linearApproximation = false);
751 
761  static double TriangleRelativeSizeSquared(vtkCell* cell, bool linearApproximation = false);
762 
768  static double TriangleScaledJacobian(vtkCell* cell, bool linearApproximation = false);
769 
775  static double TriangleShape(vtkCell* cell, bool linearApproximation = false);
776 
786  static double TriangleShapeAndSize(vtkCell* cell, bool linearApproximation = false);
787 
794  static double QuadArea(vtkCell* cell, bool linearApproximation = false);
795 
805  static double QuadAspectRatio(vtkCell* cell, bool linearApproximation = false);
806 
814  static double QuadCondition(vtkCell* cell, bool linearApproximation = false);
815 
823  static double QuadDistortion(vtkCell* cell, bool linearApproximation = false);
824 
834  static double QuadEdgeRatio(vtkCell* cell, bool linearApproximation = false);
835 
841  static double QuadEquiangleSkew(vtkCell* cell, bool linearApproximation = false);
842 
850  static double QuadJacobian(vtkCell* cell, bool linearApproximation = false);
851 
857  static double QuadMaxAngle(vtkCell* cell, bool linearApproximation = false);
858 
870  static double QuadMaxAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
871 
877  static double QuadMaxEdgeRatio(vtkCell* cell, bool linearApproximation = false);
878 
890  static double QuadMedAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
891 
897  static double QuadMinAngle(vtkCell* cell, bool linearApproximation = false);
898 
906  static double QuadOddy(vtkCell* cell, bool linearApproximation = false);
907 
920  static double QuadRadiusRatio(vtkCell* cell, bool linearApproximation = false);
921 
933  static double QuadRelativeSizeSquared(vtkCell* cell, bool linearApproximation = false);
934 
942  static double QuadScaledJacobian(vtkCell* cell, bool linearApproximation = false);
943 
950  static double QuadShape(vtkCell* cell, bool linearApproximation = false);
951 
962  static double QuadShapeAndSize(vtkCell* cell, bool linearApproximation = false);
963 
970  static double QuadShear(vtkCell* cell, bool linearApproximation = false);
971 
982  static double QuadShearAndSize(vtkCell* cell, bool linearApproximation = false);
983 
991  static double QuadSkew(vtkCell* cell, bool linearApproximation = false);
992 
999  static double QuadStretch(vtkCell* cell, bool linearApproximation = false);
1000 
1007  static double QuadTaper(vtkCell* cell, bool linearApproximation = false);
1008 
1016  static double QuadWarpage(vtkCell* cell, bool linearApproximation = false);
1017 
1030  static double TetAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
1031 
1039  static double TetAspectGamma(vtkCell* cell, bool linearApproximation = false);
1040 
1050  static double TetAspectRatio(vtkCell* cell, bool linearApproximation = false);
1051 
1060  static double TetCollapseRatio(vtkCell* cell, bool linearApproximation = false);
1061 
1068  static double TetCondition(vtkCell* cell, bool linearApproximation = false);
1069 
1078  static double TetDistortion(vtkCell* cell, bool linearApproximation = false);
1079 
1089  static double TetEdgeRatio(vtkCell* cell, bool linearApproximation = false);
1090 
1096  static double TetEquiangleSkew(vtkCell* cell, bool linearApproximation = false);
1097 
1103  static double TetEquivolumeSkew(vtkCell* cell, bool linearApproximation = false);
1104 
1111  static double TetInradius(vtkCell* cell, bool linearApproximation = false);
1112 
1119  static double TetJacobian(vtkCell* cell, bool linearApproximation = false);
1120 
1128  static double TetMeanRatio(vtkCell* cell, bool linearApproximation = false);
1129 
1135  static double TetMinAngle(vtkCell* cell, bool linearApproximation = false);
1136 
1144  static double TetNormalizedInradius(vtkCell* cell, bool linearApproximation = false);
1145 
1155  static double TetRadiusRatio(vtkCell* cell, bool linearApproximation = false);
1156 
1168  static double TetRelativeSizeSquared(vtkCell* cell, bool linearApproximation = false);
1169 
1177  static double TetScaledJacobian(vtkCell* cell, bool linearApproximation = false);
1178 
1185  static double TetShape(vtkCell* cell, bool linearApproximation = false);
1186 
1197  static double TetShapeAndSize(vtkCell* cell, bool linearApproximation = false);
1198 
1204  static double TetSquishIndex(vtkCell* cell, bool linearApproximation = false);
1205 
1212  static double TetVolume(vtkCell* cell, bool linearApproximation = false);
1213 
1219  static double PyramidEquiangleSkew(vtkCell* cell, bool linearApproximation = false);
1220 
1227  static double PyramidJacobian(vtkCell* cell, bool linearApproximation = false);
1228 
1235  static double PyramidScaledJacobian(vtkCell* cell, bool linearApproximation = false);
1236 
1244  static double PyramidShape(vtkCell* cell, bool linearApproximation = false);
1245 
1251  static double PyramidVolume(vtkCell* cell, bool linearApproximation = false);
1252 
1259  static double WedgeCondition(vtkCell* cell, bool linearApproximation = false);
1260 
1267  static double WedgeDistortion(vtkCell* cell, bool linearApproximation = false);
1268 
1276  static double WedgeEdgeRatio(vtkCell* cell, bool linearApproximation = false);
1277 
1283  static double WedgeEquiangleSkew(vtkCell* cell, bool linearApproximation = false);
1284 
1291  static double WedgeJacobian(vtkCell* cell, bool linearApproximation = false);
1292 
1299  static double WedgeMaxAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
1300 
1308  static double WedgeMaxStretch(vtkCell* cell, bool linearApproximation = false);
1309 
1317  static double WedgeMeanAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
1318 
1330  static double WedgeScaledJacobian(vtkCell* cell, bool linearApproximation = false);
1331 
1339  static double WedgeShape(vtkCell* cell, bool linearApproximation = false);
1340 
1346  static double WedgeVolume(vtkCell* cell, bool linearApproximation = false);
1347 
1354  static double HexCondition(vtkCell* cell, bool linearApproximation = false);
1355 
1362  static double HexDiagonal(vtkCell* cell, bool linearApproximation = false);
1363 
1371  static double HexDimension(vtkCell* cell, bool linearApproximation = false);
1372 
1380  static double HexDistortion(vtkCell* cell, bool linearApproximation = false);
1381 
1391  static double HexEdgeRatio(vtkCell* cell, bool linearApproximation = false);
1392 
1398  static double HexEquiangleSkew(vtkCell* cell, bool linearApproximation = false);
1399 
1407  static double HexJacobian(vtkCell* cell, bool linearApproximation = false);
1408 
1415  static double HexMaxAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
1416 
1422  static double HexMaxEdgeRatio(vtkCell* cell, bool linearApproximation = false);
1423 
1430  static double HexMedAspectFrobenius(vtkCell* cell, bool linearApproximation = false);
1431 
1438  static double HexNodalJacobianRatio(vtkCell* cell, bool linearApproximation = false);
1439 
1447  static double HexOddy(vtkCell* cell, bool linearApproximation = false);
1448 
1460  static double HexRelativeSizeSquared(vtkCell* cell, bool linearApproximation = false);
1461 
1469  static double HexScaledJacobian(vtkCell* cell, bool linearApproximation = false);
1470 
1477  static double HexShape(vtkCell* cell, bool linearApproximation = false);
1478 
1489  static double HexShapeAndSize(vtkCell* cell, bool linearApproximation = false);
1490 
1497  static double HexShear(vtkCell* cell, bool linearApproximation = false);
1498 
1508  static double HexShearAndSize(vtkCell* cell, bool linearApproximation = false);
1509 
1518  static double HexSkew(vtkCell* cell, bool linearApproximation = false);
1519 
1526  static double HexStretch(vtkCell* cell, bool linearApproximation = false);
1527 
1534  static double HexTaper(vtkCell* cell, bool linearApproximation = false);
1541  static double HexVolume(vtkCell* cell, bool linearApproximation = false);
1542 
1553  VTK_DEPRECATED_IN_9_6_0("Please use SetSaveCellQuality instead.")
1554  virtual void SetRatio(vtkTypeBool r) { this->SetSaveCellQuality(r); }
1555  VTK_DEPRECATED_IN_9_6_0("Please use GetSaveCellQuality instead.")
1556  vtkTypeBool GetRatio() { return this->GetSaveCellQuality(); }
1557  VTK_DEPRECATED_IN_9_6_0("Please use SaveCellQualityOn instead.")
1558  void RatioOn() { this->SaveCellQualityOn(); }
1559  VTK_DEPRECATED_IN_9_6_0("Please use SaveCellQualityOff instead.")
1560  void RatioOff() { this->SaveCellQualityOff(); }
1561 
1562 protected:
1563  vtkMeshQuality();
1564  ~vtkMeshQuality() override = default;
1565 
1567 
1576 
1577  using CellQualityType = std::function<double(vtkCell*, bool)>;
1578  CellQualityType GetTriangleQualityMeasureFunction() const;
1579  CellQualityType GetQuadraticTriangleQualityMeasureFunction() const;
1580  CellQualityType GetBiQuadraticTriangleQualityMeasureFunction() const;
1581  CellQualityType GetQuadQualityMeasureFunction() const;
1582  CellQualityType GetQuadraticQuadQualityMeasureFunction() const;
1583  CellQualityType GetBiQuadraticQuadQualityMeasureFunction() const;
1584  CellQualityType GetTetQualityMeasureFunction() const;
1585  CellQualityType GetQuadraticTetQualityMeasureFunction() const;
1586  CellQualityType GetPyramidQualityMeasureFunction() const;
1587  CellQualityType GetWedgeQualityMeasureFunction() const;
1588  CellQualityType GetHexQualityMeasureFunction() const;
1589  CellQualityType GetQuadraticHexQualityMeasureFunction() const;
1590  CellQualityType GetTriQuadraticHexQualityMeasureFunction() const;
1591 
1592  // Variables used to store the average size (2D: area / 3D: volume)
1593  static double TriangleAverageSize;
1594  static double QuadAverageSize;
1595  static double TetAverageSize;
1596  static double PyramidAverageSize;
1597  static double WedgeAverageSize;
1598  static double HexAverageSize;
1599 
1600 private:
1601  vtkMeshQuality(const vtkMeshQuality&) = delete;
1602  void operator=(const vtkMeshQuality&) = delete;
1603 };
1604 
1605 VTK_ABI_NAMESPACE_END
1606 #endif // vtkMeshQuality_h
QualityMeasureTypes
Enum which lists the Quality Measures Types.
void SetQuadQualityMeasureToEdgeRatio()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetQuadQualityMeasureToWarpage()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
static double TriangleAverageSize
void SetQuadQualityMeasureToRelativeSizeSquared()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetHexQualityMeasureToMedAspectFrobenius()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetTetQualityMeasureToMinAngle()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetHexQualityMeasureToRelativeSizeSquared()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetQuadQualityMeasureToRadiusRatio()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
QualityMeasureTypes WedgeQualityMeasure
void SetTriangleQualityMeasureToAspectFrobenius()
Set/Get the particular estimator used to function the quality of triangles.
void SetWedgeQualityMeasureToJacobian()
Set/Get the particular estimator used to measure the quality of wedges.
void SetTriangleQualityMeasureToArea()
Set/Get the particular estimator used to function the quality of triangles.
void SetTriangleQualityMeasureToAspectRatio()
Set/Get the particular estimator used to function the quality of triangles.
void SetHexQualityMeasureToScaledJacobian()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetPyramidQualityMeasureToEquiangleSkew()
Set/Get the particular estimator used to measure the quality of pyramids.
void SetTetQualityMeasureToScaledJacobian()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTetQualityMeasureToEdgeRatio()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTetQualityMeasureToMeanRatio()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTetQualityMeasureToEquiangleSkew()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetHexQualityMeasureToVolume()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetQuadQualityMeasureToOddy()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
Store vtkAlgorithm input/output information.
void SetHexQualityMeasureToShapeAndSize()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetWedgeQualityMeasureToShape()
Set/Get the particular estimator used to measure the quality of wedges.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
void SetQuadQualityMeasureToMaxAngle()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetHexQualityMeasureToEquiangleSkew()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetWedgeQualityMeasureToMeanAspectFrobenius()
Set/Get the particular estimator used to measure the quality of wedges.
void SetHexQualityMeasureToEdgeRatio()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetQuadQualityMeasureToMaxEdgeRatio()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetPyramidQualityMeasureToScaledJacobian()
Set/Get the particular estimator used to measure the quality of pyramids.
void SetTetQualityMeasureToRelativeSizeSquared()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTriangleQualityMeasureToEquiangleSkew()
Set/Get the particular estimator used to function the quality of triangles.
void SetPyramidQualityMeasureToJacobian()
Set/Get the particular estimator used to measure the quality of pyramids.
void SetTetQualityMeasureToNormalizedInradius()
Set/Get the particular estimator used to measure the quality of tetrahedra.
std::function< double(vtkCell *, bool)> CellQualityType
void SetTetQualityMeasureToCondition()
Set/Get the particular estimator used to measure the quality of tetrahedra.
QualityMeasureTypes PyramidQualityMeasure
void SetTetQualityMeasureToShapeAndSize()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTriangleQualityMeasureToDistortion()
Set/Get the particular estimator used to function the quality of triangles.
static double WedgeAverageSize
void SetTriangleQualityMeasureToCondition()
Set/Get the particular estimator used to function the quality of triangles.
virtual void SetPyramidQualityMeasure(int measure)
Set/Get the particular estimator used to measure the quality of pyramids.
void SetQuadQualityMeasureToMinAngle()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetQuadQualityMeasureToMedAspectFrobenius()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetQuadQualityMeasureToShearAndSize()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetHexQualityMeasureToNodalJacobianRatio()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetHexQualityMeasureToSkew()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetQuadQualityMeasureToMaxAspectFrobenius()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetTriangleQualityMeasureToShape()
Set/Get the particular estimator used to function the quality of triangles.
void SetQuadQualityMeasureToAspectRatio()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetTriangleQualityMeasureToScaledJacobian()
Set/Get the particular estimator used to function the quality of triangles.
void SetTetQualityMeasureToJacobian()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetWedgeQualityMeasureToScaledJacobian()
Set/Get the particular estimator used to measure the quality of wedges.
void SetTetQualityMeasureToDistortion()
Set/Get the particular estimator used to measure the quality of tetrahedra.
dynamic, self-adjusting array of double
void SetQuadQualityMeasureToScaledJacobian()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetQuadQualityMeasureToJacobian()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
int vtkTypeBool
Definition: vtkABI.h:64
vtkTypeBool SaveCellQuality
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetWedgeQualityMeasureToVolume()
Set/Get the particular estimator used to measure the quality of wedges.
void SetHexQualityMeasureToDiagonal()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetWedgeQualityMeasureToCondition()
Set/Get the particular estimator used to measure the quality of wedges.
abstract class to specify cell behavior
Definition: vtkCell.h:50
QualityMeasureTypes TriangleQualityMeasure
void SetQuadQualityMeasureToStretch()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
#define VTK_DEPRECATED_IN_9_6_0(reason)
void SetTriangleQualityMeasureToRadiusRatio()
Set/Get the particular estimator used to function the quality of triangles.
void SetTriangleQualityMeasureToEdgeRatio()
Set/Get the particular estimator used to function the quality of triangles.
void SetTetQualityMeasureToCollapseRatio()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetPyramidQualityMeasureToVolume()
Set/Get the particular estimator used to measure the quality of pyramids.
void SetTetQualityMeasureToAspectFrobenius()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetHexQualityMeasureToDistortion()
Set/Get the particular estimator used to measure the quality of hexahedra.
a simple class to control print indentation
Definition: vtkIndent.h:28
void SetHexQualityMeasureToJacobian()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetTetQualityMeasureToVolume()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetWedgeQualityMeasureToEquiangleSkew()
Set/Get the particular estimator used to measure the quality of wedges.
void SetQuadQualityMeasureToEquiangleSkew()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetHexQualityMeasureToMaxAspectFrobenius()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetTriangleQualityMeasureToMinAngle()
Set/Get the particular estimator used to function the quality of triangles.
QualityMeasureTypes HexQualityMeasure
void SetTetQualityMeasureToRadiusRatio()
Set/Get the particular estimator used to measure the quality of tetrahedra.
virtual void SetHexQualityMeasure(int measure)
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetQuadQualityMeasureToShapeAndSize()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:44
void SetQuadQualityMeasureToShear()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
virtual void SetQuadQualityMeasure(int measure)
Set/Get the particular estimator used to measure the quality of quadrilaterals.
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks the algorithm to do its work.
void SetTriangleQualityMeasureToRelativeSizeSquared()
Set/Get the particular estimator used to function the quality of triangles.
void SetWedgeQualityMeasureToDistortion()
Set/Get the particular estimator used to measure the quality of wedges.
void SetQuadQualityMeasureToArea()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetHexQualityMeasureToStretch()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetTriangleQualityMeasureToShapeAndSize()
Set/Get the particular estimator used to function the quality of triangles.
void SetHexQualityMeasureToMaxEdgeRatio()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetHexQualityMeasureToShearAndSize()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetHexQualityMeasureToTaper()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetHexQualityMeasureToShear()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetTetQualityMeasureToSquishIndex()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetHexQualityMeasureToShape()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetQuadQualityMeasureToDistortion()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
static double HexAverageSize
static double TetAverageSize
void SetHexQualityMeasureToOddy()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetWedgeQualityMeasureToMaxAspectFrobenius()
Set/Get the particular estimator used to measure the quality of wedges.
void SetQuadQualityMeasureToSkew()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
virtual void SetTetQualityMeasure(int measure)
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTetQualityMeasureToAspectRatio()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetWedgeQualityMeasureToMaxStretch()
Set/Get the particular estimator used to measure the quality of wedges.
void SetQuadQualityMeasureToShape()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
virtual void SetWedgeQualityMeasure(int measure)
Set/Get the particular estimator used to measure the quality of wedges.
QualityMeasureTypes TetQualityMeasure
static double QuadAverageSize
void SetTriangleQualityMeasureToMaxAngle()
Set/Get the particular estimator used to function the quality of triangles.
Store zero or more vtkInformation instances.
void SetTetQualityMeasureToInradius()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetTetQualityMeasureToAspectGamma()
Set/Get the particular estimator used to measure the quality of tetrahedra.
QualityMeasureTypes QuadQualityMeasure
Calculate functions of quality of the elements of a mesh.
Superclass for algorithms that produce output of the same type as input.
void SetHexQualityMeasureToDimension()
Set/Get the particular estimator used to measure the quality of hexahedra.
void SetPyramidQualityMeasureToShape()
Set/Get the particular estimator used to measure the quality of pyramids.
virtual void SetTriangleQualityMeasure(int measure)
Set/Get the particular estimator used to function the quality of triangles.
void SetQuadQualityMeasureToTaper()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetTetQualityMeasureToShape()
Set/Get the particular estimator used to measure the quality of tetrahedra.
static vtkDataSetAlgorithm * New()
void SetTriangleQualityMeasureToNormalizedInradius()
Set/Get the particular estimator used to function the quality of triangles.
static double PyramidAverageSize
void SetWedgeQualityMeasureToEdgeRatio()
Set/Get the particular estimator used to measure the quality of wedges.
void SetQuadQualityMeasureToCondition()
Set/Get the particular estimator used to measure the quality of quadrilaterals.
void SetTetQualityMeasureToEquivolumeSkew()
Set/Get the particular estimator used to measure the quality of tetrahedra.
void SetHexQualityMeasureToCondition()
Set/Get the particular estimator used to measure the quality of hexahedra.