OGS
GaussLegendreTet.h
Go to the documentation of this file.
1 
11 #pragma once
12 
13 #include <array>
14 
15 #include "mathlib_export.h"
16 
17 namespace MathLib
18 {
19 
23 template <unsigned ORDER>
25  static MATHLIB_EXPORT const unsigned Order = ORDER;
26  static MATHLIB_EXPORT const unsigned NPoints = ORDER;
27  static MATHLIB_EXPORT const std::array<std::array<double, 3>, NPoints> X;
28  static MATHLIB_EXPORT const double W[NPoints];
29 };
30 
31 template <>
32 struct GaussLegendreTet<2> {
33  static MATHLIB_EXPORT const unsigned Order = 2;
34  static MATHLIB_EXPORT const unsigned NPoints = 5;
35  static MATHLIB_EXPORT const std::array<std::array<double, 3>, NPoints> X;
36  static MATHLIB_EXPORT const double W[NPoints];
37 };
38 
39 template <>
40 struct GaussLegendreTet<3> {
41  static MATHLIB_EXPORT const unsigned Order = 3;
42  static MATHLIB_EXPORT const unsigned NPoints = 14;
43  static MATHLIB_EXPORT const std::array<std::array<double, 3>, NPoints> X;
44  static MATHLIB_EXPORT const double W[NPoints];
45 };
46 
47 #ifndef _MSC_VER // The following explicit instantatiation declaration does not
48  // compile on that particular compiler but is necessary.
49 template <>
50 const std::array<std::array<double, 3>, GaussLegendreTet<1>::NPoints>
52 template <>
53 double const GaussLegendreTet<1>::W[1];
54 #endif
55 } // namespace MathLib
#define MATHLIB_EXPORT
static MATHLIB_EXPORT const std::array< std::array< double, 3 >, NPoints > X
static MATHLIB_EXPORT const std::array< std::array< double, 3 >, NPoints > X
static MATHLIB_EXPORT const unsigned Order
static MATHLIB_EXPORT const unsigned NPoints
static MATHLIB_EXPORT const double W[NPoints]
static MATHLIB_EXPORT const std::array< std::array< double, 3 >, NPoints > X