KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Public Member Functions | List of all members
Kratos::MmgUtilities< TMMGLibrary > Class Template Reference

Provides the Kratos interface to the MMG library API. More...

#include <mmg_utilities.h>

Collaboration diagram for Kratos::MmgUtilities< TMMGLibrary >:

Public Member Functions

IndexVectorType CheckFirstTypeConditions ()
 
IndexVectorType CheckFirstTypeConditions ()
 
IndexVectorType CheckFirstTypeConditions ()
 
IndexVectorType CheckSecondTypeConditions ()
 
IndexVectorType CheckSecondTypeConditions ()
 
IndexVectorType CheckSecondTypeConditions ()
 
IndexVectorType CheckFirstTypeElements ()
 
IndexVectorType CheckFirstTypeElements ()
 
IndexVectorType CheckFirstTypeElements ()
 
IndexVectorType CheckSecondTypeElements ()
 
IndexVectorType CheckSecondTypeElements ()
 
IndexVectorType CheckSecondTypeElements ()
 
void BlockNode (const IndexType iNode)
 
void BlockNode (const IndexType iNode)
 
void BlockNode (const IndexType iNode)
 
void BlockCondition (const IndexType iCondition)
 
void BlockCondition (const IndexType iCondition)
 
void BlockCondition (const IndexType iCondition)
 
void BlockElement (const IndexType iElement)
 
void BlockElement (const IndexType iElement)
 
void BlockElement (const IndexType iElement)
 
Node::Pointer CreateNode (ModelPart &rModelPart, const IndexType iNode, int &Ref, int &IsRequired)
 
Node::Pointer CreateNode (ModelPart &rModelPart, const IndexType iNode, int &Ref, int &IsRequired)
 
Node::Pointer CreateNode (ModelPart &rModelPart, const IndexType iNode, int &Ref, int &IsRequired)
 
Condition::Pointer CreateFirstTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 
Condition::Pointer CreateFirstTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 
Condition::Pointer CreateFirstTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 
Condition::Pointer CreateSecondTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 
Condition::Pointer CreateSecondTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 
Condition::Pointer CreateSecondTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 
Element::Pointer CreateFirstTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 
Element::Pointer CreateFirstTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 
Element::Pointer CreateFirstTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 
Element::Pointer CreateSecondTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 
Element::Pointer CreateSecondTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 
Element::Pointer CreateSecondTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 
void InitMesh ()
 
void InitMesh ()
 
void InitMesh ()
 
void InitVerbosityParameter (const IndexType VerbosityMMG)
 
void InitVerbosityParameter (const IndexType VerbosityMMG)
 
void InitVerbosityParameter (const IndexType VerbosityMMG)
 
void SetMeshOptimizationModeParameter (const bool EnableMeshOptimization)
 
void SetMeshOptimizationModeParameter (const bool EnableMeshOptimization)
 
void SetMeshOptimizationModeParameter (const bool EnableMeshOptimization)
 
void SetMeshSize (MMGMeshInfo< MMGLibrary::MMG2D > &rMMGMeshInfo)
 
void SetMeshSize (MMGMeshInfo< MMGLibrary::MMG3D > &rMMGMeshInfo)
 
void SetMeshSize (MMGMeshInfo< MMGLibrary::MMGS > &rMMGMeshInfo)
 
void SetSolSizeScalar (const SizeType NumNodes)
 
void SetSolSizeScalar (const SizeType NumNodes)
 
void SetSolSizeScalar (const SizeType NumNodes)
 
void SetSolSizeVector (const SizeType NumNodes)
 
void SetSolSizeVector (const SizeType NumNodes)
 
void SetSolSizeVector (const SizeType NumNodes)
 
void SetSolSizeTensor (const SizeType NumNodes)
 
void SetSolSizeTensor (const SizeType NumNodes)
 
void SetSolSizeTensor (const SizeType NumNodes)
 
void SetDispSizeVector (const SizeType NumNodes)
 
void SetDispSizeVector (const SizeType NumNodes)
 
void SetDispSizeVector (const SizeType NumNodes)
 
void CheckMeshData ()
 
void CheckMeshData ()
 
void CheckMeshData ()
 
void InputMesh (const std::string &rOutputName)
 
void InputMesh (const std::string &rOutputName)
 
void InputMesh (const std::string &rOutputName)
 
void InputSol (const std::string &rInputName)
 
void InputSol (const std::string &rInputName)
 
void InputSol (const std::string &rInputName)
 
void OutputMesh (const std::string &rOutputName)
 
void OutputMesh (const std::string &rOutputName)
 
void OutputMesh (const std::string &rOutputName)
 
void OutputSol (const std::string &rOutputName)
 
void OutputSol (const std::string &rOutputName)
 
void OutputSol (const std::string &rOutputName)
 
void OutputDisplacement (const std::string &rOutputName)
 
void OutputDisplacement (const std::string &rOutputName)
 
void OutputDisplacement (const std::string &rOutputName)
 
void FreeAll ()
 
void FreeAll ()
 
void FreeAll ()
 
void MMGLibCallMetric (Parameters ConfigurationParameters)
 
void MMGLibCallIsoSurface (Parameters ConfigurationParameters)
 
void MMGLibCallMetric (Parameters ConfigurationParameters)
 
void MMGLibCallIsoSurface (Parameters ConfigurationParameters)
 
void MMGLibCallMetric (Parameters ConfigurationParameters)
 
void MMGLibCallIsoSurface (Parameters ConfigurationParameters)
 
void SetNumberOfLocalParameters (IndexType NumberOfLocalParameter)
 
void SetNumberOfLocalParameters (IndexType NumberOfLocalParameter)
 
void SetNumberOfLocalParameters (IndexType NumberOfLocalParameter)
 
void SetLocalParameter (IndexType rColor, double HMin, double HMax, double HausdorffValue)
 
void SetLocalParameter (IndexType rColor, double HMin, double HMax, double HausdorffValue)
 
void SetLocalParameter (IndexType rColor, double HMin, double HMax, double HausdorffValue)
 
void SetNodes (const double X, const double Y, const double Z, const IndexType Color, const IndexType Index)
 
void SetNodes (const double X, const double Y, const double Z, const IndexType Color, const IndexType Index)
 
void SetNodes (const double X, const double Y, const double Z, const IndexType Color, const IndexType Index)
 
