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.
List of all members
Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace > Class Template Reference

This is the base class to define the different convergence criterion considered. More...

#include <convergence_criteria.h>

Inheritance diagram for Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >:
Collaboration diagram for Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >:

Public Member Functions

Life Cycle
 ConvergenceCriteria ()
 
 ConvergenceCriteria (Kratos::Parameters ThisParameters)
 Constructor with Parameters. More...
 
 ConvergenceCriteria (ConvergenceCriteria const &rOther)
 
virtual ~ConvergenceCriteria ()
 
Input and output
virtual std::string Info () const
 Turn back information as a string. More...
 
virtual void PrintInfo (std::ostream &rOStream) const
 Print information about this object. More...
 
virtual void PrintData (std::ostream &rOStream) const
 Print object's data. More...
 

Protected Member Functions

Protected Operations
virtual Parameters ValidateAndAssignParameters (Parameters ThisParameters, const Parameters DefaultParameters) const
 This method validate and assign default parameters. More...
 
virtual void AssignSettings (const Parameters ThisParameters)
 This method assigns settings to member variables. More...
 

Protected Attributes

Protected member Variables
bool mActualizeRHSIsNeeded = false
 
bool mConvergenceCriteriaIsInitialized = false
 This "flag" is set in order to know if it is necessary to actualize the RHS. More...
 
int mEchoLevel
 This "flag" is set in order to know if it is convergence criteria is initialized. More...
 

Type Definitions

typedef ConvergenceCriteria< TSparseSpace, TDenseSpace > ClassType
 The definition of the current class. More...
 
typedef TSparseSpace::DataType TDataType
 Data type definition. More...
 
typedef TSparseSpace::MatrixType TSystemMatrixType
 Matrix type definition. More...
 
typedef TSparseSpace::VectorType TSystemVectorType
 Vector type definition. More...
 
typedef TDenseSpace::MatrixType LocalSystemMatrixType
 Local system matrix type definition. More...
 
typedef TDenseSpace::VectorType LocalSystemVectorType
 Local system vector type definition. More...
 
typedef ModelPart::DofsArrayType DofsArrayType
 DoF array type definition. More...
 
 KRATOS_CLASS_POINTER_DEFINITION (ConvergenceCriteria)
 Pointer definition of ConvergenceCriteria. More...
 

Operations

virtual ClassType::Pointer Create (Parameters ThisParameters) const
 Create method. More...
 
virtual std::vector< TSystemVectorType > & GetRHS_Element_Components ()
 Get component wise element components. More...
 
virtual std::vector< Variable< LocalSystemVectorType > > & GetRHS_Element_Variables ()
 Get component wise element variables. More...
 
virtual std::vector< TSystemVectorType > & GetRHS_Condition_Components ()
 Get component wise condition components. More...
 
virtual std::vector< Variable< LocalSystemVectorType > > & GetRHS_Condition_Variables ()
 Get component wise condition variables. More...
 
virtual void SetEchoLevel (int Level)
 It sets the level of echo for the solving strategy. More...
 
int GetEchoLevel ()
 This returns the level of echo for the solving strategy. More...
 
void SetActualizeRHSFlag (bool ActualizeRHSIsNeeded)
 This method sets the flag mActualizeRHSIsNeeded. More...
 
bool GetActualizeRHSflag ()
 This method gets the flag mActualizeRHSIsNeeded. More...
 
virtual bool PreCriteria (ModelPart &rModelPart, DofsArrayType &rDofSet, const TSystemMatrixType &rA, const TSystemVectorType &rDx, const TSystemVectorType &rb)
 Criterias that need to be called before getting the solution. More...
 
virtual bool PostCriteria (ModelPart &rModelPart, DofsArrayType &rDofSet, const TSystemMatrixType &rA, const TSystemVectorType &rDx, const TSystemVectorType &rb)
 Criterias that need to be called after getting the solution. More...
 
virtual void Initialize (ModelPart &rModelPart)
 This function initialize the convergence criteria. More...
 
