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.
optimization_application.h
Go to the documentation of this file.
1 // | / |
2 // ' / __| _` | __| _ \ __|
3 // . \ | ( | | ( |\__ `
4 // _|\_\_| \__,_|\__|\___/ ____/
5 // Multi-Physics
6 //
7 // License: BSD License
8 // license: OptimizationApplication/license.txt
9 //
10 // Main authors: Reza Najian Asl, https://github.com/RezaNajian
11 // Suneth Warnakulasuriya
12 
13 #pragma once
14 
15 // System includes
16 #include <string>
17 #include <iostream>
18 
19 // External includes
20 
21 // Project includes
23 
24 /* ELEMENTS */
30 
31 /* ELEMENT DATA CONTAINERS*/
35 
36 /* ADJOINT ELEMENTS */
38 
39 /* CONDITIONS */
42 
43 /* CONSTITUTIVE LAWS */
45 
46 namespace Kratos
47 {
50 
52 
54  class KRATOS_API(OPTIMIZATION_APPLICATION) KratosOptimizationApplication : public KratosApplication
55  {
56  public:
59 
62 
66 
69 
72 
74 
77 
81 
82  void Register() override;
83 
87 
89  std::string Info() const override
90  {
91  return "KratosOptimizationApplication";
92  }
93 
95  void PrintInfo(std::ostream& rOStream) const override
96  {
97  rOStream << Info();
98  PrintData(rOStream);
99  }
100 
102  void PrintData(std::ostream& rOStream) const override
103  {
104  KRATOS_WATCH("in my application");
106  rOStream << "Variables:" << std::endl;
108  rOStream << std::endl;
109  rOStream << "Elements:" << std::endl;
110  KratosComponents<Element>().PrintData(rOStream);
111  rOStream << std::endl;
112  rOStream << "Conditions:" << std::endl;
113  KratosComponents<Condition>().PrintData(rOStream);
114  }
115 
117 
118  private:
121 
122  /* ELEMENTS */
123 
124  const HelmholtzSurfShapeElement mHelmholtzSurfShape3D3N;
125  const HelmholtzSurfThicknessElement mHelmholtzSurfThickness3D3N;
126  const HelmholtzBulkShapeElement mHelmholtzBulkShape3D4N;
127  const HelmholtzBulkElement mHelmholtzBulkTopology3D4N;
128 
129  /* ADJ ELEMENTS */
130  const AdjointSmallDisplacementElement mAdjointSmallDisplacementElement3D4N;
131 
132  // Helmholtz elements
133  const HelmholtzElement<HelmholtzSurfaceDataContainer<3, 3, 1>> mHelmholtzSurfaceElement3D3N;
134  const HelmholtzElement<HelmholtzSurfaceDataContainer<3, 4, 1>> mHelmholtzSurfaceElement3D4N;
135  const HelmholtzElement<HelmholtzSurfaceDataContainer<3, 3, 3>> mHelmholtzVectorSurfaceElement3D3N;
136  const HelmholtzElement<HelmholtzSurfaceDataContainer<3, 4, 3>> mHelmholtzVectorSurfaceElement3D4N;
137 
138  const HelmholtzElement<HelmholtzSolidDataContainer<3, 4, 1>> mHelmholtzSolidElement3D4N;
139  const HelmholtzElement<HelmholtzSolidDataContainer<3, 8, 1>> mHelmholtzSolidElement3D8N;
140  const HelmholtzElement<HelmholtzSolidDataContainer<3, 4, 3>> mHelmholtzVectorSolidElement3D4N;
141  const HelmholtzElement<HelmholtzSolidDataContainer<3, 8, 3>> mHelmholtzVectorSolidElement3D8N;
142 
143  const HelmholtzElement<HelmholtzSolidShapeDataContainer<3, 4>> mHelmholtzSolidShapeElement3D4N;
144  const HelmholtzElement<HelmholtzSolidShapeDataContainer<3, 8>> mHelmholtzSolidShapeElement3D8N;
145 
146  /* CONDITIONS*/
147  // Surface conditions
148  const HelmholtzSurfShapeCondition mHelmholtzSurfShapeCondition3D3N;
149  const HelmholtzSurfaceShapeCondition mHelmholtzSurfaceShapeCondition3D3N;
150  const HelmholtzSurfaceShapeCondition mHelmholtzSurfaceShapeCondition3D4N;
151 
152  /* CONSTITUTIVE LAWS */
153  const HelmholtzJacobianStiffened3D mHelmholtzJacobianStiffened3D;
154 
156 
157  }; // Class KratosOptimizationApplication
158 
160 
161 } // namespace Kratos.
162 
163 
std::string Info() const override
Turn back information as a string.
Definition: periodic_interface_process.hpp:93
Short class definition.
Definition: adjoint_small_displacement_element.h:57
Short class definition.
Definition: helmholtz_bulk_element.h:62
Short class definition.
Definition: helmholtz_bulk_shape_element.h:57
Short class definition.
Definition: helmholtz_element.h:42
This class defines constitutive model for shape filtering of solid 3D cases. This current implementat...
Definition: helmholtz_jacobian_stiffened_3d.h:55
This is the class of surface PDE/Helmholtz-based surface filtering.
Definition: helmholtz_surf_shape_condition.h:56
Short class definition.
Definition: helmholtz_surf_shape_element.h:59
Short class definition.
Definition: helmholtz_surf_thickness_element.h:59
Short class definition.
Definition: helmholtz_surface_shape_condition.h:44
This class defines the interface with kernel for all applications in Kratos.
Definition: kratos_application.h:91
Definition: kratos_components.h:253
virtual void PrintData(std::ostream &rOStream) const
Print object's data.
Definition: kratos_components.h:403
KratosComponents class encapsulates a lookup table for a family of classes in a generic way.
Definition: kratos_components.h:49
Short class definition.
Definition: optimization_application.h:55
void PrintInfo(std::ostream &rOStream) const override
Print information about this object.
Definition: optimization_application.h:95
KRATOS_CLASS_POINTER_DEFINITION(KratosOptimizationApplication)
Pointer definition of KratosOptimizationApplication.
KratosOptimizationApplication & operator=(KratosOptimizationApplication const &rOther)=delete
~KratosOptimizationApplication() override
Destructor.
Definition: optimization_application.h:71
KratosOptimizationApplication(KratosOptimizationApplication const &rOther)=delete
Copy constructor.
void PrintData(std::ostream &rOStream) const override
Print object's data.
Definition: optimization_application.h:102
std::string Info() const override
Turn back information as a string.
Definition: optimization_application.h:89
#define KRATOS_WATCH(variable)
Definition: define.h:806
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
KRATOS_API_EXTERN template class KratosComponents< Condition >
Definition: condition.h:1191
KRATOS_API_EXTERN template class KratosComponents< Element >
Definition: element.h:1240