include/pops/numerics/elliptic/interface/elliptic_problem.hpp File ReferenceΒΆ
|
adc_cpp 0.3.0
Model-free C++23 core for coupled hyperbolic-elliptic systems on adaptive (AMR) meshes, with MPI and GPU (Kokkos) backends
|
DESCRIPTIVE types of the elliptic stage: EllipticProblem (problem definition) and FieldPostProcess (field derivation convention), plus additive factories. More...
#include <pops/core/foundation/types.hpp>#include <pops/numerics/elliptic/mg/geometric_mg.hpp>#include <pops/mesh/layout/box_array.hpp>#include <pops/mesh/geometry/geometry.hpp>#include <pops/mesh/storage/multifab.hpp>#include <pops/mesh/boundary/physical_bc.hpp>#include <stdexcept>#include <utility>
Include dependency graph for elliptic_problem.hpp:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Classes | |
| struct | pops::EllipticProblem |
| struct | pops::FieldPostProcess |
| struct | pops::detail::FieldPostprocessKernel |
Namespaces | |
| namespace | pops |
| namespace | pops::detail |
Functions | |
| BCRec | pops::homogeneous_bc (const EllipticProblem &p) |
| template<class Solver , class... Args> | |
| Solver | pops::make_elliptic_solver (const Geometry &geom, const BoxArray &ba, const EllipticProblem &problem, Args &&... args) |
| void | pops::field_postprocess (const MultiFab &phi, MultiFab &out, Real cx, Real cy, FieldPostProcess spec) |
Detailed Description
DESCRIPTIVE types of the elliptic stage: EllipticProblem (problem definition) and FieldPostProcess (field derivation convention), plus additive factories.
Layer: include/pops/numerics/elliptic/interface. Role: NAME values and conventions ALREADY coded, without modifying a single floating-point operation (bit-identical structural refactor). EllipticProblem gathers what defines lap(eps phi) = f solved by GeometricMG/PoissonFFTSolver (coefficient eps, physical BCRec, nullspace_const flag). FieldPostProcess names the derivation E = -grad phi and the sign convention (GradSign::Plus for the coupler that stores +grad phi, Minus for a consumer storing -grad phi). Contract: make_elliptic_solver(geom, ba, problem, ...) builds an EllipticSolver from a named EllipticProblem; field_postprocess(phi, out, cx, cy, spec) writes out = (phi if requested, s*grad phi centered) with s = +/-1 per the spec, cx = 1/(2 dx), cy = 1/(2 dy).
Invariants:
- eps is PURELY DESCRIPTIVE: the 5-point stencil does not read it (eps = 1 implicit); eps != 1 raises std::invalid_argument in make_elliptic_solver (forbidden trap, not silently ignored);
- field_postprocess reproduces detail::coupler_grad_phi character for character (same order, same factors *cx / *cy): only the sign s is a degree of freedom;
- FieldPostprocessKernel is a NAMED functor (and not an POPS_HD lambda) because it is first instantiated from an external TU: an extended lambda would break the device kernel emission under nvcc.
Generated by