19 #ifndef EVAL_POINTS_HH_
20 #define EVAL_POINTS_HH_
54 class EvalPoints :
public std::enable_shared_from_this<EvalPoints> {
69 inline unsigned int size(
unsigned int dim)
const {
74 template<
unsigned int dim>
75 inline arma::vec::fixed<dim>
local_point(
unsigned int local_point_idx)
const {
76 ASSERT_GT(dim, 0).error(
"Dimension 0 not supported!\n");
81 inline int subset_begin(
unsigned int dim,
unsigned int idx)
const {
86 inline int subset_end(
unsigned int dim,
unsigned int idx)
const {
91 inline int subset_size(
unsigned int dim,
unsigned int idx)
const {
96 inline unsigned int n_subsets(
unsigned int dim)
const {
105 template <
unsigned int dim>
109 template <
unsigned int dim>
118 for (
uint i=0; i<4; ++i)
136 inline unsigned int size()
const {
142 template<
unsigned int dim>
143 inline arma::vec::fixed<dim>
local_point(
unsigned int local_point_idx)
const {
172 template <
unsigned int dim>
196 template<
class Integral>
#define ASSERT_LT(a, b)
Definition of comparative assert macro (Less Than) only for debug mode.
#define ASSERT_GT(a, b)
Definition of comparative assert macro (Greater Than) only for debug mode.
ArmaVec< Type, nr > vec(uint mat_index) const
unsigned int size() const
Directing class of FieldValueCache.
Subobject holds evaluation points data of one dimension (0,1,2,3)
unsigned int n_subsets_
Number of subset.
int subset_begin(unsigned int idx) const
Return begin index of appropriate subset data.
std::array< int, EvalPoints::max_subsets+1 > subset_starts_
Indices of subsets data in local_points_ vector, used size is n_subsets_ + 1.
unsigned int size() const
Return size of evaluation points object (number of points).
arma::vec::fixed< dim > local_point(unsigned int local_point_idx) const
Return local coordinates of given local point.
DimEvalPoints(unsigned int dim)
Constructor.
unsigned int n_subsets() const
Return number of subsets.
uint add_subset()
Adds new subset and its end size to subset_starts_ array.
unsigned int dim_
Dimension of local points.
int subset_end(unsigned int idx) const
Return end index of appropriate subset data.
Armor::Array< double > local_points_
Local coords of points vector.
void add_local_points(const Armor::Array< double > &quad_points)
Adds set of local point to local_points_ (bulk or side).
int subset_size(unsigned int idx) const
Return number of local points corresponding to subset.
Class holds local coordinations of evaluating points (bulk and sides) specified by element dimension.
int subset_begin(unsigned int dim, unsigned int idx) const
Return begin index of appropriate subset data.
static const unsigned int undefined_dim
Undefined dimension of new (empty) object.
unsigned int n_subsets(unsigned int dim) const
Return number of subsets.
unsigned int size(unsigned int dim) const
Return size of evaluation points object (number of points).
std::shared_ptr< internal_integrals::Edge > add_edge_internal(Quadrature *)
The same as add_bulk but for edge points on sides.
unsigned int max_size() const
Return maximal size of evaluation points objects.
int subset_end(unsigned int dim, unsigned int idx) const
Return end index of appropriate subset data.
std::shared_ptr< internal_integrals::Bulk > add_bulk_internal(Quadrature *)
unsigned int max_size_
Maximal number of used EvalPoints.
static const unsigned int max_subset_points
Maximal average number of points hold in subset.
uint get_max_integral_quad_size(IntegralPtrMap< Integral > integrals, unsigned int dim) const
Common implementation of get_max_bulk_quad_size and get_max_side_quad_size.
IntegralPtrMap< internal_integrals::Bulk > bulk_integrals_
Maps of all BulkIntegrals of dimensions 0,1,2,3.
uint get_max_bulk_quad_size(unsigned int dim) const
Return maximal size of quadrature of given dimension of bulk integral (Bulk, Coupling /lower-dim/)
int subset_size(unsigned int dim, unsigned int idx) const
Return number of local points corresponding to subset.
IntegralPtrMap< internal_integrals::Edge > edge_integrals_
Maps of all EdgeIntegrals of dimensions 1,2,3.
std::array< DimEvalPoints, 4 > dim_eval_points_
Sub objects of dimensions 0,1,2,3.
static constexpr unsigned int max_subsets
Maximal number of hold subsets.
arma::vec::fixed< dim > local_point(unsigned int local_point_idx) const
Return local coordinates of given local point and appropriate dim.
uint get_max_side_quad_size(unsigned int dim) const
Return maximal size of quadrature of given dimension of side integral (Edge, Coupling /higher-dim/,...
Base class for quadrature rules on simplices in arbitrary dimensions.
std::unordered_map< std::tuple< uint, uint >, std::shared_ptr< Integral >, IntegralTplHash > IntegralPtrMap
Alias for unordered_map of shared_ptr<Integral> with custom hash.
Implementation of range helper class.