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.
drag_and_moment_utilities.h
Go to the documentation of this file.
1 // | / |
2 // ' / __| _` | __| _ \ __|
3 // . \ | ( | | ( |\__ `
4 // _|\_\_| \__,_|\__|\___/ ____/
5 // Multi-Physics
6 //
7 // License: BSD License
8 // Kratos default license: kratos/license.txt
9 //
10 // Main author: Ruben Zorrilla
11 // Anoop Kodakkal
12 //
13 
14 #if !defined(KRATOS_DRAG_AND_MOMENT_UTILITIES_H_INCLUDED )
15 #define KRATOS_DRAG_AND_MOMENT_UTILITIES_H_INCLUDED
16 
17 // System includes
18 #include <string>
19 #include <iostream>
20 
21 // External includes
22 
23 // Project includes
24 #include "includes/define.h"
25 #include "includes/model_part.h"
26 #include "geometries/geometry.h"
28 #include "utilities/openmp_utils.h"
30 
31 // Application includes
33 
34 namespace Kratos
35 {
38 
41 
45 
49 
53 
57 
59 
62  class KRATOS_API(FLUID_DYNAMICS_APPLICATION) DragAndMomentUtilities
63  {
64  public:
65 
68 
71  typedef std::vector<IntegrationPointType> IntegrationPointsArrayType;
72 
75 
79 
82 
85 
89 
90 
94 
101  std::tuple<array_1d<double, 3>, array_1d<double, 3>> CalculateBodyFittedDragAndMoment(ModelPart &rModelPart, array_1d<double, 3> rReferencePoint);
102 
108  std::tuple<array_1d<double, 3>, array_1d<double, 3>> CalculateEmbeddedDragAndMoment(ModelPart &rModelPart, array_1d<double, 3> rReferencePoint);
109 
113 
114 
118 
119 
123 
125  std::string Info() const;
126 
128  void PrintInfo(std::ostream& rOStream) const;
129 
131  void PrintData(std::ostream& rOStream) const;
132 
136 
137 
139 
140 private:
143 
144 
148 
149 
153 
154 
158 
159 
163 
164 
168 
169 
173 
176 
179 
181 
182 }; // Class DragUtilities
183 
185 
188 
189 
193 
194 
196 inline std::ostream& operator << (
197  std::ostream& rOStream,
198  const DragAndMomentUtilities& rThis);
199 
201 
203 
204 } // namespace Kratos.
205 
206 #endif // KRATOS_DRAG_UTILITIES_H_INCLUDED defined
PeriodicInterfaceProcess & operator=(const PeriodicInterfaceProcess &)=delete
Auxiliary utility to compute the drag force and the moment around a given point.
Definition: drag_and_moment_utilities.h:63
void PrintInfo(std::ostream &rOStream) const
Print information about this object.
void PrintData(std::ostream &rOStream) const
Print object's data.
~DragAndMomentUtilities()
Destructor.
Definition: drag_and_moment_utilities.h:84
KRATOS_CLASS_POINTER_DEFINITION(DragAndMomentUtilities)
Pointer definition of DragAndMomentUtilities.
IntegrationPoint< 3 > IntegrationPointType
Definition: drag_and_moment_utilities.h:70
Geometry< Node > GeometryType
Definition: drag_and_moment_utilities.h:69
std::vector< IntegrationPointType > IntegrationPointsArrayType
Definition: drag_and_moment_utilities.h:71
std::string Info() const
Turn back information as a string.
DragAndMomentUtilities()
Constructor.
Definition: drag_and_moment_utilities.h:81
Geometry base class.
Definition: geometry.h:71
Short class definition.
Definition: integration_point.h:52
This class aims to manage meshes for multi-physics simulations.
Definition: model_part.h:77
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
std::ostream & operator<<(std::ostream &rOStream, const LinearMasterSlaveConstraint &rThis)
output stream function
Definition: linear_master_slave_constraint.h:432