MFEM  v4.6.0
Finite element discretization library
Public Types | Public Member Functions | Protected Attributes | List of all members
mfem::TMOP_WorstCaseUntangleOptimizer_Metric Class Reference

#include <tmop.hpp>

Inheritance diagram for mfem::TMOP_WorstCaseUntangleOptimizer_Metric:
[legend]
Collaboration diagram for mfem::TMOP_WorstCaseUntangleOptimizer_Metric:
[legend]

Public Types

enum  BarrierType { BarrierType::None, BarrierType::Shifted, BarrierType::Pseudo }
 
enum  WorstCaseType { WorstCaseType::None, WorstCaseType::Beta, WorstCaseType::PMean }
 

Public Member Functions

 TMOP_WorstCaseUntangleOptimizer_Metric (TMOP_QualityMetric &tmop_metric_, int exponent_=1, double alpha_=1.5, double detT_ep_=0.0001, double muT_ep_=0.0001, BarrierType btype_=BarrierType::None, WorstCaseType wctype_=WorstCaseType::None)
 
virtual double EvalW (const DenseMatrix &Jpt) const
 Evaluate the strain energy density function, W = W(Jpt), by using the 2D or 3D matrix invariants, see linalg/invariants.hpp. More...
 
virtual void EvalP (const DenseMatrix &Jpt, DenseMatrix &P) const
 Evaluate the 1st Piola-Kirchhoff stress tensor, P = P(Jpt). More...
 
virtual void AssembleH (const DenseMatrix &Jpt, const DenseMatrix &DS, const double weight, DenseMatrix &A) const
 Evaluate the derivative of the 1st Piola-Kirchhoff stress tensor and assemble its contribution to the local gradient matrix 'A'. More...
 
virtual double EvalWBarrier (const DenseMatrix &Jpt) const
 
virtual void SetMinDetT (double min_detT_)
 
virtual void SetMaxMuT (double max_muT_)
 
virtual BarrierType GetBarrierType ()
 
virtual WorstCaseType GetWorstCaseType ()
 
- Public Member Functions inherited from mfem::TMOP_QualityMetric
 TMOP_QualityMetric ()
 
virtual ~TMOP_QualityMetric ()
 
virtual void SetTargetJacobian (const DenseMatrix &Jtr_)
 Specify the reference-element -> target-element Jacobian matrix for the point of interest. More...
 
virtual double EvalWMatrixForm (const DenseMatrix &Jpt) const
 Evaluates the metric in matrix form (opposed to invariant form). Used for validating the invariant evaluations. More...
 
virtual int Id () const
 Return the metric ID. More...
 
- Public Member Functions inherited from mfem::HyperelasticModel
 HyperelasticModel ()
 
virtual ~HyperelasticModel ()
 
void SetTransformation (ElementTransformation &Ttr_)
 

Protected Attributes

TMOP_QualityMetrictmop_metric
 
double min_detT
 
double max_muT
 
int exponent
 
double alpha
 
double detT_ep
 
double muT_ep
 
BarrierType btype
 
WorstCaseType wctype
 
- Protected Attributes inherited from mfem::TMOP_QualityMetric
const DenseMatrixJtr
 
- Protected Attributes inherited from mfem::HyperelasticModel
ElementTransformationTtr
 

Additional Inherited Members

- Protected Member Functions inherited from mfem::TMOP_QualityMetric
void SetTransformation (ElementTransformation &)
 The method HyperelasticModel::SetTransformation() is hidden for TMOP_QualityMetrics, because it is not used. More...
 

Detailed Description

Simultaneous Untangler + Worst Case Improvement Metric Uses a base metric mu and is defined as: mu_tilde = mu_hat, when WorstCaseType = None, = mu_hat/(beta - mu_hat), when WorstCaseType = Beta, = mu_hat^p, when WorstCaseType = PMean, where beta = max(mu_hat) + muT_ep, and mu_hat = (mu/2phi(tau,ep)) where 2phi(tau,ep) = 1, when when BarrierType = None, = 2*(tau - min(alpha*min(tau)-detT_ep,0)), when BarrierType = Shifted = tau^2 + sqrt(tau^2 + ep^2), when BarrierType = Pseudo where tau = det(T), and max(mu_hat) and min(tau) are computed over the entire mesh. Ultimately, this metric can be used for mesh untangling with the BarrierType option and for worst case quality improvement with the WorstCaseType option.

Definition at line 151 of file tmop.hpp.

Member Enumeration Documentation

◆ BarrierType

Enumerator
None 
Shifted 
Pseudo 

Definition at line 154 of file tmop.hpp.

◆ WorstCaseType

Enumerator
None 
Beta 
PMean 

Definition at line 160 of file tmop.hpp.

Constructor & Destructor Documentation

◆ TMOP_WorstCaseUntangleOptimizer_Metric()

