include/pops/numerics/elliptic/linear/krylov_solver.hpp File ReferenceΒΆ

adc_cpp: include/pops/numerics/elliptic/linear/krylov_solver.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
krylov_solver.hpp File Reference

TensorKrylovSolver: MATRIX-FREE Krylov solver (BiCGStab) with MG preconditioning, for the FULL-TENSOR elliptic operator L(phi) = -div(A grad phi) + kappa phi, A possibly non-symmetric. More...

+ Include dependency graph for krylov_solver.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  pops::TensorKrylovSolver
 

Namespaces

namespace  pops
 

Detailed Description

TensorKrylovSolver: MATRIX-FREE Krylov solver (BiCGStab) with MG preconditioning, for the FULL-TENSOR elliptic operator L(phi) = -div(A grad phi) + kappa phi, A possibly non-symmetric.

Layer: include/pops/numerics/elliptic/linear. Role: solve the elliptic problem when A is NON-SYMMETRIC (cross term Axy != Ayx, e.g. the rotation B^{-1} arising from a Schur condensation), the case where the GeometricMG V-cycle ALONE (5-point Gauss-Seidel smoother, diagonal block, explicit cross terms) stalls or diverges. BiCGStab (and not GMRES): FIXED memory footprint, no restart. The matvec is apply_laplacian (full operator, strictly matrix-free); the preconditioner is N V-cycles of GeometricMG on the SYMMETRIC PART (diagonal block). Models the EllipticSolver concept. Contract: convention aligned with poisson_operator.hpp – we solve L_int(phi) = rhs with L_int = div(A grad phi) - kappa phi; the case A = I, kappa = 0 recovers the canonical Laplacian and converges to the SAME solution as GeometricMG (to the tolerance).

Invariants / constraints:

  • op and precond MUST be DISTINCT GeometricMG objects (assert in the constructor): apply_precond OVERWRITES precond.rhs()/phi() at every iteration; confusing them would destroy the solve iterate;
  • precond carries the SYMMETRIC part (same eps/eps_y/kappa, set_cross_terms NOT called);
  • DEVICE/MPI: named functors only; the dot products (dot, norm) are COLLECTIVE (all_reduce_sum) and called on ALL ranks, including a rank WITHOUT a box (no deadlock);
  • ADDITIVE: no existing path (GeometricMG / Poisson) goes through this header (opt-in).