Rodin::QF module

Module for defining quadrature formulae over reference polytopes.

QuadratureFormula selects persistent reference integration rules by geometry and exactness. GaussLegendre, TensorProduct, and the simplex rule families supply points and weights for element integration and reference-basis tabulation.

\[ \int_{\hat{K}} f(\hat{x}) \, d\hat{x} \approx \sum_{i=1}^n w_i \, f(\hat{x}_i) \]

where $ \hat{K} $ is a reference polytope, $ \hat{x}_i $ are the quadrature points, and $ w_i $ are the associated weights.

Available Quadrature Rules

RuleClassPolytopesExactness
CentroidQF::CentroidAll typesDegree 1 (linear). Single point at barycenter.
Gauss-LegendreQF::GaussLegendreAll typesDegree $ 2n-1 $ for $ n $ points (1D). Tensor-product or Duffy transform for higher dimensions.
Gauss-LobattoQF::GaussLobattoSegmentsDegree $ 2n-3 $ for $ n $ points. Includes endpoints (useful for spectral methods).
Grundmann-MöllerQF::GrundmannMollerSimplices onlyDegree $ 2s+1 $ for parameter $ s \geq 0 $ . Designed specifically for simplicial elements.

Automatic Selection

During assembly, the quadrature order is automatically chosen based on the polynomial degree of the finite element space and the integrands. Users can also specify a quadrature rule explicitly:

QF::GaussLegendre qf(Polytope::Type::Triangle, 5); // order 5 on triangles

Higher-Dimensional Construction

  • Tensor-product geometries (quadrilaterals, hexahedra): constructed via tensor products of 1D Gauss-Legendre rules.
  • Simplicial geometries (triangles, tetrahedra): the Duffy transformation maps tensor-product rules to the simplex, or Grundmann-Möller rules are used natively.

Rodin provides quadrature rules for all supported polytope types (segments, triangles, quadrilaterals, tetrahedra, hexahedra, wedges).

Classes

class Centroid
Single-point centroid quadrature formula.
class GaussLegendre
Gauss-Legendre quadrature formula on reference polytopes.
class GaussLobatto
Gauss-Lobatto quadrature formula on reference polytopes.
class GrundmannMoller
Grundmann-Möller simplex quadrature formula.
class QuadratureFormulaBase
Read-only access to reference quadrature points and weights.
class QuadratureFormula
Persistent immutable reference quadrature points and weights.
class TensorProduct
Cartesian product of two quadrature formulae.
class WitherdenVincent
Fully symmetric positive interior quadrature.
class XiaoGimbutas
Near-minimal positive interior quadrature on simplices.