23SamePoint(
const mfem::IntegrationPoint & a,
const mfem::IntegrationPoint & b,
const int dim)
38 mfem::ElementTransformation & T,
39 const mfem::IntegrationPoint & ip)
const
41 const mfem::QuadratureSpaceBase & qspace = *qf.GetSpace();
42 const int el_idx = qspace.GetEntityIndex(T);
47 const mfem::Geometry::Type geom = qspace.GetGeometry(el_idx);
48 const int dim = mfem::Geometry::Dimension[geom];
49 const mfem::IntegrationRule & stored_rule = qspace.GetIntRule(el_idx);
52 if (ip.index < stored_rule.Size() && SamePoint(stored_rule.IntPoint(ip.index), ip,
dim))
58 const int stored_order = qspace.GetOrder();
59 int suggested_order = -1;
64 for (
int order = 0; order <= 2 * stored_order + 64; ++order)
66 const mfem::IntegrationRule & candidate = mfem::IntRules.Get(geom, order);
67 if (ip.index < candidate.Size() && SamePoint(candidate.IntPoint(ip.index), ip,
dim))
69 suggested_order = order;
74 if (suggested_order >= 0)
77 "' stores values on the order-",
81 " points on this element), but it is being evaluated by an integrator using a "
82 "different quadrature rule (",
83 mfem::IntRules.Get(geom, suggested_order).Size(),
84 " points). The stored values are indexed by quadrature point, so the orders must "
85 "match. Set 'order = ",
93 "' stores values on the order-",
95 " quadrature rule, but it is being evaluated by an integrator using a different "
96 "quadrature rule. The stored values are indexed by quadrature point, so the orders "
97 "must match; adjust 'order' on '",
99 "' to match the consuming integrator.");