|
hp-FEM
Adaptive hp-FEM suite for nano-optics
|
#include <span>#include <vector>#include "hpfem/adaptivity/residual_estimator.hpp"#include "hpfem/assembly/conical_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.
Namespaces | |
| namespace | hpfem |
| namespace | hpfem::adaptivity |
Functions | |
| Estimate | hpfem::adaptivity::conical_residual_estimate (const fespace::NedelecDofMap< 2 > &transverse, const fespace::DofMap< 2 > &longitudinal, const Vector &e, const Vector &v, Real beta, Real k_squared, const assembly::ConicalFormFactory &form_of_cell, const EstimatorOptions &options={}, std::span< const assembly::PeriodicPair< 2 > > periodic={}) |
| std::vector< Complex > | hpfem::adaptivity::conical_weighted_residual (const fespace::NedelecDofMap< 2 > &transverse, const fespace::DofMap< 2 > &longitudinal, const Vector &e, const Vector &v, Real beta, Real k_squared, const assembly::ConicalFormFactory &form_of_cell, const fespace::NedelecDofMap< 2 > &weight_transverse, const fespace::DofMap< 2 > &weight_longitudinal, const Vector &weight_e, const Vector &weight_v, const EstimatorOptions &options={}) |
Residual-based a-posteriori error estimator of the conical (2.5D) curl–curl problem (assembly/conical_forms.hpp): the residual of the three-dimensional equation \( \nabla\times(\mu^{-1}\nabla\times E) - k^2\varepsilon E = f \) for the field \( E(x, y)e^{i\beta z} \), so that \( \partial_z = i\beta \). Per cell K of the 2D mesh with diameter h_K and order p_K,
\[ \eta_K^2 = \frac{h_K^2}{p_K^2}\int_K\big(|R_K|^2 + \ell^2|\nabla\cdot d|^2\big)\,dx\,dy + \sum_{F\subset\partial K}\frac{h_F}{2p_F}\int_F\big(|[\![n\times w]\!]|^2 + \ell^2|[\![n\cdot d]\!]|^2\big)\,ds, \]
( \( \ell = 1/k \) the length scale of the Gauss-law terms, EstimatorOptions::length_scale) with \( w = \mu^{-1}\nabla\times E_{hp} \), \( d = f + k^2\varepsilon E_{hp} \) and \( R_K = d - \nabla\times w \) in Cartesian components: for the scaled unknowns \( (E_x, E_y, v = -iE_z) \) the curl of the mode is \( \nabla\times E = (i(\partial_yv -
\beta E_y),\ -i(\partial_xv - \beta E_x),\ \partial_xE_y - \partial_yE_x) \), and for an unscaled vector \( (\nabla\times w)_x = \partial_yw_z - i\beta w_y \), \( (\nabla\times w)_y = i\beta w_x - \partial_xw_z \), \( (\nabla\times w)_z = \partial_xw_y
- \partial_yw_x \), \( \nabla\cdot d = \partial_xd_x + \partial_yd_y + i\beta d_z \). The facet normal lies in the plane, so \( |n\times w|^2 = |w_z|^2 + |n_xw_y - n_yw_x|^2 \) and \( n\cdot d = n_xd_x + n_yd_y \). Interior facets only (hanging child facets against the cell of their parent); PEC facets carry no term, Bloch slave facets (with periodic) the jump against the phase-shifted master cells, credited to both sides. At β = 0 the indicators are those of the in-plane and the E_z block side by side. Convention exp(-iωt). See docs/theory/maxwell.md#conical-incidence-and-the-e_z-polarisation.