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.
axisymmetric_eulerian_convection_diffusion.h
Go to the documentation of this file.
1 // KRATOS ___ ___ _ ___ __ ___ ___ ___ ___
2 // / __/ _ \| \| \ \ / /__| \_ _| __| __|
3 // | (_| (_) | .` |\ V /___| |) | || _|| _|
4 // \___\___/|_|\_| \_/ |___/___|_| |_| APPLICATION
5 //
6 // License: BSD License
7 // Kratos default license: kratos/license.txt
8 //
9 // Main authors: Ruben Zorrilla
10 //
11 
12 #pragma once
13 
14 // System includes
15 
16 
17 // External includes
18 
19 
20 // Project includes
22 #include "includes/define.h"
23 #include "includes/serializer.h"
24 
25 // Application includes
26 #include "eulerian_conv_diff.h"
27 
30 
33 
37 
41 
45 
49 
50 namespace Kratos
51 {
52 
53 template< unsigned int TDim, unsigned int TNumNodes>
54 class KRATOS_API(CONVECTION_DIFFUSION_APPLICATION) AxisymmetricEulerianConvectionDiffusionElement
55  : public EulerianConvectionDiffusionElement<TDim, TNumNodes>
56 {
57 public:
58 
61 
64 
67 
70 
73 
75  using IndexType = typename BaseType::IndexType;
76 
78  using SizeType = typename BaseType::SizeType;
79 
81  using VectorType = typename BaseType::VectorType;
82 
84  using MatrixType = typename BaseType::MatrixType;
85 
88 
91 
95 
98  {
99  }
100 
102  IndexType NewId,
103  typename GeometryType::Pointer pGeometry)
104  : BaseType(NewId, pGeometry)
105  {}
106 
108  IndexType NewId,
109  typename GeometryType::Pointer pGeometry,
110  typename PropertiesType::Pointer pProperties)
111  : BaseType(NewId, pGeometry, pProperties)
112  {}
113 
116 
120 
121 
125 
126  Element::Pointer Create(
127  IndexType NewId,
128  NodesArrayType const& ThisNodes,
129  typename PropertiesType::Pointer pProperties) const override
130  {
131  return Kratos::make_intrusive<AxisymmetricEulerianConvectionDiffusionElement<TDim, TNumNodes>>(NewId, this->GetGeometry().Create(ThisNodes), pProperties);
132  }
133 
134  Element::Pointer Create(
135  IndexType NewId,
136  typename GeometryType::Pointer pGeom,
137  typename PropertiesType::Pointer pProperties) const override
138  {
139  return Kratos::make_intrusive<AxisymmetricEulerianConvectionDiffusionElement<TDim, TNumNodes>>(NewId, pGeom, pProperties);
140  }
141 
142  void CalculateLocalSystem(
143  MatrixType& rLeftHandSideMatrix,
144  VectorType& rRightHandSideVector,
145  const ProcessInfo& rCurrentProcessInfo) override;
146 
147  void CalculateRightHandSide(
148  VectorType& rRightHandSideVector,
149  const ProcessInfo& rCurrentProcessInfo) override;
150 
154 
155 
159 
160  int Check(const ProcessInfo &rCurrentProcessInfo) const override;
161 
165 
166  std::string Info() const override
167  {
168  return "AxisymmetricConvectionDiffusion #";
169  }
170 
171  void PrintInfo(std::ostream& rOStream) const override
172  {
173  rOStream << this->Info() << this->Id();
174  }
175 
176 
180 
181 
183 protected:
186 
187 
191 
192 
196 
197 
201 
202  double CalculateTau(
203  const typename BaseType::ElementVariables &rVariables,
204  const double NormVelocity,
205  const double ElementSize);
206 
210 
211 
215 
216 
220 
221 
223 private:
226 
229 
233 
234 
238 
239 
243 
244  friend class Serializer;
245 
246  void save(Serializer& rSerializer) const override
247  {
249  }
250 
251  void load(Serializer& rSerializer) override
252  {
253  KRATOS_SERIALIZE_LOAD_BASE_CLASS(rSerializer, BaseType);
254  }
255 
259 
260 
264 
277  void CalculateGaussPointData(
278  const array_1d<double, TNumNodes> &rN,
279  const BoundedMatrix<double, TNumNodes, TDim> &rDNDX,
280  typename BaseType::ElementVariables &rVariables,
281  double &rRadius,
282  array_1d<double, TDim> &rVelocity,
283  array_1d<double, TNumNodes> &rConvectionOperator,
284  BoundedMatrix<double, TDim, TDim> &rVelocityGradient) const;
285 
289 
290 
294 
295 
299 
300 
302 }; // Class AxisymmetricConvectionDiffusion
303 
305 
307 
308 } // namespace Kratos.
std::string Info() const override
Turn back information as a string.
Definition: periodic_interface_process.hpp:93
Definition: axisymmetric_eulerian_convection_diffusion.h:56
virtual ~AxisymmetricEulerianConvectionDiffusionElement()
Destructor.
Definition: axisymmetric_eulerian_convection_diffusion.h:115
typename GeometryType::ShapeFunctionsGradientsType ShapeFunctionsGradientsType
Shape functions gradient container type.
Definition: axisymmetric_eulerian_convection_diffusion.h:90
KRATOS_CLASS_INTRUSIVE_POINTER_DEFINITION(AxisymmetricEulerianConvectionDiffusionElement)
Pointer definition of AxisymmetricEulerianConvectionDiffusionElement.
Element::Pointer Create(IndexType NewId, NodesArrayType const &ThisNodes, typename PropertiesType::Pointer pProperties) const override
It creates a new element pointer.
Definition: axisymmetric_eulerian_convection_diffusion.h:126
AxisymmetricEulerianConvectionDiffusionElement()
Constructors.
Definition: axisymmetric_eulerian_convection_diffusion.h:97
std::string Info() const override
Turn back information as a string.
Definition: axisymmetric_eulerian_convection_diffusion.h:166
AxisymmetricEulerianConvectionDiffusionElement(IndexType NewId, typename GeometryType::Pointer pGeometry, typename PropertiesType::Pointer pProperties)
Definition: axisymmetric_eulerian_convection_diffusion.h:107
AxisymmetricEulerianConvectionDiffusionElement(IndexType NewId, typename GeometryType::Pointer pGeometry)
Definition: axisymmetric_eulerian_convection_diffusion.h:101
Element::Pointer Create(IndexType NewId, typename GeometryType::Pointer pGeom, typename PropertiesType::Pointer pProperties) const override
It creates a new element pointer.
Definition: axisymmetric_eulerian_convection_diffusion.h:134
void PrintInfo(std::ostream &rOStream) const override
Print information about this object.
Definition: axisymmetric_eulerian_convection_diffusion.h:171
std::size_t SizeType
Definition: element.h:94
formulation described in https://docs.google.com/document/d/13a_zGLj6xORDuLgoOG5LwHI6BwShvfO166opZ815...
Definition: eulerian_conv_diff.h:41
std::size_t IndexType
Definition: flags.h:74
This defines the geometrical object, base definition of the element and condition entities.
Definition: geometrical_object.h:58
IntegrationMethod
Definition: geometry_data.h:76
Geometry base class.
Definition: geometry.h:71
GeometryData::ShapeFunctionsGradientsType ShapeFunctionsGradientsType
Definition: geometry.h:189
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
Properties encapsulates data shared by different Elements or Conditions. It can store any type of dat...
Definition: properties.h:69
The serialization consists in storing the state of an object into a storage format like data file or ...
Definition: serializer.h:123
#define KRATOS_SERIALIZE_SAVE_BASE_CLASS(Serializer, BaseType)
Definition: define.h:812
#define KRATOS_SERIALIZE_LOAD_BASE_CLASS(Serializer, BaseType)
Definition: define.h:815
std::size_t IndexType
Definition: binary_expression.cpp:25
Vector VectorType
Definition: geometrical_transformation_utilities.h:56
Matrix MatrixType
Definition: geometrical_transformation_utilities.h:55
std::size_t SizeType
Definition: nurbs_utilities.h:41
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
Properties PropertiesType
Definition: regenerate_pfem_pressure_conditions_process.h:26
Geometry< Node > GeometryType
The definition of the geometry.
Definition: mortar_classes.h:37
ModelPart::NodesContainerType NodesArrayType
Definition: gid_gauss_point_container.h:42
def load(f)
Definition: ode_solve.py:307