37 MFEM_ABORT(
"Currently MFEM + Algoim supports only quads and hexes.");
50 if (vir!=
nullptr) {
return vir;}
53 int np1d=int_order/2+1;
56 LevelSet2D ls(pe,lsvec);
57 auto q = Algoim::quadGen<2>(ls,Algoim::BoundingBox<real_t,2>(0.0,1.0),
62 for (
size_t i=0; i<q.nodes.size(); i++)
65 ip.
Set2w(q.nodes[i].x(0),q.nodes[i].x(1),q.nodes[i].w);
70 LevelSet3D ls(pe,lsvec);
71 auto q = Algoim::quadGen<3>(ls,Algoim::BoundingBox<real_t,3>(0.0,1.0),
76 for (
size_t i=0; i<q.nodes.size(); i++)
79 ip.
Set(q.nodes[i].x(0),q.nodes[i].x(1),q.nodes[i].x(2),q.nodes[i].w);
88 if (sir!=
nullptr) {
return sir;}
90 int np1d=int_order/2+1;
94 LevelSet2D ls(pe,lsvec);
95 auto q = Algoim::quadGen<2>(ls,Algoim::BoundingBox<real_t,2>(0.0,1.0),
100 for (
size_t i=0; i<q.nodes.size(); i++)
103 ip.
Set2w(q.nodes[i].x(0),q.nodes[i].x(1),q.nodes[i].w);
108 LevelSet3D ls(pe,lsvec);
109 auto q = Algoim::quadGen<3>(ls,Algoim::BoundingBox<real_t,3>(0.0,1.0),
114 for (
size_t i=0; i<q.nodes.size(); i++)
117 ip.
Set(q.nodes[i].x(0),q.nodes[i].x(1),q.nodes[i].x(2),q.nodes[i].w);
const IntegrationRule * GetVolumeIntegrationRule()
AlgoimIntegrationRule(int o, const FiniteElement &el, ElementTransformation &trans, const Vector &lsfun)
const IntegrationRule * GetSurfaceIntegrationRule()
Data type dense matrix using column-major storage.
void Mult(const real_t *x, real_t *y) const
Matrix vector multiplication.
Abstract class for all finite elements.
int GetOrder() const
Returns the order of the finite element. In the case of anisotropic orders, returns the maximum order...
int GetDim() const
Returns the reference space dimension for the finite element.
Geometry::Type GetGeomType() const
Returns the Geometry::Type of the reference element.
int GetDof() const
Returns the number of degrees of freedom in the finite element.
Arbitrary order H1 elements in 3D utilizing the Bernstein basis on a cube.
Arbitrary order H1 elements in 2D utilizing the Bernstein basis on a square.
Class for integration point with weight.
void Set(const real_t *p, const int dim)
void Set2w(const real_t x1, const real_t x2, const real_t w)
Class for an integration rule - an Array of IntegrationPoint.
void SetOrder(const int order)
Sets the order of the integration rule. This is only for keeping order information,...
IntegrationPoint & IntPoint(int i)
Returns a reference to the i-th integration point.
virtual void Project(Coefficient &coeff, ElementTransformation &Trans, Vector &dofs) const
Given a coefficient and a transformation, compute its projection (approximation) in the local finite ...
void SetSize(int s)
Resize the vector to size s.
void trans(const Vector &u, Vector &x)