DFT-EFE
 
Loading...
Searching...
No Matches
QuadratureRule.h
Go to the documentation of this file.
1#ifndef dftefeQuadratureRule_h
2#define dftefeQuadratureRule_h
3
4#include <utils/Point.h>
5#include <utils/TypeConfig.h>
6#include <vector>
7
8namespace dftefe
9{
10 namespace quadrature
11 {
12 /*
13 *Class that stores the quadrature information. This class provides the
14 *location of the quadrature points in parametric coordinates and its
15 *corresponding weights
16 */
18 {
19 public:
20 virtual ~QuadratureRule() = default;
21
30 const std::vector<utils::Point> &points,
31 const std::vector<double> & weights);
32
38 virtual const std::vector<utils::Point> &
39 getPoints() const;
40
48 virtual const std::vector<utils::Point> &
49 get1DPoints() const;
50
56 virtual const std::vector<double> &
57 getWeights() const;
65 virtual const std::vector<double> &
66 get1DWeights() const;
67
68 virtual bool
69 isTensorStructured() const;
70
71 virtual size_type
72 nPoints() const;
73
74 virtual size_type
75 n1DPoints() const;
76
77 virtual size_type
78 getDim() const;
79
80 protected:
82
86 std::vector<utils::Point> d_points;
87 std::vector<utils::Point> d_1DPoints;
88 std::vector<double> d_weights;
89 std::vector<double> d_1DWeights;
91 };
92
93 } // end of namespace quadrature
94
95} // end of namespace dftefe
96
97#endif // dftefeQuadratureRule_h
Definition: QuadratureRule.h:18
virtual size_type n1DPoints() const
Definition: QuadratureRule.cpp:83
virtual size_type getDim() const
Definition: QuadratureRule.cpp:89
std::vector< double > d_1DWeights
Definition: QuadratureRule.h:89
size_type d_dim
Definition: QuadratureRule.h:83
QuadratureRule(const size_type dim, const std::vector< utils::Point > &points, const std::vector< double > &weights)
Constructor to create a tensor structured quadrature with arbitrary 1D points and weights.
size_type d_num1DPoints
Definition: QuadratureRule.h:85
size_type d_numPoints
Definition: QuadratureRule.h:84
std::vector< utils::Point > d_points
Definition: QuadratureRule.h:86
std::vector< utils::Point > d_1DPoints
Definition: QuadratureRule.h:87
bool d_isTensorStructured
Definition: QuadratureRule.h:90
virtual const std::vector< double > & getWeights() const
A function to returns the weights of the quadrature points.
Definition: QuadratureRule.cpp:51
virtual const std::vector< utils::Point > & getPoints() const
A function to return the quad points in the parametric space.
Definition: QuadratureRule.cpp:32
virtual size_type nPoints() const
Definition: QuadratureRule.cpp:77
virtual const std::vector< utils::Point > & get1DPoints() const
A function to return the 1D quad points in the parametric space. This function throws an error if thi...
Definition: QuadratureRule.cpp:38
virtual const std::vector< double > & get1DWeights() const
A function to return the 1D quad points in the parametric space. This function throws an error if thi...
Definition: QuadratureRule.cpp:57
virtual bool isTensorStructured() const
Definition: QuadratureRule.cpp:71
std::vector< double > d_weights
Definition: QuadratureRule.h:88
QuadratureRule()
Definition: QuadratureRule.cpp:8
dealii includes
Definition: AtomFieldDataSpherical.cpp:31
unsigned int size_type
Definition: TypeConfig.h:8