18#ifndef LINE_QUAD_BASE_H
19#define LINE_QUAD_BASE_H
32const uint8_t LINE_DEFAULT_ORDER = 10;
33const uint8_t LINE_MAX_ORDER = 30;
48 static_assert((
dim == 1 ||
dim == 2 ||
dim == 3),
"`dim` must be 1, 2, or 3.");
85 if (!points_weights_computed_)
86 throw std::runtime_error(
87 "LineQuadratureBase::points(): must call `compute_points_weights()` first.");
98 if (!points_weights_computed_)
99 throw std::runtime_error(
100 "LineQuadratureBase::weights(): must call `compute_points_weights()` first.");
110 uint8_t order_ = LINE_DEFAULT_ORDER;
111 bool points_weights_computed_ =
false;
Base class for quadrature over a line segment.
uint8_t order() const
Returns the quadrature order.
const EigMatNX< Float, dim > & points() const
Returns the points on which to evaluate the integrand.
virtual void set_order(const uint8_t order)
Sets the quadrature order.
virtual void compute_points_weights(ConstEigRef< EigColVecN< Float, dim > > p1, ConstEigRef< EigColVecN< Float, dim > > p2, std::function< EigRowVec< Complex >(ConstEigRef< EigMatNX< Float, dim > >)> eval={})=0
Computes and stores the points on which to evaluate the integrand, and the corresponding weights.
const EigRowVec< Float > & weights() const
Returns the weights associated with the points on which the integrand is evaluated.
const Eigen::Ref< const EigObj > ConstEigRef
Read-only reference to an Eigen object.
Eigen::Matrix< T, N, 1 > EigColVecN
Fixed-size column vector of size N containing type T.
Primary namespace for the OpenBEM library.