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.
solver_process.hpp
Go to the documentation of this file.
1 //
2 // Project Name: KratosSolidMechanicsApplication $
3 // Created by: $Author: JMCarbonell $
4 // Last modified by: $Co-Author: $
5 // Date: $Date: August 2016 $
6 // Revision: $Revision: 0.0 $
7 //
8 //
9 
10 #if !defined(KRATOS_SOLVER_PROCESS_H_INCLUDED)
11 #define KRATOS_SOLVER_PROCESS_H_INCLUDED
12 
13 
14 
15 // System includes
16 
17 // External includes
18 
19 // Project includes
20 #include "includes/model_part.h"
22 #include "processes/process.h"
23 
24 namespace Kratos
25 {
26 
29 
31 
36 class SolverProcess : public Process
37 {
38 public:
41 
44 
48 
51 
53  SolverProcess(Flags options) : Process( options ) {}
54 
56  ~SolverProcess() override {}
57 
58 
62 
64  void operator()()
65  {
66  Execute();
67  }
68 
72 
73 
75  void Execute() override
76  {
77  }
78 
81  void ExecuteInitialize() override
82  {
83  }
84 
87  void ExecuteBeforeSolutionLoop() override final
88  {
89  KRATOS_WARNING(" SolverProcess ") << " method not available " << std::endl;
90  }
91 
94  {
95  }
96 
99  {
100  }
101 
104  {
105  }
106 
107 
110  {
111  KRATOS_WARNING(" SolverProcess ") << " method not available " << std::endl;
112  }
113 
114 
116  void ExecuteBeforeOutputStep() override final
117  {
118  KRATOS_WARNING(" SolverProcess ") << " method not available " << std::endl;
119  }
120 
121 
123  void ExecuteAfterOutputStep() override final
124  {
125  }
126 
127 
130  void ExecuteFinalize() override
131  {
132  }
133 
134 
138 
139 
143 
144 
148 
150  std::string Info() const override
151  {
152  return "SolverProcess";
153  }
154 
156  void PrintInfo(std::ostream& rOStream) const override
157  {
158  rOStream << "SolverProcess";
159  }
160 
162  void PrintData(std::ostream& rOStream) const override
163  {
164  }
165 
166 
171 
172 protected:
173 
182 
184  SolverProcess(SolverProcess const& rOther);
185 
199 
200 private:
201 
216 
218  SolverProcess& operator=(SolverProcess const& rOther);
219 
220 
230 
231 }; // Class SolverProcess
232 
234 
237 
238 
242 
243 
245 inline std::istream& operator >> (std::istream& rIStream,
246  SolverProcess& rThis);
247 
249 inline std::ostream& operator << (std::ostream& rOStream,
250  const SolverProcess& rThis)
251 {
252  rThis.PrintInfo(rOStream);
253  rOStream << std::endl;
254  rThis.PrintData(rOStream);
255 
256  return rOStream;
257 }
259 
260 
261 } // namespace Kratos.
262 
263 #endif // KRATOS_SOLVER_PROCESS_H_INCLUDED defined
Definition: flags.h:58
The base class for all processes in Kratos.
Definition: process.h:49
The base class for processes passed to the solution scheme.
Definition: solver_process.hpp:37
std::string Info() const override
Turn back information as a string.
Definition: solver_process.hpp:150
void Execute() override
Execute method is used to execute the SolverProcess algorithms.
Definition: solver_process.hpp:75
void PrintInfo(std::ostream &rOStream) const override
Print information about this object.
Definition: solver_process.hpp:156
virtual void ExecuteFinalizeNonLinearIteration()
this function will be executed at every time step AFTER performing a non linear iteration
Definition: solver_process.hpp:103
SolverProcess(Flags options)
Constructor.
Definition: solver_process.hpp:53
void ExecuteInitialize() override
Definition: solver_process.hpp:81
void PrintData(std::ostream &rOStream) const override
Print object's data.
Definition: solver_process.hpp:162
KRATOS_CLASS_POINTER_DEFINITION(SolverProcess)
Pointer definition of SolverProcess.
void ExecuteBeforeSolutionLoop() override final
Definition: solver_process.hpp:87
void ExecuteBeforeOutputStep() override final
this function will be executed at every time step BEFORE writing the output
Definition: solver_process.hpp:116
void ExecuteAfterOutputStep() override final
this function will be executed at every time step AFTER writing the output
Definition: solver_process.hpp:123
void ExecuteFinalizeSolutionStep() override
this function will be executed at every time step AFTER performing the solve phase
Definition: solver_process.hpp:109
void ExecuteInitializeSolutionStep() override
this function will be executed at every time step BEFORE performing the solve phase
Definition: solver_process.hpp:93
~SolverProcess() override
Destructor.
Definition: solver_process.hpp:56
SolverProcess(SolverProcess const &rOther)
Copy constructor.
void ExecuteFinalize() override
Definition: solver_process.hpp:130
virtual void ExecuteInitializeNonLinearIteration()
this function will be executed at every time step BEFORE performing a non linear iteration
Definition: solver_process.hpp:98
SolverProcess()
Default constructor.
Definition: solver_process.hpp:50
void operator()()
This operator is provided to call the process as a function and simply calls the Execute method.
Definition: solver_process.hpp:64
#define KRATOS_WARNING(label)
Definition: logger.h:265
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
std::istream & operator>>(std::istream &rIStream, LinearMasterSlaveConstraint &rThis)
input stream function
std::ostream & operator<<(std::ostream &rOStream, const LinearMasterSlaveConstraint &rThis)
output stream function
Definition: linear_master_slave_constraint.h:432