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.
total_structural_mass_process.h
Go to the documentation of this file.
1 // KRATOS ___| | | |
2 // \___ \ __| __| | | __| __| | | __| _` | |
3 // | | | | | ( | | | | ( | |
4 // _____/ \__|_| \__,_|\___|\__|\__,_|_| \__,_|_| MECHANICS
5 //
6 // License: BSD License
7 // license: StructuralMechanicsApplication/license.txt
8 //
9 // Main authors: Vicente Mataix Ferrandiz
10 //
11 
12 #pragma once
13 
14 // System includes
15 
16 // External includes
17 
18 // Project includes
19 #include "processes/process.h"
20 #include "includes/model_part.h"
21 
22 namespace Kratos
23 {
26 
30 
34 
38 
49 class KRATOS_API(STRUCTURAL_MECHANICS_APPLICATION) TotalStructuralMassProcess
50  : public Process
51 {
52 public:
55 
58 
62 
65  ModelPart& rThisModelPart
66  ):mrThisModelPart(rThisModelPart)
67  {
69 
70  KRATOS_CATCH("")
71  }
72 
75  = default;
76 
80 
84 
88 
92 
96 
100 
101  void Execute() override;
102 
103  static double CalculateElementMass(Element& rElement, const std::size_t DomainSize);
104 
108 
109 
113 
114 
118 
120  std::string Info() const override
121  {
122  return "TotalStructuralMassProcess";
123  }
124 
126  void PrintInfo(std::ostream& rOStream) const override
127  {
128  rOStream << "TotalStructuralMassProcess";
129  }
130 
132  void PrintData(std::ostream& rOStream) const override
133  {
134  }
135 
139 
140 
142 
143 protected:
146 
147 
151 
152 
156 
157 
161 
165 
166 
170 
171 
175 
176 
178 
179 private:
182 
183 
187 
188  ModelPart& mrThisModelPart; // The main model part
189 
193 
197 
198 
202 
203 
207 
208 
212 
215 
218 
219 
221 
222 }; // Class TotalStructuralMassProcess
223 
225 
228 
229 
233 
235 // inline std::istream& operator >> (std::istream& rIStream,
236 // TotalStructuralMassProcess& rThis);
237 //
238 // /// output stream function
239 // inline std::ostream& operator << (std::ostream& rOStream,
240 // const TotalStructuralMassProcess& rThis)
241 // {
242 // rThis.PrintInfo(rOStream);
243 // rOStream << std::endl;
244 // rThis.PrintData(rOStream);
245 //
246 // return rOStream;
247 // }
248 
249 }
PeriodicInterfaceProcess & operator=(const PeriodicInterfaceProcess &)=delete
Base class for all Elements.
Definition: element.h:60
This class aims to manage meshes for multi-physics simulations.
Definition: model_part.h:77
The base class for all processes in Kratos.
Definition: process.h:49
This method computes the total mass of a structure.
Definition: total_structural_mass_process.h:51
TotalStructuralMassProcess(ModelPart &rThisModelPart)
Default constructor.
Definition: total_structural_mass_process.h:64
void PrintData(std::ostream &rOStream) const override
Print object's data.
Definition: total_structural_mass_process.h:132
KRATOS_CLASS_POINTER_DEFINITION(TotalStructuralMassProcess)
Pointer definition of TotalStructuralMassProcess.
void PrintInfo(std::ostream &rOStream) const override
Print information about this object.
Definition: total_structural_mass_process.h:126
std::string Info() const override
Turn back information as a string.
Definition: total_structural_mass_process.h:120
~TotalStructuralMassProcess() override=default
Destructor.
#define KRATOS_CATCH(MoreInfo)
Definition: define.h:110
#define KRATOS_TRY
Definition: define.h:109
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21