virtual bool IsInitialized ()
 This function returns if the convergence criteria is initialized. More...
 
virtual void InitializeSolutionStep (ModelPart &rModelPart, DofsArrayType &rDofSet, const TSystemMatrixType &rA, const TSystemVectorType &rDx, const TSystemVectorType &rb)
 This function initializes the solution step. More...
 
virtual void InitializeNonLinearIteration (ModelPart &rModelPart, DofsArrayType &rDofSet, const TSystemMatrixType &rA, const TSystemVectorType &rDx, const TSystemVectorType &rb)
 This function initializes the non-linear iteration. More...
 
virtual void FinalizeSolutionStep (ModelPart &rModelPart, DofsArrayType &rDofSet, const TSystemMatrixType &rA, const TSystemVectorType &rDx, const TSystemVectorType &rb)
 This function finalizes the solution step. More...
 
virtual void FinalizeNonLinearIteration (ModelPart &rModelPart, DofsArrayType &rDofSet, const TSystemMatrixType &rA, const TSystemVectorType &rDx, const TSystemVectorType &rb)
 This function finalizes the non-linear iteration. More...
 
virtual int Check (ModelPart &rModelPart)
 This function is designed to be called once to perform all the checks needed on the input provided. Checks can be "expensive" as the function is designed to catch user's errors. More...
 
virtual Parameters GetDefaultParameters () const
 This method provides the defaults parameters to avoid conflicts between the different constructors. More...
 
static std::string Name ()
 Returns the name of the class as used in the settings (snake_case format) More...
 

Detailed Description

template<class TSparseSpace, class TDenseSpace>
class Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >

This is the base class to define the different convergence criterion considered.

Template Parameters
TSparseSpaceThe sparse space considered
TDenseSpaceThe dense space considered
Author
Riccardo Rossi

Member Typedef Documentation

◆ ClassType

template<class TSparseSpace , class TDenseSpace >
typedef ConvergenceCriteria< TSparseSpace, TDenseSpace > Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::ClassType

The definition of the current class.

◆ DofsArrayType

template<class TSparseSpace , class TDenseSpace >
typedef ModelPart::DofsArrayType Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::DofsArrayType

DoF array type definition.

◆ LocalSystemMatrixType

template<class TSparseSpace , class TDenseSpace >
typedef TDenseSpace::MatrixType Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::LocalSystemMatrixType

Local system matrix type definition.

◆ LocalSystemVectorType

template<class TSparseSpace , class TDenseSpace >
typedef TDenseSpace::VectorType Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::LocalSystemVectorType

Local system vector type definition.

◆ TDataType

template<class TSparseSpace , class TDenseSpace >
typedef TSparseSpace::DataType Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::TDataType

Data type definition.

◆ TSystemMatrixType

template<class TSparseSpace , class TDenseSpace >
typedef TSparseSpace::MatrixType Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::TSystemMatrixType

Matrix type definition.

◆ TSystemVectorType

template<class TSparseSpace , class TDenseSpace >
typedef TSparseSpace::VectorType Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::TSystemVectorType

Vector type definition.

Constructor & Destructor Documentation

◆ ConvergenceCriteria() [1/3]

template<class TSparseSpace , class TDenseSpace >
Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::ConvergenceCriteria ( )
inlineexplicit

Constructor.

◆ ConvergenceCriteria() [2/3]

template<class TSparseSpace , class TDenseSpace >
Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::ConvergenceCriteria ( Kratos::Parameters  ThisParameters)
inlineexplicit

Constructor with Parameters.

Parameters
ThisParametersThe configuration parameters

◆ ConvergenceCriteria() [3/3]

template<class TSparseSpace , class TDenseSpace >
Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::ConvergenceCriteria ( ConvergenceCriteria< TSparseSpace, TDenseSpace > const &  rOther)
inlineexplicit

Copy constructor.

◆ ~ConvergenceCriteria()

template<class TSparseSpace , class TDenseSpace >
virtual Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::~ConvergenceCriteria ( )
inlinevirtual