mfem::TMOP_WorstCaseUntangleOptimizer_Metric::TMOP_WorstCaseUntangleOptimizer_Metric ( TMOP_QualityMetric tmop_metric_,
int  exponent_ = 1,
double  alpha_ = 1.5,
double  detT_ep_ = 0.0001,
double  muT_ep_ = 0.0001,
BarrierType  btype_ = BarrierType::None,
WorstCaseType  wctype_ = WorstCaseType::None 
)
inline

Definition at line 179 of file tmop.hpp.

Member Function Documentation

◆ AssembleH()

virtual void mfem::TMOP_WorstCaseUntangleOptimizer_Metric::AssembleH ( const DenseMatrix Jpt,
const DenseMatrix DS,
const double  weight,
DenseMatrix A 
) const
inlinevirtual

Evaluate the derivative of the 1st Piola-Kirchhoff stress tensor and assemble its contribution to the local gradient matrix 'A'.

Parameters
[in]JptRepresents the target->physical transformation Jacobian matrix.
[in]DSGradient of the basis matrix (dof x dim).
[in]weightQuadrature weight coefficient for the point.
[in,out]ALocal gradient matrix where the contribution from this point will be added.

Computes weight * d(dW_dxi)_d(xj) at the current point, for all i and j, where x1 ... xn are the FE dofs. This function is usually defined using the matrix invariants and their derivatives.

Implements mfem::TMOP_QualityMetric.

Definition at line 204 of file tmop.hpp.

◆ EvalP()

virtual void mfem::TMOP_WorstCaseUntangleOptimizer_Metric::EvalP ( const DenseMatrix Jpt,
DenseMatrix P 
) const
inlinevirtual

Evaluate the 1st Piola-Kirchhoff stress tensor, P = P(Jpt).

Parameters
[in]JptRepresents the target->physical transformation Jacobian matrix.
[out]PThe evaluated 1st Piola-Kirchhoff stress tensor.

Implements mfem::TMOP_QualityMetric.

Definition at line 201 of file tmop.hpp.

◆ EvalW()

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::EvalW ( const DenseMatrix Jpt) const
virtual

Evaluate the strain energy density function, W = W(Jpt), by using the 2D or 3D matrix invariants, see linalg/invariants.hpp.

Parameters
[in]JptRepresents the target->physical transformation Jacobian matrix.

Implements mfem::TMOP_QualityMetric.

Definition at line 167 of file tmop.cpp.

◆ EvalWBarrier()

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::EvalWBarrier ( const DenseMatrix Jpt) const
virtual

Definition at line 184 of file tmop.cpp.

◆ GetBarrierType()

virtual BarrierType mfem::TMOP_WorstCaseUntangleOptimizer_Metric::GetBarrierType ( )
inlinevirtual

Definition at line 215 of file tmop.hpp.

◆ GetWorstCaseType()

virtual WorstCaseType mfem::TMOP_WorstCaseUntangleOptimizer_Metric::GetWorstCaseType ( )
inlinevirtual

Definition at line 217 of file tmop.hpp.

◆ SetMaxMuT()

virtual void mfem::TMOP_WorstCaseUntangleOptimizer_Metric::SetMaxMuT ( double  max_muT_)
inlinevirtual

Definition at line 213 of file tmop.hpp.

◆ SetMinDetT()

virtual void mfem::TMOP_WorstCaseUntangleOptimizer_Metric::SetMinDetT ( double  min_detT_)
inlinevirtual

Definition at line 211 of file tmop.hpp.

Member Data Documentation

◆ alpha

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::alpha
protected

Definition at line 172 of file tmop.hpp.

◆ btype

BarrierType mfem::TMOP_WorstCaseUntangleOptimizer_Metric::btype
protected

Definition at line 175 of file tmop.hpp.

◆ detT_ep

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::detT_ep
protected

Definition at line 173 of file tmop.hpp.

◆ exponent

int mfem::TMOP_WorstCaseUntangleOptimizer_Metric::exponent
protected

Definition at line 171 of file tmop.hpp.

◆ max_muT

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::max_muT
protected

Definition at line 170 of file tmop.hpp.

◆ min_detT

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::min_detT
protected

Definition at line 169 of file tmop.hpp.

◆ muT_ep

double mfem::TMOP_WorstCaseUntangleOptimizer_Metric::muT_ep
protected

Definition at line 174 of file tmop.hpp.

◆ tmop_metric

TMOP_QualityMetric& mfem::TMOP_WorstCaseUntangleOptimizer_Metric::tmop_metric
protected

Definition at line 168 of file tmop.hpp.

◆ wctype

WorstCaseType mfem::TMOP_WorstCaseUntangleOptimizer_Metric::wctype
protected

Definition at line 176 of file tmop.hpp.


The documentation for this class was generated from the following files: