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.
pyramid_gauss_legendre_integration_points.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 authors: Philipp Bucher (https://github.com/philbucher)
11 // Ashish Darekar
12 //
13 // Reference: (https://github.com/nschloe/quadpy/blob/main/src/quadpy/p3/_felippa.py)
14 
15 #if !defined (KRATOS_PYRAMID_GAUSS_LEGENDRE_INTEGRATION_POINTS_H_INCLUDED)
16 #define KRATOS_PYRAMID_GAUSS_LEGENDRE_INTEGRATION_POINTS_H_INCLUDED
17 
18 // System includes
19 
20 // External includes
21 
22 // Project includes
23 #include "integration/quadrature.h"
24 
25 
26 namespace Kratos {
27 
29 {
30 public:
32  typedef std::size_t SizeType;
33 
34  static const unsigned int Dimension = 3;
35 
37 
38  typedef std::array<IntegrationPointType, 1> IntegrationPointsArrayType;
39 
41 
43  {
44  return 1;
45  }
46 
48  {
49  static const IntegrationPointsArrayType s_integration_points{{
50  IntegrationPointType( 0.0 , 0.0 , -0.5 , 4.7407407407407405 )
51  }};
52  return s_integration_points;
53  }
54 
55  std::string Info() const
56  {
57  std::stringstream buffer;
58  buffer << "Pyramid Gauss-Legendre quadrature 1 ";
59  return buffer.str();
60  }
61 
62 }; // Class PyramidGaussLegendreIntegrationPoints1
63 
65 {
66 public:
68  typedef std::size_t SizeType;
69 
70  static const unsigned int Dimension = 3;
71 
73 
74  typedef std::array<IntegrationPointType, 5> IntegrationPointsArrayType;
75 
77 
79  {
80  return 5;
81  }
82 
84  {
85  static const IntegrationPointsArrayType s_integration_points{{
86  IntegrationPointType( 0.5842373946721772 , 0.5842373946721772 , -0.6666666666666666 , 0.81 ),
87  IntegrationPointType( -0.5842373946721772 , 0.5842373946721772 , -0.6666666666666666 , 0.81 ),
88  IntegrationPointType( 0.5842373946721772 , -0.5842373946721772 , -0.6666666666666666 , 0.81 ),
89  IntegrationPointType( -0.5842373946721772 , -0.5842373946721772 , -0.6666666666666666 , 0.81 ),
90  IntegrationPointType( 0.0 , 0.0 , 0.4 , 4.62962962962963 )
91  }};
92  return s_integration_points;
93  }
94 
95  std::string Info() const
96  {
97  std::stringstream buffer;
98  buffer << "Pyramid Gauss-Legendre quadrature 2 ";
99  return buffer.str();
100  }
101 
102 }; // Class PyramidGaussLegendreIntegrationPoints2
103 
105 {
106 public:
108  typedef std::size_t SizeType;
109 
110  static const unsigned int Dimension = 3;
111 
113 
114  typedef std::array<IntegrationPointType, 8> IntegrationPointsArrayType;
115 
117 
119  {
120  return 8;
121  }
122 
124  {
125  static const IntegrationPointsArrayType s_integration_points{{
126  IntegrationPointType( 0.5773502691896257 , 0.5773502691896257 , 0.08830368802245057 , 0.9700392164449294 ),
127  IntegrationPointType( -0.5773502691896257 , 0.5773502691896257 , 0.08830368802245057 , 0.9700392164449294 ),
128  IntegrationPointType( 0.5773502691896257 , -0.5773502691896257 , 0.08830368802245057 , 0.9700392164449294 ),
129  IntegrationPointType( -0.5773502691896257 , -0.5773502691896257 , 0.08830368802245057 , 0.9700392164449294 ),
130  IntegrationPointType( 0.5773502691896257 , 0.5773502691896257 , -0.7549703546891172 , 0.6040348576291448 ),
131  IntegrationPointType( -0.5773502691896257 , 0.5773502691896257 , -0.7549703546891172 , 0.6040348576291448 ),
132  IntegrationPointType( 0.5773502691896257 , -0.5773502691896257 , -0.7549703546891172 , 0.6040348576291448 ),
133  IntegrationPointType( -0.5773502691896257 , -0.5773502691896257 , -0.7549703546891172 , 0.6040348576291448 )
134  }};
135  return s_integration_points;
136  }
137 
138  std::string Info() const
139  {
140  std::stringstream buffer;
141  buffer << "Pyramid Gauss-Legendre quadrature 3 ";
142  return buffer.str();
143  }
144 
145 }; // Class PyramidGaussLegendreIntegrationPoints3
146 
148 {
149 public:
151  typedef std::size_t SizeType;
152 
153  static const unsigned int Dimension = 3;
154 
156 
157  typedef std::array<IntegrationPointType, 18> IntegrationPointsArrayType;
158 
160 
162  {
163  return 18;
164  }
165 
167  {
168  static const IntegrationPointsArrayType s_integration_points{{
169  IntegrationPointType( 0.7745966692414834 , 0.7745966692414834 , 0.08830368802245057 , 0.2993948198904103 ),
170  IntegrationPointType( -0.7745966692414834 , 0.7745966692414834 , 0.08830368802245057 , 0.2993948198904103 ),
171  IntegrationPointType( 0.7745966692414834 , -0.7745966692414834 , 0.08830368802245057 , 0.2993948198904103 ),
172  IntegrationPointType( -0.7745966692414834 , -0.7745966692414834 , 0.08830368802245057 , 0.2993948198904103 ),
173  IntegrationPointType( 0.7745966692414834 , 0.0 , 0.08830368802245057 , 0.4790317118246565 ),
174  IntegrationPointType( -0.7745966692414834 , 0.0 , 0.08830368802245057 , 0.4790317118246565 ),
175  IntegrationPointType( 0.0 , 0.7745966692414834 , 0.08830368802245057 , 0.4790317118246565 ),
176  IntegrationPointType( 0.0 , -0.7745966692414834 , 0.08830368802245057 , 0.4790317118246565 ),
177  IntegrationPointType( 0.0 , 0.0 , 0.08830368802245057 , 0.7664507389194504 ),
178  IntegrationPointType( 0.7745966692414834 , 0.7745966692414834 , -0.7549703546891172 , 0.18643051161393356 ),
179  IntegrationPointType( -0.7745966692414834 , 0.7745966692414834 , -0.7549703546891172 , 0.18643051161393356 ),
180  IntegrationPointType( 0.7745966692414834 , -0.7745966692414834 , -0.7549703546891172 , 0.18643051161393356 ),
181  IntegrationPointType( -0.7745966692414834 , -0.7745966692414834 , -0.7549703546891172 , 0.18643051161393356 ),
182  IntegrationPointType( 0.7745966692414834 , 0.0 , -0.7549703546891172 , 0.29828881858229367 ),
183  IntegrationPointType( -0.7745966692414834 , 0.0 , -0.7549703546891172 , 0.29828881858229367 ),
184  IntegrationPointType( 0.0 , 0.7745966692414834 , -0.7549703546891172 , 0.29828881858229367 ),
185  IntegrationPointType( 0.0 , -0.7745966692414834 , -0.7549703546891172 , 0.29828881858229367 ),
186  IntegrationPointType( 0.0 , 0.0 , -0.7549703546891172 , 0.4772621097316699 )
187  }};
188  return s_integration_points;
189  }
190 
191  std::string Info() const
192  {
193  std::stringstream buffer;
194  buffer << "Pyramid Gauss-Legendre quadrature 4 ";
195  return buffer.str();
196  }
197 
198 }; // Class PyramidGaussLegendreIntegrationPoints4
199 
201 {
202 public:
204  typedef std::size_t SizeType;
205 
206  static const unsigned int Dimension = 3;
207 
209 
210  typedef std::array<IntegrationPointType, 27> IntegrationPointsArrayType;
211 
213 
215  {
216  return 27;
217  }
218 
220  {
221  static const IntegrationPointsArrayType s_integration_points{{
222  IntegrationPointType( 0.7745966692414834 , 0.7745966692414834 , -0.8540119518537005 , 0.11287470009663707 ),
223  IntegrationPointType( -0.7745966692414834 , 0.7745966692414834 , -0.8540119518537005 , 0.11287470009663707 ),
224  IntegrationPointType( 0.7745966692414834 , -0.7745966692414834 , -0.8540119518537005 , 0.11287470009663707 ),
225  IntegrationPointType( -0.7745966692414834 , -0.7745966692414834 , -0.8540119518537005 , 0.11287470009663707 ),
226  IntegrationPointType( 0.7745966692414834 , 0.0 , -0.8540119518537005 , 0.1805995201546193 ),
227  IntegrationPointType( -0.7745966692414834 , 0.0 , -0.8540119518537005 , 0.1805995201546193 ),
228  IntegrationPointType( 0.0 , 0.7745966692414834 , -0.8540119518537005 , 0.1805995201546193 ),
229  IntegrationPointType( 0.0 , -0.7745966692414834 , -0.8540119518537005 , 0.1805995201546193 ),
230  IntegrationPointType( 0.0 , 0.0 , -0.8540119518537005 , 0.2889592322473909 ),
231  IntegrationPointType( 0.7745966692414834 , 0.7745966692414834 , -0.3059924679232962 , 0.211713439795844 ),
232  IntegrationPointType( -0.7745966692414834 , 0.7745966692414834 , -0.3059924679232962 , 0.211713439795844 ),
233  IntegrationPointType( 0.7745966692414834 , -0.7745966692414834 , -0.3059924679232962 , 0.211713439795844 ),
234  IntegrationPointType( -0.7745966692414834 , -0.7745966692414834 , -0.3059924679232962 , 0.211713439795844 ),
235  IntegrationPointType( 0.7745966692414834 , 0.0 , -0.3059924679232962 , 0.33874150367335043 ),
236  IntegrationPointType( -0.7745966692414834 , 0.0 , -0.3059924679232962 , 0.33874150367335043 ),
237  IntegrationPointType( 0.0 , 0.7745966692414834 , -0.3059924679232962 , 0.33874150367335043 ),
238  IntegrationPointType( 0.0 , -0.7745966692414834 , -0.3059924679232962 , 0.33874150367335043 ),
239  IntegrationPointType( 0.0 , 0.0 , -0.3059924679232962 , 0.5419864058773607 ),
240  IntegrationPointType( 0.7745966692414834 , 0.7745966692414834 , 0.41000441977699675 , 0.21244889714455584 ),
241  IntegrationPointType( -0.7745966692414834 , 0.7745966692414834 , 0.41000441977699675 , 0.21244889714455584 ),
242  IntegrationPointType( 0.7745966692414834 , -0.7745966692414834 , 0.41000441977699675 , 0.21244889714455584 ),
243  IntegrationPointType( -0.7745966692414834 , -0.7745966692414834 , 0.41000441977699675 , 0.21244889714455584 ),
244  IntegrationPointType( 0.7745966692414834 , 0.0 , 0.41000441977699675 , 0.33991823543128935 ),
245  IntegrationPointType( -0.7745966692414834 , 0.0 , 0.41000441977699675 , 0.33991823543128935 ),
246  IntegrationPointType( 0.0 , 0.7745966692414834 , 0.41000441977699675 , 0.33991823543128935 ),
247  IntegrationPointType( 0.0 , -0.7745966692414834 , 0.41000441977699675 , 0.33991823543128935 ),
248  IntegrationPointType( 0.0 , 0.0 , 0.41000441977699675 , 0.543869176690063 )
249  }};
250  return s_integration_points;
251  }
252 
253  std::string Info() const
254  {
255  std::stringstream buffer;
256  buffer << "Pyramid Gauss-Legendre quadrature 5 ";
257  return buffer.str();
258  }
259 
260 }; // Class PyramidGaussLegendreIntegrationPoints5
261 
262 } // namespace Kratos.
263 
264 #endif // KRATOS_PYRAMID_GAUSS_LEGENDRE_INTEGRATION_POINTS_H_INCLUDED defined
Short class definition.
Definition: integration_point.h:52
Point class.
Definition: point.h:59
Definition: pyramid_gauss_legendre_integration_points.h:29
std::size_t SizeType
Definition: pyramid_gauss_legendre_integration_points.h:32
std::string Info() const
Definition: pyramid_gauss_legendre_integration_points.h:55
static const unsigned int Dimension
Definition: pyramid_gauss_legendre_integration_points.h:34
IntegrationPointType::PointType PointType
Definition: pyramid_gauss_legendre_integration_points.h:40
IntegrationPoint< 3 > IntegrationPointType
Definition: pyramid_gauss_legendre_integration_points.h:36
KRATOS_CLASS_POINTER_DEFINITION(PyramidGaussLegendreIntegrationPoints1)
static SizeType IntegrationPointsNumber()
Definition: pyramid_gauss_legendre_integration_points.h:42
std::array< IntegrationPointType, 1 > IntegrationPointsArrayType
Definition: pyramid_gauss_legendre_integration_points.h:38
static const IntegrationPointsArrayType & IntegrationPoints()
Definition: pyramid_gauss_legendre_integration_points.h:47
Definition: pyramid_gauss_legendre_integration_points.h:65
static SizeType IntegrationPointsNumber()
Definition: pyramid_gauss_legendre_integration_points.h:78
std::array< IntegrationPointType, 5 > IntegrationPointsArrayType
Definition: pyramid_gauss_legendre_integration_points.h:74
IntegrationPoint< 3 > IntegrationPointType
Definition: pyramid_gauss_legendre_integration_points.h:72
std::string Info() const
Definition: pyramid_gauss_legendre_integration_points.h:95
static const unsigned int Dimension
Definition: pyramid_gauss_legendre_integration_points.h:70
KRATOS_CLASS_POINTER_DEFINITION(PyramidGaussLegendreIntegrationPoints2)
std::size_t SizeType
Definition: pyramid_gauss_legendre_integration_points.h:68
static const IntegrationPointsArrayType & IntegrationPoints()
Definition: pyramid_gauss_legendre_integration_points.h:83
IntegrationPointType::PointType PointType
Definition: pyramid_gauss_legendre_integration_points.h:76
Definition: pyramid_gauss_legendre_integration_points.h:105
std::size_t SizeType
Definition: pyramid_gauss_legendre_integration_points.h:108
KRATOS_CLASS_POINTER_DEFINITION(PyramidGaussLegendreIntegrationPoints3)
static const unsigned int Dimension
Definition: pyramid_gauss_legendre_integration_points.h:110
IntegrationPointType::PointType PointType
Definition: pyramid_gauss_legendre_integration_points.h:116
std::array< IntegrationPointType, 8 > IntegrationPointsArrayType
Definition: pyramid_gauss_legendre_integration_points.h:114
static const IntegrationPointsArrayType & IntegrationPoints()
Definition: pyramid_gauss_legendre_integration_points.h:123
static SizeType IntegrationPointsNumber()
Definition: pyramid_gauss_legendre_integration_points.h:118
std::string Info() const
Definition: pyramid_gauss_legendre_integration_points.h:138
IntegrationPoint< 3 > IntegrationPointType
Definition: pyramid_gauss_legendre_integration_points.h:112
Definition: pyramid_gauss_legendre_integration_points.h:148
IntegrationPointType::PointType PointType
Definition: pyramid_gauss_legendre_integration_points.h:159
std::string Info() const
Definition: pyramid_gauss_legendre_integration_points.h:191
std::size_t SizeType
Definition: pyramid_gauss_legendre_integration_points.h:151
static SizeType IntegrationPointsNumber()
Definition: pyramid_gauss_legendre_integration_points.h:161
static const IntegrationPointsArrayType & IntegrationPoints()
Definition: pyramid_gauss_legendre_integration_points.h:166
IntegrationPoint< 3 > IntegrationPointType
Definition: pyramid_gauss_legendre_integration_points.h:155
static const unsigned int Dimension
Definition: pyramid_gauss_legendre_integration_points.h:153
KRATOS_CLASS_POINTER_DEFINITION(PyramidGaussLegendreIntegrationPoints4)
std::array< IntegrationPointType, 18 > IntegrationPointsArrayType
Definition: pyramid_gauss_legendre_integration_points.h:157
Definition: pyramid_gauss_legendre_integration_points.h:201
IntegrationPoint< 3 > IntegrationPointType
Definition: pyramid_gauss_legendre_integration_points.h:208
std::size_t SizeType
Definition: pyramid_gauss_legendre_integration_points.h:204
IntegrationPointType::PointType PointType
Definition: pyramid_gauss_legendre_integration_points.h:212
std::string Info() const
Definition: pyramid_gauss_legendre_integration_points.h:253
static const unsigned int Dimension
Definition: pyramid_gauss_legendre_integration_points.h:206
KRATOS_CLASS_POINTER_DEFINITION(PyramidGaussLegendreIntegrationPoints5)
static const IntegrationPointsArrayType & IntegrationPoints()
Definition: pyramid_gauss_legendre_integration_points.h:219
static SizeType IntegrationPointsNumber()
Definition: pyramid_gauss_legendre_integration_points.h:214
std::array< IntegrationPointType, 27 > IntegrationPointsArrayType
Definition: pyramid_gauss_legendre_integration_points.h:210
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21