Destructor.

Member Function Documentation

◆ AssignSettings()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::AssignSettings ( const Parameters  ThisParameters)
inlineprotectedvirtual

This method assigns settings to member variables.

Parameters
ThisParametersParameters that are assigned to the member variables

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosDisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ Check()

template<class TSparseSpace , class TDenseSpace >
virtual int Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::Check ( ModelPart rModelPart)
inlinevirtual

This function is designed to be called once to perform all the checks needed on the input provided. Checks can be "expensive" as the function is designed to catch user's errors.

Warning
Must be defined on the derived classes
Parameters
rModelPartReference to the ModelPart containing the problem.
Returns
0 all OK, 1 otherwise

Reimplemented in Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ Create()

template<class TSparseSpace , class TDenseSpace >
virtual ClassType::Pointer Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::Create ( Parameters  ThisParameters) const
inlinevirtual

Create method.

Parameters
ThisParametersThe configuration parameters

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::MixedGenericCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosDisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ FinalizeNonLinearIteration()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::FinalizeNonLinearIteration ( ModelPart rModelPart,
DofsArrayType rDofSet,
const TSystemMatrixType rA,
const TSystemVectorType rDx,
const TSystemVectorType rb 
)
inlinevirtual

This function finalizes the non-linear iteration.

Warning
Must be defined on the derived classes
Parameters
rModelPartReference to the ModelPart containing the problem.
rDofSetReference to the container of the problem's degrees of freedom (stored by the BuilderAndSolver)
rASystem matrix (unused)
rDxVector of results (variations on nodal variables)
rbRHS vector (residual + reactions)

Reimplemented in Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ FinalizeSolutionStep()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::FinalizeSolutionStep ( ModelPart rModelPart,
DofsArrayType rDofSet,
const TSystemMatrixType rA,
const TSystemVectorType rDx,
const TSystemVectorType rb 
)
inlinevirtual

This function finalizes the solution step.

Warning
Must be defined on the derived classes
Parameters
rModelPartReference to the ModelPart containing the problem.
rDofSetReference to the container of the problem's degrees of freedom (stored by the BuilderAndSolver)
rASystem matrix (unused)
rDxVector of results (variations on nodal variables)
rbRHS vector (residual + reactions)

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ GetActualizeRHSflag()

template<class TSparseSpace , class TDenseSpace >
bool Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetActualizeRHSflag ( )
inline

This method gets the flag mActualizeRHSIsNeeded.

Returns
mActualizeRHSIsNeeded: The flag that tells if actualize RHS is needed

◆ GetDefaultParameters()

template<class TSparseSpace , class TDenseSpace >
virtual Parameters Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetDefaultParameters ( ) const
inlinevirtual

This method provides the defaults parameters to avoid conflicts between the different constructors.

Returns
The default parameters

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosDisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ GetEchoLevel()

template<class TSparseSpace , class TDenseSpace >
int Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetEchoLevel ( )
inline

This returns the level of echo for the solving strategy.

The different levels of echo are:

  • 0: Mute... no echo at all
  • 1: Printing time and basic information
  • 2: Printing linear solver data
  • 3: Print of debug information: Echo of stiffness matrix, Dx, b...
    Returns
    Level of echo for the solving strategy

◆ GetRHS_Condition_Components()

template<class TSparseSpace , class TDenseSpace >
virtual std::vector<TSystemVectorType>& Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetRHS_Condition_Components ( )
inlinevirtual

Get component wise condition components.

Warning
Must be defined on the derived classes
Returns
The RHS condition components

◆ GetRHS_Condition_Variables()

template<class TSparseSpace , class TDenseSpace >
virtual std::vector< Variable< LocalSystemVectorType > >& Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetRHS_Condition_Variables ( )
inlinevirtual

Get component wise condition variables.

Warning
Must be defined on the derived classes
Returns
The RHS condition variables

◆ GetRHS_Element_Components()

template<class TSparseSpace , class TDenseSpace >
virtual std::vector<TSystemVectorType>& Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetRHS_Element_Components ( )
inlinevirtual

