![]() |
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.
|
#include <nodal_two_step_v_p_strategy.h>
Public Member Functions | |
Life Cycle | |
| NodalTwoStepVPStrategy (ModelPart &rModelPart, SolverSettingsType &rSolverConfig) | |
| NodalTwoStepVPStrategy (ModelPart &rModelPart, typename TLinearSolver::Pointer pVelocityLinearSolver, typename TLinearSolver::Pointer pPressureLinearSolver, bool ReformDofSet=true, double VelTol=0.0001, double PresTol=0.0001, int MaxPressureIterations=1, unsigned int TimeOrder=2, unsigned int DomainSize=2) | |
| virtual | ~NodalTwoStepVPStrategy () |
| Destructor. More... | |
| int | Check () override |
| Function to perform expensive checks. More... | |
| void | SetTimeCoefficients (ProcessInfo &rCurrentProcessInfo) |
| bool | SolveSolutionStep () override |
| Solves the current step. This function returns true if a solution has been found, false otherwise. More... | |
| void | FinalizeSolutionStep () override |
| Performs all the required operations that should be done (for each step) after solving the solution step. More... | |
| void | Initialize () override |
| Initialization of member variables and prior operations. More... | |
| void | InitialAssignFluidMaterialToEachNode (ModelPart::NodeIterator itNode) |
| void | ComputeNodalVolume () |
| void | SetNeighboursOrderToNode (ModelPart::NodeIterator itNode) |
| void | InitializeNodalVariablesForRemeshedDomain (ModelPart::NodeIterator itNode) |
| void | InitializeNonLinearIterations () |
| void | CalcNodalStrainsAndStresses () |
| void | CalcNodalStrainsAndStressesForNode (ModelPart::NodeIterator itNode) |
| void | ComputeDeviatoricCoefficientForFluid (ModelPart::NodeIterator itNode, const unsigned int dimension, double &deviatoricCoefficient) |
| void | CalcNodalStrainsForNode (ModelPart::NodeIterator itNode) |
| void | CalcNodalStrains () |
| void | ComputeAndStoreNodalDeformationGradient (ModelPart::NodeIterator itNode, double theta) |
| void | UpdateTopology (ModelPart &rModelPart, unsigned int echoLevel) |
| void | CalculatePressureVelocity () |
| void | CalculatePressureAcceleration () |
| void | CalculateAccelerations () |
| void | UpdateAccelerations (array_1d< double, 3 > &CurrentAcceleration, const array_1d< double, 3 > &CurrentVelocity, array_1d< double, 3 > &PreviousAcceleration, const array_1d< double, 3 > &PreviousVelocity) |
| void | CalculateDisplacements () |
| void | CalculateDisplacementsAndResetNodalVariables () |
| void | UpdatePressureAccelerations () |
| void | Clear () override |
| Clears the internal storage. More... | |
Access | |
| void | SetEchoLevel (int Level) override |
| This sets the level of echo for the solving strategy. More... | |
Input and output | |
| std::string | Info () const override |
| Turn back information as a string. More... | |
| void | PrintInfo (std::ostream &rOStream) const override |
| Print information about this object. More... | |
| void | PrintData (std::ostream &rOStream) const override |
| Print object's data. More... | |
Public Member Functions inherited from Kratos::ImplicitSolvingStrategy< TSparseSpace, TDenseSpace, TLinearSolver > | |
| ImplicitSolvingStrategy () | |
| Default constructor. More... | |
| ImplicitSolvingStrategy (ModelPart &rModelPart, Parameters ThisParameters) | |
| Default constructor. (with parameters) More... | |
| ImplicitSolvingStrategy (ModelPart &rModelPart, bool MoveMeshFlag=false) | |
| Default constructor. More... | |
| virtual | ~ImplicitSolvingStrategy () |
| BaseType::Pointer | Create (ModelPart &rModelPart, Parameters ThisParameters) const override |
| Create method. More... | |
| void | SetRebuildLevel (int Level) override |
| This sets the build level. More... | |
| int | GetRebuildLevel () const override |
| This returns the build level. More... | |
| void | SetStiffnessMatrixIsBuilt (const bool StiffnessMatrixIsBuilt) |
| This method sets the flag mStiffnessMatrixIsBuilt. More... | |
| bool | GetStiffnessMatrixIsBuilt () const |
| This method gets the flag mStiffnessMatrixIsBuilt. More... | |
| KRATOS_CLASS_POINTER_DEFINITION (ImplicitSolvingStrategy) | |
| Parameters | GetDefaultParameters () const override |
| This method provides the defaults parameters to avoid conflicts between the different constructors. More... | |
Public Member Functions inherited from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace > | |
| SolvingStrategy () | |
| Default constructor. More... | |
| SolvingStrategy (ModelPart &rModelPart, Parameters ThisParameters) | |
| Default constructor. (with parameters) More... | |
| SolvingStrategy (ModelPart &rModelPart, bool MoveMeshFlag=false) | |
| Default constructor. More... | |
| virtual | ~SolvingStrategy () |
| KRATOS_CLASS_POINTER_DEFINITION (SolvingStrategy) | |
| virtual void | Predict () |
| Operation to predict the solution ... if it is not called a trivial predictor is used in which the values of the solution step of interest are assumed equal to the old values. More... | |
| virtual double | Solve () |
| The problem of interest is solved. More... | |
| virtual bool | IsConverged () |
| This should be considered as a "post solution" convergence check which is useful for coupled analysis. More... | |
| virtual void | CalculateOutputData () |
| This operations should be called before printing the results when non trivial results (e.g. stresses) need to be calculated given the solution of the step. More... | |
| virtual void | InitializeSolutionStep () |
| Performs all the required operations that should be done (for each step) before solving the solution step. More... | |
| int | GetEchoLevel () |
| This returns the level of echo for the solving strategy. More... | |
| void | SetMoveMeshFlag (bool Flag) |
| This function sets the flag that says if the mesh is moved. More... | |
| bool | MoveMeshFlag () |
| This function returns the flag that says if the mesh is moved. More... | |
| bool | GetMoveMeshFlag () |
| This function returns the flag that says if the mesh is moved. More... | |
| virtual void | MoveMesh () |
| This function is designed to move the mesh. More... | |
| ModelPart & | GetModelPart () |
| Operations to get the pointer to the model. More... | |
| const ModelPart & | GetModelPart () const |
| Operations to get the pointer to the model. More... | |
| virtual double | GetResidualNorm () |
| Operations to get the residual norm. More... | |
| virtual TSystemMatrixType & | GetSystemMatrix () |
| This method returns the LHS matrix. More... | |
| virtual TSystemVectorType & | GetSystemVector () |
| This method returns the RHS vector. More... | |
| virtual TSystemVectorType & | GetSolutionVector () |
| This method returns the solution vector. More... | |
Protected Member Functions | |
Protected Operations | |
| bool | SolveMomentumIteration (unsigned int it, unsigned int maxIt, bool &fixedTimeStep, double &velocityNorm) |
| Calculate the coefficients for time iteration. More... | |
| bool | SolveContinuityIteration (unsigned int it, unsigned int maxIt, double &NormP) |
| bool | CheckVelocityConvergence (const double NormDv, double &errorNormDv) |
| double | ComputeVelocityNorm () |
| double | ComputePressureNorm () |
| void | ComputeErrorL2NormCaseImposedG () |
| void | ComputeErrorL2NormCasePoiseuille () |
| bool | CheckPressureConvergence (const double NormDp, double &errorNormDp) |
| bool | FixTimeStepMomentum (const double DvErrorNorm) |
| bool | CheckMomentumConvergence (const double DvErrorNorm) |
| bool | FixTimeStepContinuity (const double DvErrorNorm) |
Protected Member Functions inherited from Kratos::ImplicitSolvingStrategy< TSparseSpace, TDenseSpace, TLinearSolver > | |
| void | AssignSettings (const Parameters ThisParameters) override |
| This method assigns settings to member variables. More... | |
Protected Member Functions inherited from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace > | |
| virtual Parameters | ValidateAndAssignParameters (Parameters ThisParameters, const Parameters DefaultParameters) const |
| This method validate and assign default parameters. More... | |
Protected Attributes | |
Member Variables | |
| double | mVelocityTolerance |
| double | mPressureTolerance |
| unsigned int | mMaxPressureIter |
| unsigned int | mDomainSize |
| unsigned int | mTimeOrder |
| bool | mReformDofSet |
| StrategyPointerType | mpMomentumStrategy |
| Scheme for the solution of the momentum equation. More... | |
| StrategyPointerType | mpPressureStrategy |
| Scheme for the solution of the mass equation. More... | |
Protected Attributes inherited from Kratos::ImplicitSolvingStrategy< TSparseSpace, TDenseSpace, TLinearSolver > | |
| int | mRebuildLevel |
| bool | mStiffnessMatrixIsBuilt |
| The current rebuild level. More... | |
Protected Attributes inherited from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace > | |
| int | mEchoLevel |
Private Operations | |
| void | InitializeStrategy (SolverSettingsType &rSolverConfig) |
| typedef ImplicitSolvingStrategy<TSparseSpace, TDenseSpace, TLinearSolver> Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::BaseType |
Counted pointer of NodalTwoStepVPStrategy.
| typedef BaseType::DofsArrayType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::DofsArrayType |
| typedef BaseType::ElementsArrayType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::ElementsArrayType |
| typedef Geometry<NodeType> Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::GeometryType |
Geometry type (using with given NodeType)
| typedef BaseType::LocalSystemMatrixType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::LocalSystemMatrixType |
| typedef BaseType::LocalSystemVectorType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::LocalSystemVectorType |
| typedef Node Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::NodeType |
| typedef GlobalPointersVector<Node> Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::NodeWeakPtrVectorType |
| typedef GeometryType::ShapeFunctionsGradientsType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::ShapeFunctionDerivativesArrayType |
| typedef std::size_t Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::SizeType |
| typedef TwoStepVPSolverSettings<TSparseSpace, TDenseSpace, TLinearSolver> Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::SolverSettingsType |
| typedef ImplicitSolvingStrategy<TSparseSpace, TDenseSpace, TLinearSolver>::Pointer Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::StrategyPointerType |
| typedef BaseType::TDataType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::TDataType |
| typedef BaseType::TSystemMatrixType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::TSystemMatrixType |
| typedef BaseType::TSystemVectorType Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::TSystemVectorType |
|
inline |
|
inline |
|
inlinevirtual |
Destructor.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineoverridevirtual |
Function to perform expensive checks.
It is designed to be called ONCE to verify that the input is correct.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
|
inlineprotected |
|
inlineprotected |
|
inlineprotected |
|
inlineoverridevirtual |
Clears the internal storage.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
|
inline |
|
inline |
|
inlineprotected |
|
inlineprotected |
|
inline |
|
inlineprotected |
|
inlineprotected |
|
inlineoverridevirtual |
Performs all the required operations that should be done (for each step) after solving the solution step.
A member variable should be used as a flag to make sure this function is called only once per step.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
|
inlineprotected |
|
inlineprotected |
|
inlineoverridevirtual |
Turn back information as a string.
Reimplemented from Kratos::ImplicitSolvingStrategy< TSparseSpace, TDenseSpace, TLinearSolver >.
Reimplemented in Kratos::NodalTwoStepVPStrategyForFSI< TSparseSpace, TDenseSpace, TLinearSolver >.
|
inline |
|
inlineoverridevirtual |
Initialization of member variables and prior operations.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
Reimplemented in Kratos::NodalTwoStepVPStrategyForFSI< TSparseSpace, TDenseSpace, TLinearSolver >.
|
inline |
|
inline |
|
inlineprotected |
| Kratos::NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver >::KRATOS_CLASS_POINTER_DEFINITION | ( | NodalTwoStepVPStrategy< TSparseSpace, TDenseSpace, TLinearSolver > | ) |
|
inlineoverridevirtual |
Print object's data.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
|
inlineoverridevirtual |
Print information about this object.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
Reimplemented in Kratos::NodalTwoStepVPStrategyForFSI< TSparseSpace, TDenseSpace, TLinearSolver >.
|
inlineoverridevirtual |
This sets the level of echo for the solving strategy.
| Level | of echo for the solving strategy |
{ 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 from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
|
inline |
|
inline |
|
inlineprotected |
|
inlineprotected |
Calculate the coefficients for time iteration.
| rCurrentProcessInfo | ProcessInfo instance from the fluid ModelPart. Must contain DELTA_TIME variables. |
|
inlineoverridevirtual |
Solves the current step. This function returns true if a solution has been found, false otherwise.
Reimplemented from Kratos::SolvingStrategy< TSparseSpace, TDenseSpace >.
Reimplemented in Kratos::NodalTwoStepVPStrategyForFSI< TSparseSpace, TDenseSpace, TLinearSolver >.
|
inline |
|
inline |
|
inline |
|
protected |
|
protected |
|
protected |
Scheme for the solution of the momentum equation.
|
protected |
Scheme for the solution of the mass equation.
|
protected |
|
protected |
|
protected |
|
protected |