void SetConditions (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 
void SetConditions (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 
void SetConditions (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 
void SetElements (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 
void SetElements (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 
void SetElements (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 
void SetMetricScalar (const double Metric, const IndexType NodeId)
 
void SetMetricScalar (const double Metric, const IndexType NodeId)
 
void SetMetricScalar (const double Metric, const IndexType NodeId)
 
void SetMetricVector (const array_1d< double, 2 > &rMetric, const IndexType NodeId)
 
void SetMetricVector (const array_1d< double, 3 > &rMetric, const IndexType NodeId)
 
void SetMetricVector (const array_1d< double, 3 > &rMetric, const IndexType NodeId)
 
void SetMetricTensor (const array_1d< double, 3 > &rMetric, const IndexType NodeId)
 
void SetMetricTensor (const array_1d< double, 6 > &rMetric, const IndexType NodeId)
 
void SetMetricTensor (const array_1d< double, 6 > &rMetric, const IndexType NodeId)
 
void SetDisplacementVector (const array_1d< double, 3 > &rDisplacement, const IndexType NodeId)
 
void SetDisplacementVector (const array_1d< double, 3 > &rDisplacement, const IndexType NodeId)
 
void SetDisplacementVector (const array_1d< double, 3 > &rDisplacement, const IndexType NodeId)
 
void GetMetricScalar (double &rMetric)
 
void GetMetricScalar (double &rMetric)
 
void GetMetricScalar (double &rMetric)
 
void GetMetricVector (array_1d< double, 2 > &rMetric)
 
void GetMetricVector (array_1d< double, 3 > &rMetric)
 
void GetMetricVector (array_1d< double, 3 > &rMetric)
 
void GetMetricTensor (array_1d< double, 3 > &rMetric)
 
void GetMetricTensor (array_1d< double, 6 > &rMetric)
 
void GetMetricTensor (array_1d< double, 6 > &rMetric)
 
void GetDisplacementVector (array_1d< double, 3 > &rDisplacement)
 
void GetDisplacementVector (array_1d< double, 3 > &rDisplacement)
 
void GetDisplacementVector (array_1d< double, 3 > &rDisplacement)
 
Operations
std::string GetMmgVersion ()
 This method retrieves the current Mmg version. More...
 
void SetEchoLevel (const SizeType EchoLevel)
 This method sets the echo level. More...
 
SizeType GetEchoLevel ()
 This method gets the echo level. More...
 
void SetDiscretization (const DiscretizationOption Discretization)
 This method sets the discretization method. More...
 
DiscretizationOption GetDiscretization ()
 This method gets the discretization method. More...
 
void SetRemoveRegions (const bool RemoveRegions)
 This method sets if the regions must be removed. More...
 
bool GetRemoveRegions ()
 This method gets if the regions must be removed. More...
 
void PrintAndGetMmgMeshInfo (MMGMeshInfo< TMMGLibrary > &rMMGMeshInfo)
 It prints info about the current mesh. More...
 
virtual IndexVectorType FindDuplicateNodeIds (const ModelPart &rModelPart)
 Returns a vector of ids of spatially repeated nodes. More...
 
virtual IndexVectorType CheckFirstTypeConditions ()
 Returns a vector of ids of repeated conditions. More...
 
virtual IndexVectorType CheckSecondTypeConditions ()
 Returns a vector of ids of repeated conditions. More...
 
virtual IndexVectorType CheckFirstTypeElements ()
 Returns a vector of ids of repeated elements. More...
 
virtual IndexVectorType CheckSecondTypeElements ()
 Returns a vector of ids of repeated elements. More...
 
virtual void BlockNode (const IndexType iNode)
 It blocks certain nodes before remesh the model. More...
 
virtual void BlockCondition (const IndexType iCondition)
 It blocks certain conditions before remesh the model. More...
 
virtual void BlockElement (const IndexType iElement)
 It blocks certain elements before remesh the model. More...
 
virtual NodeType::Pointer CreateNode (ModelPart &rModelPart, IndexType iNode, int &Ref, int &IsRequired)
 It creates the new node. More...
 
virtual Condition::Pointer CreateFirstTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 It creates the new condition (first type, depends if the library work in 2D/3D/Surfaces) More...
 
Condition::Pointer CreateSecondTypeCondition (ModelPart &rModelPart, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, const IndexType CondId, int &Ref, int &IsRequired, bool SkipCreation)
 It creates the new condition (second type, depends if the library work in 2D/3D/Surfaces) More...
 
virtual Element::Pointer CreateFirstTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 It creates the new element (first type, depends if the library work in 2D/3D/Surfaces) More...
 
Element::Pointer CreateSecondTypeElement (ModelPart &rModelPart, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement, const IndexType ElemId, int &Ref, int &IsRequired, bool SkipCreation)
 It creates the new element (second type, depends if the library work in 2D/3D/Surfaces) More...
 
virtual void InitMesh ()
 Initialisation of mesh and sol structures. More...
 
virtual void InitVerbosity ()
 Here the verbosity is set. More...
 
virtual void InitVerbosityParameter (const IndexType VerbosityMMG)
 Here the verbosity is set using the API. More...
 
virtual void SetMeshOptimizationModeParameter (const bool EnableMeshOptimization)
 This sets the optimization mode using the API where edge lengths are preserved, ignoring the metric values. More...
 
void SetMeshSize (MMGMeshInfo< TMMGLibrary > &rMMGMeshInfo)
 This sets the size of the mesh. More...
 
virtual void SetSolSizeScalar (const SizeType NumNodes)
 This sets the size of the solution for the scalar case. More...
 
virtual void SetSolSizeVector (const SizeType NumNodes)
 This sets the size of the solution for the vector case. More...
 
virtual void SetSolSizeTensor (const SizeType NumNodes)
 This sets the size of the solution for the tensor case. More...
 
virtual void SetDispSizeVector (const SizeType NumNodes)
 This sets the size of the displacement for lagrangian movement. More...
 
virtual void CheckMeshData ()
 This checks the mesh data and prints if it is OK. More...
 
virtual void InputMesh (const std::string &rInputName)
 This sets the output mesh. More...
 
virtual void InputSol (const std::string &rInputName)
 This sets the output sol. More...
 
virtual void OutputMesh (const std::string &rOutputName)
 This sets the output mesh. More...
 
virtual void OutputSol (const std::string &rOutputName)
 This sets the output sol. More...
 
virtual void OutputDisplacement (const std::string &rOutputName)
 This sets the output displacement. More...
 
virtual void OutputReferenceEntitities (const std::string &rOutputName, const std::unordered_map< IndexType, Condition::Pointer > &rRefCondition, const std::unordered_map< IndexType, Element::Pointer > &rRefElement)
 This method generates the maps of reference for conditions and elements from an existing json. More...
 
virtual void FreeAll ()
 This frees the MMG structures. More...
 
void MMGLibCallMetric (Parameters ConfigurationParameters)
 This loads the solution. More...
 
void MMGLibCallIsoSurface (Parameters ConfigurationParameters)
 This loads the solution. More...
 
virtual void SetNodes (const double X, const double Y, const double Z, const IndexType Color, const IndexType Index)
 This sets the nodes of the mesh. More...
 
virtual void SetConditions (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 This sets the conditions of the mesh. More...
 
virtual void SetElements (GeometryType &rGeometry, const IndexType Color, const IndexType Index)
 This sets elements of the mesh. More...
 
virtual void SetMetricScalar (const double Metric, const IndexType NodeId)
 This function is used to set the metric scalar. More...
 
virtual void SetMetricVector (const array_1d< double, Dimension > &rMetric, const IndexType NodeId)
 This function is used to set the metric vector (x, y, z) More...
 
virtual void SetMetricTensor (const TensorArrayType &rMetric, const IndexType NodeId)
 This function is used to set the Hessian metric tensor, note that when using the Hessian, more than one metric can be defined simultaneously, so in consecuence we need to define the elipsoid which defines the volume of maximal intersection. More...
 
virtual void SetDisplacementVector (const array_1d< double, 3 > &rDisplacement, const IndexType NodeId)
 This function is used to set the displacement vector (x, y, z) More...
 
virtual void GetMetricScalar (double &rMetric)
 This function is used to retrieve the metric scalar. More...
 
virtual void GetMetricVector (array_1d< double, Dimension > &rMetric)
 This function is used to retrieve the metric vector (x, y, z) More...
 
virtual void GetMetricTensor (TensorArrayType &rMetric)
 This function is used to retrieve the Hessian metric tensor, note that when using the Hessian, more than one metric can be defined simultaneously, so in consecuence we need to define the elipsoid which defines the volume of maximal intersection. More...
 
virtual void GetDisplacementVector (array_1d< double, 3 > &rDisplacement)
 This function is used to retrieve the displacement vector (x, y, z) More...
 
void ReorderAllIds (ModelPart &rModelPart)
 This function reorder the nodes, conditions and elements to avoid problems with non-consecutive ids. More...
 
virtual void GenerateMeshDataFromModelPart (ModelPart &rModelPart, std::unordered_map< IndexType, std::vector< std::string >> &rColors, ColorsMapType &rColorMapCondition, ColorsMapType &rColorMapElement, const FrameworkEulerLagrange Framework=FrameworkEulerLagrange::EULERIAN, const bool CollapsePrismElements=false)
 This method generates mesh data from an existing model part. More...
 
virtual void GenerateReferenceMaps (ModelPart &rModelPart, const ColorsMapType &rColorMapCondition, const ColorsMapType &rColorMapElement, std::unordered_map< IndexType, Condition::Pointer > &rRefCondition, std::unordered_map< IndexType, Element::Pointer > &rRefElement)
 This method generates the maps of reference for conditions and elements. More...
 
virtual void GenerateSolDataFromModelPart (ModelPart &rModelPart)
 This method generates solution (metric) data from an existing model part. More...
 
virtual void GenerateIsosurfaceMetricDataFromModelPart (ModelPart &rModelPart)
 This method generates solution (metric) data from an existing model part for the isosurface algorithm. More...
 
virtual void GenerateDisplacementDataFromModelPart (ModelPart &rModelPart)
 This method generates displacement data from an existing model part. More...
 
void WriteMeshDataToModelPart (ModelPart &rModelPart, const std::unordered_map< IndexType, std::vector< std::string >> &rColors, const NodeType::DofsContainerType &rDofs, const MMGMeshInfo< TMMGLibrary > &rMMGMeshInfo, std::unordered_map< IndexType, Condition::Pointer > &rMapPointersRefCondition, std::unordered_map< IndexType, Element::Pointer > &rMapPointersRefElement)
 This method writes mesh data to an existing model part. More...
 
void WriteSolDataToModelPart (ModelPart &rModelPart)
 This method writes sol data to an existing model part. More...
 
virtual void WriteReferenceEntitities (ModelPart &rModelPart, const std::string &rFilename, std::unordered_map< IndexType, Condition::Pointer > &rRefCondition, std::unordered_map< IndexType, Element::Pointer > &rRefElement)
 This method writes the maps of reference for conditions and elements from an existing json. More...
 
virtual void CreateAuxiliarSubModelPartForFlags (ModelPart &rModelPart)
 This function generates a list of submodelparts to be able to reassign flags after remesh. More...
 
virtual void AssignAndClearAuxiliarSubModelPartForFlags (ModelPart &rModelPart)
 This function assigns the flags and clears the auxiliar sub model part for flags. More...
 
void SetNumberOfLocalParameters (IndexType NumberOfLocalParameter)
 Sets the number of parameters to be defined locally at each reference color. Required by the library. More...
 
void SetLocalParameter (IndexType rColor, double HMin, double HMax, double HausdorffValue)
 Sets the local hmin, hmax and hausdorff value for all entities with the given color reference. More...
 
Input and output
std::string Info () const
 Turn back information as a string. More...
 
void PrintInfo (std::ostream &rOStream) const
 Print information about this object. More...
 
void PrintData (std::ostream &rOStream) const
 Print object's data. More...
 

Type Definitions

typedef Node NodeType
 Node definition. More...
 
typedef Geometry< NodeTypeGeometryType
 
typedef std::conditional< Dimension==2, array_1d< double, 3 >, array_1d< double, 6 > >::type TensorArrayType
 The type of array considered for the tensor. More...
 
typedef std::vector< doubleDoubleVectorType
 Double vector. More...
 
typedef std::unordered_map< DoubleVectorType, IndexType, KeyHasherRange< DoubleVectorType >, KeyComparorRange< DoubleVectorType > > DoubleVectorMapType
 Double vector map. More...
 
typedef std::unordered_map< IndexVectorType, IndexType, KeyHasherRange< IndexVectorType >, KeyComparorRange< IndexVectorType > > IndexVectorMapType
 Index vector map. More...
 
typedef std::unordered_map< IndexType, IndexTypeColorsMapType
 Colors map. More...
 
typedef std::pair< IndexType, IndexTypeIndexPairType
 Index pair. More...
 
typedef std::pair< IndexType, std::vector< std::string > > IndexStringVectorPairType
 Index and string vector pair. More...
 
static constexpr SizeType Dimension = (TMMGLibrary == MMGLibrary::MMG2D) ? 2 : 3
 Spatial dimension. More...
 
static constexpr double ZeroTolerance = std::numeric_limits<double>::epsilon()
 Definition of the zero tolerance. More...
 
 KRATOS_CLASS_POINTER_DEFINITION (MmgUtilities)
 Pointer definition of MmgUtilities. More...
 

Detailed Description

template<MMGLibrary TMMGLibrary>
class Kratos::MmgUtilities< TMMGLibrary >

Provides the Kratos interface to the MMG library API.

Author
Vicente Mataix Ferrandiz

Member Typedef Documentation

◆ ColorsMapType

template<MMGLibrary TMMGLibrary>
typedef std::unordered_map<IndexType,IndexType> Kratos::MmgUtilities< TMMGLibrary >::ColorsMapType

Colors map.

◆ DoubleVectorMapType

template<MMGLibrary TMMGLibrary>
typedef std::unordered_map<DoubleVectorType, IndexType, KeyHasherRange<DoubleVectorType>, KeyComparorRange<DoubleVectorType> > Kratos::MmgUtilities< TMMGLibrary >::DoubleVectorMapType

Double vector map.

◆ DoubleVectorType

template<MMGLibrary TMMGLibrary>
typedef std::vector<double> Kratos::MmgUtilities< TMMGLibrary >::DoubleVectorType

Double vector.

◆ GeometryType

template<MMGLibrary TMMGLibrary>
typedef Geometry<NodeType> Kratos::MmgUtilities< TMMGLibrary >::GeometryType

◆ IndexPairType

template<MMGLibrary TMMGLibrary>
typedef std::pair<IndexType,IndexType> Kratos::MmgUtilities< TMMGLibrary >::IndexPairType

Index pair.

◆ IndexStringVectorPairType

template<MMGLibrary TMMGLibrary>
typedef std::pair<IndexType, std::vector<std::string> > Kratos::MmgUtilities< TMMGLibrary >::IndexStringVectorPairType

Index and string vector pair.

◆ IndexVectorMapType

template<MMGLibrary TMMGLibrary>
typedef std::unordered_map<IndexVectorType, IndexType, KeyHasherRange<IndexVectorType>, KeyComparorRange<IndexVectorType> > Kratos::MmgUtilities< TMMGLibrary >::IndexVectorMapType

Index vector map.

◆ NodeType

template<MMGLibrary TMMGLibrary>
typedef Node Kratos::MmgUtilities< TMMGLibrary >::NodeType

Node definition.

◆ TensorArrayType

template<MMGLibrary TMMGLibrary>
typedef std::conditional<Dimension == 2, array_1d<double, 3>, array_1d<double, 6> >::type Kratos::MmgUtilities< TMMGLibrary >::TensorArrayType

The type of array considered for the tensor.

Member Function Documentation

◆ AssignAndClearAuxiliarSubModelPartForFlags()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::AssignAndClearAuxiliarSubModelPartForFlags ( ModelPart rModelPart)
virtual

This function assigns the flags and clears the auxiliar sub model part for flags.

Parameters
[in,out]rModelPartThe model part of interest to study

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ BlockCondition() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::BlockCondition ( const IndexType  iCondition)

◆ BlockCondition() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::BlockCondition ( const IndexType  iCondition)

◆ BlockCondition() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::BlockCondition ( const IndexType  iCondition)

◆ BlockCondition() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::BlockCondition ( const IndexType  iCondition)
virtual

It blocks certain conditions before remesh the model.

Parameters
[in]iConditionThe index of the condition

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ BlockElement() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::BlockElement ( const IndexType  iElement)

◆ BlockElement() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::BlockElement ( const IndexType  iElement)

◆ BlockElement() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::BlockElement ( const IndexType  iElement)

◆ BlockElement() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::BlockElement ( const IndexType  iElement)
virtual

It blocks certain elements before remesh the model.

Parameters
[in]iElementThe index of the element

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ BlockNode() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::BlockNode ( const IndexType  iNode)

◆ BlockNode() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::BlockNode ( const IndexType  iNode)

◆ BlockNode() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::BlockNode ( const IndexType  iNode)

◆ BlockNode() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::BlockNode ( const IndexType  iNode)
virtual

It blocks certain nodes before remesh the model.

Parameters
[in]iNodeThe index of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CheckFirstTypeConditions() [1/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG2D >::CheckFirstTypeConditions ( )

◆ CheckFirstTypeConditions() [2/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG3D >::CheckFirstTypeConditions ( )

◆ CheckFirstTypeConditions() [3/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMGS >::CheckFirstTypeConditions ( )

◆ CheckFirstTypeConditions() [4/4]

template<MMGLibrary TMMGLibrary>
virtual IndexVectorType Kratos::MmgUtilities< TMMGLibrary >::CheckFirstTypeConditions ( )
virtual

Returns a vector of ids of repeated conditions.

For 2D and surface meshes it returns the ids of repeated edges found in the MMG mesh data structure. In 3D it returns ids of triangles.

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CheckFirstTypeElements() [1/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG2D >::CheckFirstTypeElements ( )

◆ CheckFirstTypeElements() [2/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG3D >::CheckFirstTypeElements ( )

◆ CheckFirstTypeElements() [3/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMGS >::CheckFirstTypeElements ( )

◆ CheckFirstTypeElements() [4/4]

template<MMGLibrary TMMGLibrary>
virtual IndexVectorType Kratos::MmgUtilities< TMMGLibrary >::CheckFirstTypeElements ( )
virtual

Returns a vector of ids of repeated elements.

For 2D and surface meshes it returns the ids of repeated triangles found in the MMG mesh data structure. In 3D it returns ids of tetrahedra.

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CheckMeshData() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::CheckMeshData ( )

◆ CheckMeshData() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::CheckMeshData ( )

◆ CheckMeshData() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::CheckMeshData ( )

◆ CheckMeshData() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::CheckMeshData ( )
virtual

This checks the mesh data and prints if it is OK.

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CheckSecondTypeConditions() [1/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG2D >::CheckSecondTypeConditions ( )

◆ CheckSecondTypeConditions() [2/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG3D >::CheckSecondTypeConditions ( )

◆ CheckSecondTypeConditions() [3/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMGS >::CheckSecondTypeConditions ( )

◆ CheckSecondTypeConditions() [4/4]

template<MMGLibrary TMMGLibrary>
virtual IndexVectorType Kratos::MmgUtilities< TMMGLibrary >::CheckSecondTypeConditions ( )
virtual

Returns a vector of ids of repeated conditions.

For 3D meshes it returns the ids of repeated quadrilaterals found in the MMG mesh data structure. Otherwise, it returns an empty vector.

◆ CheckSecondTypeElements() [1/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG2D >::CheckSecondTypeElements ( )

◆ CheckSecondTypeElements() [2/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMG3D >::CheckSecondTypeElements ( )

◆ CheckSecondTypeElements() [3/4]

IndexVectorType Kratos::MmgUtilities< MMGLibrary::MMGS >::CheckSecondTypeElements ( )

◆ CheckSecondTypeElements() [4/4]

template<MMGLibrary TMMGLibrary>
virtual IndexVectorType Kratos::MmgUtilities< TMMGLibrary >::CheckSecondTypeElements ( )
virtual

Returns a vector of ids of repeated elements.

For 3D meshes it returns the ids of repeated prisms found in the MMG mesh data structure. Otherwise, it returns an empty vector.

◆ CreateAuxiliarSubModelPartForFlags()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::CreateAuxiliarSubModelPartForFlags ( ModelPart rModelPart)
virtual

This function generates a list of submodelparts to be able to reassign flags after remesh.

Parameters
[in,out]rModelPartThe model part of interest to study

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CreateFirstTypeCondition() [1/4]

Condition::Pointer Kratos::MmgUtilities< MMGLibrary::MMG2D >::CreateFirstTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateFirstTypeCondition() [2/4]

Condition::Pointer Kratos::MmgUtilities< MMGLibrary::MMG3D >::CreateFirstTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateFirstTypeCondition() [3/4]

Condition::Pointer Kratos::MmgUtilities< MMGLibrary::MMGS >::CreateFirstTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateFirstTypeCondition() [4/4]

template<MMGLibrary TMMGLibrary>
virtual Condition::Pointer Kratos::MmgUtilities< TMMGLibrary >::CreateFirstTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)
virtual

It creates the new condition (first type, depends if the library work in 2D/3D/Surfaces)

Each call to this function increments the internal counter of the MMG mesh data structure and extracts the vertices of the current edge.

Parameters
[in,out]rModelPartThe model part of interest to study
[in,out]rMapPointersRefConditionThe pointer to the condition of reference
[in]CondIdThe id of the new condition
[out]RefMMG edge reference
[out]IsRequiredMMG required entity (0 or 1)
[in]SkipCreationSkips the creation of the new condition
Returns
pCondition The pointer to the new condition created

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CreateFirstTypeElement() [1/4]

Element::Pointer Kratos::MmgUtilities< MMGLibrary::MMG2D >::CreateFirstTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateFirstTypeElement() [2/4]

Element::Pointer Kratos::MmgUtilities< MMGLibrary::MMG3D >::CreateFirstTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateFirstTypeElement() [3/4]

Element::Pointer Kratos::MmgUtilities< MMGLibrary::MMGS >::CreateFirstTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateFirstTypeElement() [4/4]

template<MMGLibrary TMMGLibrary>
virtual Element::Pointer Kratos::MmgUtilities< TMMGLibrary >::CreateFirstTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)
virtual

It creates the new element (first type, depends if the library work in 2D/3D/Surfaces)

Parameters
[in,out]rModelPartThe model part of interest to study
[in,out]rMapPointersRefElementThe pointer to the element of reference
[in]ElemIdThe id of the element
[out]RefMMG edge reference
[out]IsRequiredMMG required entity (0 or 1)
Returns
pElement The pointer to the new condition created

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CreateNode() [1/4]

Node::Pointer Kratos::MmgUtilities< MMGLibrary::MMG2D >::CreateNode ( ModelPart rModelPart,
const IndexType  iNode,
int Ref,
int IsRequired 
)

◆ CreateNode() [2/4]

Node::Pointer Kratos::MmgUtilities< MMGLibrary::MMG3D >::CreateNode ( ModelPart rModelPart,
const IndexType  iNode,
int Ref,
int IsRequired 
)

◆ CreateNode() [3/4]

Node::Pointer Kratos::MmgUtilities< MMGLibrary::MMGS >::CreateNode ( ModelPart rModelPart,
const IndexType  iNode,
int Ref,
int IsRequired 
)

◆ CreateNode() [4/4]

template<MMGLibrary TMMGLibrary>
virtual NodeType::Pointer Kratos::MmgUtilities< TMMGLibrary >::CreateNode ( ModelPart rModelPart,
IndexType  iNode,
int Ref,
int IsRequired 
)
virtual

It creates the new node.

Each call to this function increments the internal counter of the MMG mesh data structure, extracts the coordinates of the current vertex and creates the new node with the extracted coordinates.

Parameters
[in,out]rModelPartThe model part which owns the new node
[in]iNodeThe index of the new node
[out]RefMMG point reference
[out]IsRequiredMMG required entity (0 or 1)
Returns
pNode The pointer to the new node created

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ CreateSecondTypeCondition() [1/4]

Condition::Pointer Kratos::MmgUtilities< MMGLibrary::MMG2D >::CreateSecondTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateSecondTypeCondition() [2/4]

Condition::Pointer Kratos::MmgUtilities< MMGLibrary::MMG3D >::CreateSecondTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateSecondTypeCondition() [3/4]

Condition::Pointer Kratos::MmgUtilities< MMGLibrary::MMGS >::CreateSecondTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateSecondTypeCondition() [4/4]

template<MMGLibrary TMMGLibrary>
Condition::Pointer Kratos::MmgUtilities< TMMGLibrary >::CreateSecondTypeCondition ( ModelPart rModelPart,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
const IndexType  CondId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

It creates the new condition (second type, depends if the library work in 2D/3D/Surfaces)

Parameters
[in,out]rModelPartThe model part of interest to study
[in,out]rMapPointersRefConditionThe pointer to the condition of reference
[in]CondIdThe id of the condition
[out]RefMMG edge reference
[out]IsRequiredMMG required entity (0 or 1)
Returns
pCondition The pointer to the new condition created

◆ CreateSecondTypeElement() [1/4]

Element::Pointer Kratos::MmgUtilities< MMGLibrary::MMG2D >::CreateSecondTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateSecondTypeElement() [2/4]

Element::Pointer Kratos::MmgUtilities< MMGLibrary::MMG3D >::CreateSecondTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateSecondTypeElement() [3/4]

Element::Pointer Kratos::MmgUtilities< MMGLibrary::MMGS >::CreateSecondTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

◆ CreateSecondTypeElement() [4/4]

template<MMGLibrary TMMGLibrary>
Element::Pointer Kratos::MmgUtilities< TMMGLibrary >::CreateSecondTypeElement ( ModelPart rModelPart,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement,
const IndexType  ElemId,
int Ref,
int IsRequired,
bool  SkipCreation 
)

It creates the new element (second type, depends if the library work in 2D/3D/Surfaces)

Parameters
[in,out]rModelPartThe model part of interest to study
[in,out]rMapPointersRefElementThe pointer to the element of reference
[in]ElemIdThe id of the element
[out]RefMMG edge reference
[out]IsRequiredMMG required entity (0 or 1)
Returns
pElement The pointer to the new condition created

◆ FindDuplicateNodeIds()

template<MMGLibrary TMMGLibrary>
IndexVectorType Kratos::MmgUtilities< TMMGLibrary >::FindDuplicateNodeIds ( const ModelPart rModelPart)
virtual

Returns a vector of ids of spatially repeated nodes.

Parameters
[in,out]rModelPartThe model part whose nodes are checked

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ FreeAll() [1/4]

◆ FreeAll() [2/4]

◆ FreeAll() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::FreeAll ( )

◆ FreeAll() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::FreeAll ( )
virtual

This frees the MMG structures.

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GenerateDisplacementDataFromModelPart()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::GenerateDisplacementDataFromModelPart ( ModelPart rModelPart)
virtual

This method generates displacement data from an existing model part.

Parameters
[in,out]rModelPartThe model part of interest to study

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GenerateIsosurfaceMetricDataFromModelPart()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::GenerateIsosurfaceMetricDataFromModelPart ( ModelPart rModelPart)
virtual

This method generates solution (metric) data from an existing model part for the isosurface algorithm.

Parameters
[in,out]rModelPartThe model part of interest to study

◆ GenerateMeshDataFromModelPart()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::GenerateMeshDataFromModelPart ( ModelPart rModelPart,
std::unordered_map< IndexType, std::vector< std::string >> &  rColors,
ColorsMapType rColorMapCondition,
ColorsMapType rColorMapElement,
const FrameworkEulerLagrange  Framework = FrameworkEulerLagrange::EULERIAN,
const bool  CollapsePrismElements = false 
)
virtual

This method generates mesh data from an existing model part.

Parameters
[in,out]rModelPartThe model part of interest to study
[in,out]rColorsWhere the sub model parts IDs are stored
[in,out]rColorMapConditionAuxiliar color map for conditions
[in,out]rColorMapElementAuxiliar color map for elements
[in]FrameworkThe framework considered
[in]CollapsePrismElementsIf the prisms elements are going to be collapsed

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GenerateReferenceMaps()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::GenerateReferenceMaps ( ModelPart rModelPart,
const ColorsMapType rColorMapCondition,
const ColorsMapType rColorMapElement,
std::unordered_map< IndexType, Condition::Pointer > &  rRefCondition,
std::unordered_map< IndexType, Element::Pointer > &  rRefElement 
)
virtual

This method generates the maps of reference for conditions and elements.

Parameters
[in]rModelPartThe model part of interest to study
[in]rColorMapConditionAuxiliar color map for conditions
[in]rColorMapElementAuxiliar color map for elements
[in,out]rRefConditionThe conditions of reference
[in,out]rRefElementThe elements of reference

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GenerateSolDataFromModelPart()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::GenerateSolDataFromModelPart ( ModelPart rModelPart)
virtual

This method generates solution (metric) data from an existing model part.

Parameters
[in,out]rModelPartThe model part of interest to study

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GetDiscretization()

template<MMGLibrary TMMGLibrary>
DiscretizationOption Kratos::MmgUtilities< TMMGLibrary >::GetDiscretization

This method gets the discretization method.

Returns
mDiscretization Gets the discretization method

◆ GetDisplacementVector() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::GetDisplacementVector ( array_1d< double, 3 > &  rDisplacement)

◆ GetDisplacementVector() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::GetDisplacementVector ( array_1d< double, 3 > &  rDisplacement)

◆ GetDisplacementVector() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::GetDisplacementVector ( array_1d< double, 3 > &  rDisplacement)

◆ GetDisplacementVector() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::GetDisplacementVector ( array_1d< double, 3 > &  rDisplacement)
virtual

This function is used to retrieve the displacement vector (x, y, z)

Parameters
[in,out]rDisplacementThis array contains the components of the displacement vector

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GetEchoLevel()

template<MMGLibrary TMMGLibrary>
SizeType Kratos::MmgUtilities< TMMGLibrary >::GetEchoLevel

This method gets the echo level.

Returns
mEchoLevel Gets the echo level

◆ GetMetricScalar() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::GetMetricScalar ( double rMetric)

◆ GetMetricScalar() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::GetMetricScalar ( double rMetric)

◆ GetMetricScalar() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::GetMetricScalar ( double rMetric)

◆ GetMetricScalar() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::GetMetricScalar ( double rMetric)
virtual

This function is used to retrieve the metric scalar.

Parameters
[in,out]rMetricThe inverse of the size node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GetMetricTensor() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::GetMetricTensor ( array_1d< double, 3 > &  rMetric)

◆ GetMetricTensor() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::GetMetricTensor ( array_1d< double, 6 > &  rMetric)

◆ GetMetricTensor() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::GetMetricTensor ( array_1d< double, 6 > &  rMetric)

◆ GetMetricTensor() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::GetMetricTensor ( TensorArrayType rMetric)
virtual

This function is used to retrieve the Hessian metric tensor, note that when using the Hessian, more than one metric can be defined simultaneously, so in consecuence we need to define the elipsoid which defines the volume of maximal intersection.

Parameters
[in,out]rMetricThis array contains the components of the metric tensor in the MMG defined order

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GetMetricVector() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::GetMetricVector ( array_1d< double, 2 > &  rMetric)

◆ GetMetricVector() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::GetMetricVector ( array_1d< double, 3 > &  rMetric)

◆ GetMetricVector() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::GetMetricVector ( array_1d< double, 3 > &  rMetric)

◆ GetMetricVector() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::GetMetricVector ( array_1d< double, Dimension > &  rMetric)
virtual

This function is used to retrieve the metric vector (x, y, z)

Parameters
[in,out]rMetricThis array contains the components of the metric vector

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ GetMmgVersion()

template<MMGLibrary TMMGLibrary>
std::string Kratos::MmgUtilities< TMMGLibrary >::GetMmgVersion

This method retrieves the current Mmg version.

The displacement variable for MMG.

Returns
The current version of Mmg (as a string)

◆ GetRemoveRegions()

template<MMGLibrary TMMGLibrary>
bool Kratos::MmgUtilities< TMMGLibrary >::GetRemoveRegions

This method gets if the regions must be removed.

Returns
mRemoveRegions Gets if the regions must be removed

◆ Info()

template<MMGLibrary TMMGLibrary>
std::string Kratos::MmgUtilities< TMMGLibrary >::Info ( ) const
inline

Turn back information as a string.

◆ InitMesh() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::InitMesh ( )

◆ InitMesh() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::InitMesh ( )

◆ InitMesh() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::InitMesh ( )

◆ InitMesh() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::InitMesh ( )
virtual

Initialisation of mesh and sol structures.

Initialisation of mesh and sol structures args of InitMesh:

  1. MMG5_ARG_start we start to give the args of a variadic func
  2. MMG5_ARG_ppMesh next arg will be a pointer over a MMG5_pMesh
  3. &mmgMesh pointer toward your MMG5_pMesh (that store your mesh)
  4. MMG5_ARG_ppMet next arg will be a pointer over a MMG5_pSol storing a metric
  5. &mmgSol pointer toward your MMG5_pSol (that store your metric)

◆ InitVerbosity()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::InitVerbosity
virtual

Here the verbosity is set.

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ InitVerbosityParameter() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::InitVerbosityParameter ( const IndexType  VerbosityMMG)

◆ InitVerbosityParameter() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::InitVerbosityParameter ( const IndexType  VerbosityMMG)

◆ InitVerbosityParameter() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::InitVerbosityParameter ( const IndexType  VerbosityMMG)

◆ InitVerbosityParameter() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::InitVerbosityParameter ( const IndexType  VerbosityMMG)
virtual

Here the verbosity is set using the API.

Parameters
[in]VerbosityMMGThe equivalent verbosity level in the MMG API

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ InputMesh() [1/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::InputMesh ( const std::string &  rInputName)
virtual

This sets the output mesh.

Parameters
[in]rInputNameThe input name

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ InputMesh() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::InputMesh ( const std::string &  rOutputName)

◆ InputMesh() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::InputMesh ( const std::string &  rOutputName)

◆ InputMesh() [4/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::InputMesh ( const std::string &  rOutputName)

◆ InputSol() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::InputSol ( const std::string &  rInputName)

◆ InputSol() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::InputSol ( const std::string &  rInputName)

◆ InputSol() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::InputSol ( const std::string &  rInputName)

◆ InputSol() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::InputSol ( const std::string &  rInputName)
virtual

This sets the output sol.

Parameters
[in]rInputNameThe input name

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ KRATOS_CLASS_POINTER_DEFINITION()

template<MMGLibrary TMMGLibrary>
Kratos::MmgUtilities< TMMGLibrary >::KRATOS_CLASS_POINTER_DEFINITION ( MmgUtilities< TMMGLibrary >  )

Pointer definition of MmgUtilities.

◆ MMGLibCallIsoSurface() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::MMGLibCallIsoSurface ( Parameters  ConfigurationParameters)

----------------— Level set discretization option ------------------—

(Not mandatory): check if the number of given entities match with mesh size

----------------— Level set discretization ------------------------—

◆ MMGLibCallIsoSurface() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::MMGLibCallIsoSurface ( Parameters  ConfigurationParameters)

----------------— Level set discretization option ------------------—

(Not mandatory): check if the number of given entities match with mesh size

----------------— Including surface options ------------------------—

----------------— level set discretization ------------------------—

◆ MMGLibCallIsoSurface() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::MMGLibCallIsoSurface ( Parameters  ConfigurationParameters)

----------------— Level set discretization option ------------------—

(Not mandatory): check if the number of given entities match with mesh size

----------------— level set discretization ------------------------—

◆ MMGLibCallIsoSurface() [4/4]

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::MMGLibCallIsoSurface ( Parameters  ConfigurationParameters)

This loads the solution.

◆ MMGLibCallMetric() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::MMGLibCallMetric ( Parameters  ConfigurationParameters)

◆ MMGLibCallMetric() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::MMGLibCallMetric ( Parameters  ConfigurationParameters)

◆ MMGLibCallMetric() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::MMGLibCallMetric ( Parameters  ConfigurationParameters)

◆ MMGLibCallMetric() [4/4]

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::MMGLibCallMetric ( Parameters  ConfigurationParameters)

This loads the solution.

◆ OutputDisplacement() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::OutputDisplacement ( const std::string &  rOutputName)

◆ OutputDisplacement() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::OutputDisplacement ( const std::string &  rOutputName)

◆ OutputDisplacement() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::OutputDisplacement ( const std::string &  rOutputName)

◆ OutputDisplacement() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::OutputDisplacement ( const std::string &  rOutputName)
virtual

This sets the output displacement.

Parameters
[in]rOutputNameThe output name

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ OutputMesh() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::OutputMesh ( const std::string &  rOutputName)

◆ OutputMesh() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::OutputMesh ( const std::string &  rOutputName)

◆ OutputMesh() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::OutputMesh ( const std::string &  rOutputName)

◆ OutputMesh() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::OutputMesh ( const std::string &  rOutputName)
virtual

This sets the output mesh.

Parameters
[in]rOutputNameThe output name

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ OutputReferenceEntitities()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::OutputReferenceEntitities ( const std::string &  rOutputName,
const std::unordered_map< IndexType, Condition::Pointer > &  rRefCondition,
const std::unordered_map< IndexType, Element::Pointer > &  rRefElement 
)
virtual

This method generates the maps of reference for conditions and elements from an existing json.

Parameters
[in]rOutputNameThe name of the files
[in]rRefConditionThe conditions of reference
[in]rRefElementThe elements of reference

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ OutputSol() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::OutputSol ( const std::string &  rOutputName)

◆ OutputSol() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::OutputSol ( const std::string &  rOutputName)

◆ OutputSol() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::OutputSol ( const std::string &  rOutputName)

◆ OutputSol() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::OutputSol ( const std::string &  rOutputName)
virtual

This sets the output sol.

Parameters
[in]rOutputNameThe output name

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ PrintAndGetMmgMeshInfo()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::PrintAndGetMmgMeshInfo ( MMGMeshInfo< TMMGLibrary > &  rMMGMeshInfo)

It prints info about the current mesh.

Parameters
[in,out]rMMGMeshInfoThe number of nodes, conditions and elements

◆ PrintData()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::PrintData ( std::ostream &  rOStream) const
inline

Print object's data.

◆ PrintInfo()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::PrintInfo ( std::ostream &  rOStream) const
inline

Print information about this object.

◆ ReorderAllIds()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::ReorderAllIds ( ModelPart rModelPart)

This function reorder the nodes, conditions and elements to avoid problems with non-consecutive ids.

Parameters
[in,out]rModelPartThe model part of interest to study

◆ SetConditions() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetConditions ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)

◆ SetConditions() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetConditions ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)

◆ SetConditions() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetConditions ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)

◆ SetConditions() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetConditions ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)
virtual

This sets the conditions of the mesh.

Parameters
[in,out]rGeometryThe geometry of the condition
[in]ColorReference of the node(submodelpart)
[in]IndexThe index number of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetDiscretization()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::SetDiscretization ( const DiscretizationOption  Discretization)

This method sets the discretization method.

Parameters
[in]DiscretizationSets the discretization method

◆ SetDisplacementVector() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetDisplacementVector ( const array_1d< double, 3 > &  rDisplacement,
const IndexType  NodeId 
)

◆ SetDisplacementVector() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetDisplacementVector ( const array_1d< double, 3 > &  rDisplacement,
const IndexType  NodeId 
)

◆ SetDisplacementVector() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetDisplacementVector ( const array_1d< double, 3 > &  rDisplacement,
const IndexType  NodeId 
)

◆ SetDisplacementVector() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetDisplacementVector ( const array_1d< double, 3 > &  rDisplacement,
const IndexType  NodeId 
)
virtual

This function is used to set the displacement vector (x, y, z)

Parameters
[in]rMetricThis array contains the components of the displacement vector
[in]NodeIdThe id of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetDispSizeVector() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetDispSizeVector ( const SizeType  NumNodes)

◆ SetDispSizeVector() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetDispSizeVector ( const SizeType  NumNodes)

◆ SetDispSizeVector() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetDispSizeVector ( const SizeType  NumNodes)

◆ SetDispSizeVector() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetDispSizeVector ( const SizeType  NumNodes)
virtual

This sets the size of the displacement for lagrangian movement.

Parameters
[in]NumNodesNumber of nodes

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetEchoLevel()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::SetEchoLevel ( const SizeType  EchoLevel)

This method sets the echo level.

Parameters
[in]EchoLevelSets the echo level

◆ SetElements() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetElements ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)

◆ SetElements() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetElements ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)

◆ SetElements() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetElements ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)

◆ SetElements() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetElements ( GeometryType rGeometry,
const IndexType  Color,
const IndexType  Index 
)
virtual

This sets elements of the mesh.

Parameters
[in,out]rGeometryThe geometry of the element
[in]ColorReference of the node(submodelpart)
[in]IndexThe index number of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetLocalParameter() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetLocalParameter ( IndexType  rColor,
double  HMin,
double  HMax,
double  HausdorffValue 
)

◆ SetLocalParameter() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetLocalParameter ( IndexType  rColor,
double  HMin,
double  HMax,
double  HausdorffValue 
)

◆ SetLocalParameter() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetLocalParameter ( IndexType  rColor,
double  HMin,
double  HMax,
double  HausdorffValue 
)

◆ SetLocalParameter() [4/4]

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::SetLocalParameter ( IndexType  rColor,
double  HMin,
double  HMax,
double  HausdorffValue 
)

Sets the local hmin, hmax and hausdorff value for all entities with the given color reference.

◆ SetMeshOptimizationModeParameter() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetMeshOptimizationModeParameter ( const bool  EnableMeshOptimization)

◆ SetMeshOptimizationModeParameter() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetMeshOptimizationModeParameter ( const bool  EnableMeshOptimization)

◆ SetMeshOptimizationModeParameter() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetMeshOptimizationModeParameter ( const bool  EnableMeshOptimization)

◆ SetMeshOptimizationModeParameter() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetMeshOptimizationModeParameter ( const bool  EnableMeshOptimization)
virtual

This sets the optimization mode using the API where edge lengths are preserved, ignoring the metric values.

Parameters
[in]EnableMeshOptimizationBoolean to set the mesh optimization mode

◆ SetMeshSize() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetMeshSize ( MMGMeshInfo< MMGLibrary::MMG2D > &  rMMGMeshInfo)

◆ SetMeshSize() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetMeshSize ( MMGMeshInfo< MMGLibrary::MMG3D > &  rMMGMeshInfo)

◆ SetMeshSize() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetMeshSize ( MMGMeshInfo< MMGLibrary::MMGS > &  rMMGMeshInfo)

◆ SetMeshSize() [4/4]

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::SetMeshSize ( MMGMeshInfo< TMMGLibrary > &  rMMGMeshInfo)

This sets the size of the mesh.

Parameters
[in,out]rMMGMeshInfoThe number of nodes, conditions and elements

◆ SetMetricScalar() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetMetricScalar ( const double  Metric,
const IndexType  NodeId 
)

◆ SetMetricScalar() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetMetricScalar ( const double  Metric,
const IndexType  NodeId 
)

◆ SetMetricScalar() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetMetricScalar ( const double  Metric,
const IndexType  NodeId 
)

◆ SetMetricScalar() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetMetricScalar ( const double  Metric,
const IndexType  NodeId 
)
virtual

This function is used to set the metric scalar.

Parameters
[in]MetricThe inverse of the size node
[in]NodeIdThe id of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetMetricTensor() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetMetricTensor ( const array_1d< double, 3 > &  rMetric,
const IndexType  NodeId 
)

◆ SetMetricTensor() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetMetricTensor ( const array_1d< double, 6 > &  rMetric,
const IndexType  NodeId 
)

◆ SetMetricTensor() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetMetricTensor ( const array_1d< double, 6 > &  rMetric,
const IndexType  NodeId 
)

◆ SetMetricTensor() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetMetricTensor ( const TensorArrayType rMetric,
const IndexType  NodeId 
)
virtual

This function is used to set the Hessian metric tensor, note that when using the Hessian, more than one metric can be defined simultaneously, so in consecuence we need to define the elipsoid which defines the volume of maximal intersection.

Parameters
[in]rMetricThis array contains the components of the metric tensor in the MMG defined order
[in]NodeIdThe id of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetMetricVector() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetMetricVector ( const array_1d< double, 2 > &  rMetric,
const IndexType  NodeId 
)

◆ SetMetricVector() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetMetricVector ( const array_1d< double, 3 > &  rMetric,
const IndexType  NodeId 
)

◆ SetMetricVector() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetMetricVector ( const array_1d< double, 3 > &  rMetric,
const IndexType  NodeId 
)

◆ SetMetricVector() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetMetricVector ( const array_1d< double, Dimension > &  rMetric,
const IndexType  NodeId 
)
virtual

This function is used to set the metric vector (x, y, z)

Parameters
[in]rMetricThis array contains the components of the metric vector
[in]NodeIdThe id of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetNodes() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetNodes ( const double  X,
const double  Y,
const double  Z,
const IndexType  Color,
const IndexType  Index 
)

◆ SetNodes() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetNodes ( const double  X,
const double  Y,
const double  Z,
const IndexType  Color,
const IndexType  Index 
)

◆ SetNodes() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetNodes ( const double  X,
const double  Y,
const double  Z,
const IndexType  Color,
const IndexType  Index 
)

◆ SetNodes() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetNodes ( const double  X,
const double  Y,
const double  Z,
const IndexType  Color,
const IndexType  Index 
)
virtual

This sets the nodes of the mesh.

Parameters
[in]XCoordinate X
[in]YCoordinate Y
[in]ZCoordinate Z
[in]ColorReference of the node(submodelpart)
[in]IndexThe index number of the node

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetNumberOfLocalParameters() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetNumberOfLocalParameters ( IndexType  NumberOfLocalParameter)

◆ SetNumberOfLocalParameters() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetNumberOfLocalParameters ( IndexType  NumberOfLocalParameter)

◆ SetNumberOfLocalParameters() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetNumberOfLocalParameters ( IndexType  NumberOfLocalParameter)

◆ SetNumberOfLocalParameters() [4/4]

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::SetNumberOfLocalParameters ( IndexType  NumberOfLocalParameter)

Sets the number of parameters to be defined locally at each reference color. Required by the library.

◆ SetRemoveRegions()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::SetRemoveRegions ( const bool  RemoveRegions)

This method sets if the regions must be removed.

Parameters
[in]RemoveRegionsSets if the regions must be removed

◆ SetSolSizeScalar() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetSolSizeScalar ( const SizeType  NumNodes)

◆ SetSolSizeScalar() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetSolSizeScalar ( const SizeType  NumNodes)

◆ SetSolSizeScalar() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetSolSizeScalar ( const SizeType  NumNodes)

◆ SetSolSizeScalar() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetSolSizeScalar ( const SizeType  NumNodes)
virtual

This sets the size of the solution for the scalar case.

Parameters
[in]NumNodesNumber of nodes

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetSolSizeTensor() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetSolSizeTensor ( const SizeType  NumNodes)

◆ SetSolSizeTensor() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetSolSizeTensor ( const SizeType  NumNodes)

◆ SetSolSizeTensor() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetSolSizeTensor ( const SizeType  NumNodes)

◆ SetSolSizeTensor() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetSolSizeTensor ( const SizeType  NumNodes)
virtual

This sets the size of the solution for the tensor case.

Parameters
[in]NumNodesNumber of nodes

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ SetSolSizeVector() [1/4]

void Kratos::MmgUtilities< MMGLibrary::MMG2D >::SetSolSizeVector ( const SizeType  NumNodes)

◆ SetSolSizeVector() [2/4]

void Kratos::MmgUtilities< MMGLibrary::MMG3D >::SetSolSizeVector ( const SizeType  NumNodes)

◆ SetSolSizeVector() [3/4]

void Kratos::MmgUtilities< MMGLibrary::MMGS >::SetSolSizeVector ( const SizeType  NumNodes)

◆ SetSolSizeVector() [4/4]

template<MMGLibrary TMMGLibrary>
virtual void Kratos::MmgUtilities< TMMGLibrary >::SetSolSizeVector ( const SizeType  NumNodes)
virtual

This sets the size of the solution for the vector case.

Parameters
[in]NumNodesNumber of nodes

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >, and Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ WriteMeshDataToModelPart()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::WriteMeshDataToModelPart ( ModelPart rModelPart,
const std::unordered_map< IndexType, std::vector< std::string >> &  rColors,
const NodeType::DofsContainerType rDofs,
const MMGMeshInfo< TMMGLibrary > &  rMMGMeshInfo,
std::unordered_map< IndexType, Condition::Pointer > &  rMapPointersRefCondition,
std::unordered_map< IndexType, Element::Pointer > &  rMapPointersRefElement 
)

This method writes mesh data to an existing model part.

Parameters
[in,out]rModelPartThe model part of interest to study
[in]rColorsWhere the sub model parts IDs are stored
[in]rDofsStorage for the dof of the node
[in]rMMGMeshInfoThe resulting mesh data
[in]rMapPointersRefConditionThe map of the conditions by reference (color)
[in]rMapPointersRefElementThe map of the elements by reference (color)

◆ WriteReferenceEntitities()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::WriteReferenceEntitities ( ModelPart rModelPart,
const std::string &  rFilename,
std::unordered_map< IndexType, Condition::Pointer > &  rRefCondition,
std::unordered_map< IndexType, Element::Pointer > &  rRefElement 
)
virtual

This method writes the maps of reference for conditions and elements from an existing json.

Parameters
[in]rModelPartThe model part of interest to study
[in]rFilenameThe name of the files
[in,out]rRefConditionThe conditions of reference
[in,out]rRefElementThe elements of reference

Reimplemented in Kratos::ParMmgUtilities< TPMMGLibrary >.

◆ WriteSolDataToModelPart()

template<MMGLibrary TMMGLibrary>
void Kratos::MmgUtilities< TMMGLibrary >::WriteSolDataToModelPart ( ModelPart rModelPart)

This method writes sol data to an existing model part.

Parameters
[in,out]rModelPartThe model part of interest to study

Member Data Documentation

◆ Dimension

template<MMGLibrary TMMGLibrary>
constexpr SizeType Kratos::MmgUtilities< TMMGLibrary >::Dimension = (TMMGLibrary == MMGLibrary::MMG2D) ? 2 : 3
staticconstexpr

Spatial dimension.

◆ ZeroTolerance

template<MMGLibrary TMMGLibrary>
constexpr double Kratos::MmgUtilities< TMMGLibrary >::ZeroTolerance = std::numeric_limits<double>::epsilon()
staticconstexpr

Definition of the zero tolerance.


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