Get component wise element components.

Warning
Must be defined on the derived classes
Returns
The RHS element components

◆ GetRHS_Element_Variables()

template<class TSparseSpace , class TDenseSpace >
virtual std::vector< Variable< LocalSystemVectorType > >& Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::GetRHS_Element_Variables ( )
inlinevirtual

Get component wise element variables.

Warning
Must be defined on the derived classes
Returns
The RHS element variables

◆ Info()

template<class TSparseSpace , class TDenseSpace >
virtual std::string Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::Info ( ) const
inlinevirtual

Turn back information as a string.

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::MixedGenericCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosDisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ Initialize()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::Initialize ( ModelPart rModelPart)
inlinevirtual

This function initialize the convergence criteria.

Parameters
rModelPartReference to the ModelPart containing the problem. (unused)

Reimplemented in Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::ResidualDisplacementAndOtherDoFCriteria< TSparseSpace, TDenseSpace >, Kratos::ErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ InitializeNonLinearIteration()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::InitializeNonLinearIteration ( ModelPart rModelPart,
DofsArrayType rDofSet,
const TSystemMatrixType rA,
const TSystemVectorType rDx,
const TSystemVectorType rb 
)
inlinevirtual

This function initializes the non-linear iteration.

Warning
Must be defined on the derived classes
Parameters
rModelPartReference to the ModelPart containing the problem.
rDofSetReference to the container of the problem's degrees of freedom (stored by the BuilderAndSolver)
rASystem matrix (unused)
rDxVector of results (variations on nodal variables)
rbRHS vector (residual + reactions)

Reimplemented in Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ InitializeSolutionStep()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::InitializeSolutionStep ( ModelPart rModelPart,
DofsArrayType rDofSet,
const TSystemMatrixType rA,
const TSystemVectorType rDx,
const TSystemVectorType rb 
)
inlinevirtual

This function initializes the solution step.

Warning
Must be defined on the derived classes
Parameters
rModelPartReference to the ModelPart containing the problem.
rDofSetReference to the container of the problem's degrees of freedom (stored by the BuilderAndSolver)
rASystem matrix (unused)
rDxVector of results (variations on nodal variables)
rbRHS vector (residual + reactions)

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::ResidualDisplacementAndOtherDoFCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ IsInitialized()

template<class TSparseSpace , class TDenseSpace >
virtual bool Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::IsInitialized ( )
inlinevirtual

This function returns if the convergence criteria is initialized.

Returns
mConvergenceCriteriaIsInitialized, true if initialized, false otherwise

◆ KRATOS_CLASS_POINTER_DEFINITION()

template<class TSparseSpace , class TDenseSpace >
Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::KRATOS_CLASS_POINTER_DEFINITION ( ConvergenceCriteria< TSparseSpace, TDenseSpace >  )

Pointer definition of ConvergenceCriteria.

◆ Name()

template<class TSparseSpace , class TDenseSpace >
static std::string Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::Name ( )
inlinestatic

Returns the name of the class as used in the settings (snake_case format)

Returns
The name of the class

◆ PostCriteria()

template<class TSparseSpace , class TDenseSpace >
virtual bool Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::PostCriteria ( ModelPart rModelPart,
DofsArrayType rDofSet,
const TSystemMatrixType rA,
const TSystemVectorType rDx,
const TSystemVectorType rb 
)
inlinevirtual

Criterias that need to be called after getting the solution.

Parameters
rModelPartReference to the ModelPart containing the problem.
rDofSetReference to the container of the problem's degrees of freedom (stored by the BuilderAndSolver)
rASystem matrix (unused)
rDxVector of results (variations on nodal variables)
rbRHS vector (residual + reactions)
Returns
true if convergence is achieved, false otherwise

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::ResidualDisplacementAndOtherDoFCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::MixedGenericCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosMixedGenericCriteria< TSparseSpace, TDenseSpace >, and Kratos::ErrorMeshCriteria< TSparseSpace, TDenseSpace >.

