WARPXM v1.10.0
Loading...
Searching...
No Matches
wmquadraturesystem.h
Go to the documentation of this file.
1
2#ifndef WMQUADRATURESYSTEM_H_
3#define WMQUADRATURESYSTEM_H_
4
5// STD includes
6#include <iostream>
7#include <iomanip>
8#include <vector>
9#include <numeric>
10
11// WarpX includes
12#include "lib/wxlogger.h"
13#include "lib/wxlogstream.h"
14
15template<typename T> class WmQuadratureSystem
16{
17public:
18 WmQuadratureSystem(); // const unsigned numQuadPoints);
19
21
22 // void generateQuadraturePoints();
23 static void generateQuadraturePoints(int numPoints, T* weights, T* points);
24
25 // // returns the weight (includes Jacobian determinant) - works for 1D, 2D, and 3D
26 // T getQuadraturePosition(const std::vector<std::vector<T> > & nodePositions, const
27 //T * centroid, const int * indices, const unsigned integralType, T * quadPosition);
28 // void getQuadratureComponents(const std::vector<std::vector<T> > & nodePositions,
29 //const T * A, const unsigned integralType, std::vector<std::vector<T> > &
30 //quadPositions, std::vector<T> & quadModifiers);
31
32 // static void generateQuadratureSystem(int primitiveID, const
33 // std::vector<std::vector<T> > & nodePositions, std::vector<std::vector<T> > &
34 // quadratureSystem); static void generateQuadratureJacobian(int primitiveID, const
35 // std::vector<std::vector<T> > & quadratureSystem, std::vector<T> &
36 // quadratureJacobian);
37
38 // This is a modification I'm going to try out for triangles and tetrahedra
39 // nodePositions[3*_numNodesPerElement]
40 // weights[_numQuadPoints]
41 // positions[3*_numQuadPoints]
42 static int getNumQuadraturePoints(const int primitiveID, const int polynomialOrder);
43 static void generateQuadratureSystem(const int primitiveID,
44 const int polynomialOrder,
45 const T* nodePositions,
46 T* weights,
47 T* positions);
48 static void generateNormalizedQuadratureSystem(const int primitiveID,
49 const int polynomialOrder,
50 T* weights,
51 T* positions);
52
53 // unsigned getNumQuadraturePoints(){return _numQuadPoints;}
54
55 // std::string getQuadratureString();
56
57 // T getQuadraturePoint(unsigned i) const;
58 // T getQuadratureWeight(unsigned i) const;
59
60protected:
61 // std::vector<T> _quadPoints;
62 // std::vector<T> _quadWeights;
63
64 // unsigned _numQuadPoints;
65
66 // Triangles and Tetrahedra are a bit more complicated
67 // We will use a symmetric simplex quadrature system for that
68
69private:
70};
71
72extern template class WmQuadratureSystem<real>;
73
74#endif // WMQUADRATURESYSTEM_H_
Definition: wmquadraturesystem.h:16
static void generateNormalizedQuadratureSystem(const int primitiveID, const int polynomialOrder, T *weights, T *positions)
static int getNumQuadraturePoints(const int primitiveID, const int polynomialOrder)
static void generateQuadraturePoints(int numPoints, T *weights, T *points)
static void generateQuadratureSystem(const int primitiveID, const int polynomialOrder, const T *nodePositions, T *weights, T *positions)