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.
surface_load_condition_3d.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: Riccardo Rossi
10 //
11 
12 #pragma once
13 
14 // System includes
15 
16 // External includes
17 
18 // Project includes
20 
21 namespace Kratos
22 {
23 
26 
30 
34 
38 
42 
51 class KRATOS_API(STRUCTURAL_MECHANICS_APPLICATION) SurfaceLoadCondition3D
52  : public BaseLoadCondition
53 {
54 public:
55 
58 
59  // Counted pointer of SurfaceLoadCondition3D
61 
65 
66  // Constructor void
68 
69  // Constructor using an array of nodes
71  IndexType NewId,
72  GeometryType::Pointer pGeometry
73  );
74 
75  // Constructor using an array of nodes with properties
77  IndexType NewId,
78  GeometryType::Pointer pGeometry,
79  PropertiesType::Pointer pProperties
80  );
81 
82  // Destructor
83  ~SurfaceLoadCondition3D() override;
84 
88 
89 
93 
101  Condition::Pointer Create(
102  IndexType NewId,
103  NodesArrayType const& ThisNodes,
104  PropertiesType::Pointer pProperties
105  ) const override;
106 
114  Condition::Pointer Create(
115  IndexType NewId,
116  GeometryType::Pointer pGeom,
117  PropertiesType::Pointer pProperties
118  ) const override;
119 
126  Condition::Pointer Clone (
127  IndexType NewId,
128  NodesArrayType const& ThisNodes
129  ) const override;
130 
138  const Variable<array_1d<double, 3 > >& rVariable,
139  std::vector< array_1d<double, 3 > >& rOutput,
140  const ProcessInfo& rCurrentProcessInfo
141  ) override;
142 
146 
147 
151 
152 
156 
158  std::string Info() const override
159  {
160  std::stringstream buffer;
161  buffer << "Surface load Condition #" << Id();
162  return buffer.str();
163  }
164 
166 
167  void PrintInfo(std::ostream& rOStream) const override
168  {
169  rOStream << "Surface load Condition #" << Id();
170  }
171 
173  void PrintData(std::ostream& rOStream) const override
174  {
175  pGetGeometry()->PrintData(rOStream);
176  }
177 
181 
182 protected:
183 
186 
190 
194 
198 
207  void CalculateAll(
208  MatrixType& rLeftHandSideMatrix,
209  VectorType& rRightHandSideVector,
210  const ProcessInfo& rCurrentProcessInfo,
211  const bool CalculateStiffnessMatrixFlag,
212  const bool CalculateResidualVectorFlag
213  ) override;
214 
225  void CalculateAndSubKp(
226  Matrix& rK,
227  const array_1d<double, 3>& rTangentXi,
228  const array_1d<double, 3>& rTangentEta,
229  const Matrix& rDN_De,
230  const Vector& rN,
231  const double Pressure,
232  const double Weight
233  ) const;
234 
244  void CalculateAndAddPressureForce(
245  VectorType& rResidualVector,
246  const Vector& rN,
247  const array_1d<double, 3 >& rNormal,
248  const double Pressure,
249  const double Weight,
250  const ProcessInfo& rCurrentProcessInfo
251  ) const;
252 
256 
260 
264 
265 private:
268 
272 
276 
280 
284 
288 
292 
296 
300 
301  friend class Serializer;
302 
303  void save( Serializer& rSerializer ) const override
304  {
306  }
307 
308  void load( Serializer& rSerializer ) override
309  {
311  }
312 
313 
314 }; // class SurfaceLoadCondition3D.
315 
318 
322 
323 } // namespace Kratos.
This is the base class of all the load conditions on StructuralMechanicsApplication.
Definition: base_load_condition.h:54
std::size_t IndexType
Definition: flags.h:74
PointerVector is a container like stl vector but using a vector to store pointers to its data.
Definition: pointer_vector.h:72
ProcessInfo holds the current value of different solution parameters.
Definition: process_info.h:59
The serialization consists in storing the state of an object into a storage format like data file or ...
Definition: serializer.h:123
This class is the responsible to add the contributions of the RHS and LHS of the surface loads of the...
Definition: surface_load_condition_3d.h:53
std::string Info() const override
Turn back information as a string.
Definition: surface_load_condition_3d.h:158
void PrintInfo(std::ostream &rOStream) const override
Print information about this object.
Definition: surface_load_condition_3d.h:167
void PrintData(std::ostream &rOStream) const override
Print object's data.
Definition: surface_load_condition_3d.h:173
KRATOS_CLASS_INTRUSIVE_POINTER_DEFINITION(SurfaceLoadCondition3D)
Variable class contains all information needed to store and retrive data from a data container.
Definition: variable.h:63
#define KRATOS_SERIALIZE_SAVE_BASE_CLASS(Serializer, BaseType)
Definition: define.h:812
#define KRATOS_SERIALIZE_LOAD_BASE_CLASS(Serializer, BaseType)
Definition: define.h:815
Matrix MatrixType
Definition: geometrical_transformation_utilities.h:55
Modeler::Pointer Create(const std::string &ModelerName, Model &rModel, const Parameters ModelParameters)
Checks if the modeler is registered.
Definition: modeler_factory.cpp:30
pybind11::list CalculateOnIntegrationPoints(TObject &dummy, const Variable< TDataType > &rVariable, const ProcessInfo &rProcessInfo)
Definition: add_mesh_to_python.cpp:142
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
def load(f)
Definition: ode_solve.py:307