◆ PreCriteria()

template<class TSparseSpace , class TDenseSpace >
virtual bool Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::PreCriteria ( ModelPart rModelPart,
DofsArrayType rDofSet,
const TSystemMatrixType rA,
const TSystemVectorType rDx,
const TSystemVectorType rb 
)
inlinevirtual

Criterias that need to be called before getting the solution.

Parameters
rModelPartReference to the ModelPart containing the problem.
rDofSetReference to the container of the problem's degrees of freedom (stored by the BuilderAndSolver)
rASystem matrix (unused)
rDxVector of results (variations on nodal variables)
rbRHS vector (residual)
Returns
true if convergence is achieved, false otherwise

Reimplemented in Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ PrintData()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::PrintData ( std::ostream &  rOStream) const
inlinevirtual

Print object's data.

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::MixedGenericCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosDisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ PrintInfo()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::PrintInfo ( std::ostream &  rOStream) const
inlinevirtual

Print information about this object.

Reimplemented in Kratos::ResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, Kratos::MixedGenericCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::And_Criteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::TrilinosDisplacementCriteria< TSparseSpace, TDenseSpace >, Kratos::FemDemResidualCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::PenaltyFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MPCContactCriteria< TSparseSpace, TDenseSpace >, Kratos::MortarAndConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::MeshTyingMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierResidualContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierMixedContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierFrictionalContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementLagrangeMultiplierContactCriteria< TSparseSpace, TDenseSpace >, Kratos::DisplacementContactCriteria< TSparseSpace, TDenseSpace >, Kratos::ContactErrorMeshCriteria< TSparseSpace, TDenseSpace >, Kratos::BaseMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, Kratos::ALMFrictionlessComponentsMortarConvergenceCriteria< TSparseSpace, TDenseSpace >, and Kratos::ALMFrictionalMortarConvergenceCriteria< TSparseSpace, TDenseSpace >.

◆ SetActualizeRHSFlag()

template<class TSparseSpace , class TDenseSpace >
void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::SetActualizeRHSFlag ( bool  ActualizeRHSIsNeeded)
inline

This method sets the flag mActualizeRHSIsNeeded.

Parameters
ActualizeRHSIsNeededThe flag that tells if actualize RHS is needed

◆ SetEchoLevel()

template<class TSparseSpace , class TDenseSpace >
virtual void Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::SetEchoLevel ( int  Level)
inlinevirtual

It sets the level of echo for the solving strategy.

Parameters
LevelThe level to set

The different levels of echo are:

  • 0: Mute... no echo at all
  • 1: Printing time and basic information
  • 2: Printing linear solver data
  • 3: Print of debug information: Echo of stiffness matrix, Dx, b...

Reimplemented in Kratos::Or_Criteria< TSparseSpace, TDenseSpace >, and Kratos::And_Criteria< TSparseSpace, TDenseSpace >.

◆ ValidateAndAssignParameters()

template<class TSparseSpace , class TDenseSpace >
virtual Parameters Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::ValidateAndAssignParameters ( Parameters  ThisParameters,
const Parameters  DefaultParameters 
) const
inlineprotectedvirtual

This method validate and assign default parameters.

Parameters
rParametersParameters to be validated
DefaultParametersThe default parameters
Returns
Returns validated Parameters

Member Data Documentation

◆ mActualizeRHSIsNeeded

template<class TSparseSpace , class TDenseSpace >
bool Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::mActualizeRHSIsNeeded = false
protected

◆ mConvergenceCriteriaIsInitialized

template<class TSparseSpace , class TDenseSpace >
bool Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::mConvergenceCriteriaIsInitialized = false
protected

This "flag" is set in order to know if it is necessary to actualize the RHS.

◆ mEchoLevel

template<class TSparseSpace , class TDenseSpace >
int Kratos::ConvergenceCriteria< TSparseSpace, TDenseSpace >::mEchoLevel
protected

This "flag" is set in order to know if it is convergence criteria is initialized.


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