|
hp-FEM
Adaptive hp-FEM suite for nano-optics
|
#include <span>#include <type_traits>#include <vector>#include "hpfem/assembly/maxwell_forms.hpp"#include "hpfem/assembly/periodic.hpp"#include "hpfem/core/types.hpp"#include "hpfem/fespace/dof_map.hpp"

Go to the source code of this file.
Classes | |
| struct | hpfem::adaptivity::EstimatorOptions |
| struct | hpfem::adaptivity::ResidualParts |
| Squared contributions of the four residual terms of one cell. More... | |
| struct | hpfem::adaptivity::Estimate |
| Element indicators of one discrete solution. More... | |
Namespaces | |
| namespace | hpfem |
| namespace | hpfem::adaptivity |
Residual-based a-posteriori error estimator for the time-harmonic curl–curl problem \( \nabla\times(\mu^{-1}\nabla\times E) - k^2\varepsilon E = f + \nabla\times g \) on a Nédélec space (Beck, Hiptmair, Hoppe & Wohlmuth 2000; hp weights after Schöberl 2008). Per cell K with diameter h_K and order p_K,
\[ \eta_K^2 = \frac{h_K^2}{p_K^2}\,\|R_K\|^2_{L^2(K)} + \frac{h_K^2}{p_K^2}\,\ell^2\|\nabla\cdot d\|^2_{L^2(K)} + \sum_{F\subset\partial K}\frac{h_F}{2p_F}\Big(\|[\![n\times w]\!]\|^2_{L^2(F)} + \ell^2\|[\![n\cdot d]\!]\|^2_{L^2(F)}\Big), \]
with \( w = \mu^{-1}\nabla\times E_{hp} - g \), \( d = f + k^2\varepsilon E_{hp} \), the element residual \( R_K = d - \nabla\times w \) and the length scale \( \ell = 1/k \) of the Gauss-law terms (EstimatorOptions::length_scale): \( \nabla\cdot d \) carries one inverse length more than \( R_K \), so without \( \ell \) the published form holds only for lengths of order one and the Gauss-law terms dominate SI-scale problems by \( 1/(kh)^2 \). Interior facets (hanging child facets against the cell of their parent) and, with periodic, the Bloch slave facets, whose jump is taken against the phase-shifted master cells (assembly::PeriodicLocator) and credited to both sides; PEC facets carry no residual, natural (PMC) facets are not accounted for. Complex coefficients and PML cells enter through the per-cell form, so the estimator measures the residual of the equation actually solved. Convention exp(-iωt) as everywhere. See docs/theory/error-estimation.md.