OpenSWMM Engine  6.0.0-alpha.1
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.1)
Loading...
Searching...
No Matches
openswmm::twoD::gpu::KokkosAmgPreconditioner Class Reference

BoomerAMG preconditioner over the Kokkos surface Newton matrix. More...

#include <KokkosAmgPreconditioner.hpp>

Collaboration diagram for openswmm::twoD::gpu::KokkosAmgPreconditioner:

Public Member Functions

 KokkosAmgPreconditioner ()=default
 
 ~KokkosAmgPreconditioner ()
 
 KokkosAmgPreconditioner (const KokkosAmgPreconditioner &)=delete
 
KokkosAmgPreconditioneroperator= (const KokkosAmgPreconditioner &)=delete
 
void initialize (const MeshViews &mesh)
 
void setup (const MeshViews &mesh, const StateViews &state, double gamma, bool recompute)
 
void solve (DView r, DView z, double gamma)
 Apply one BoomerAMG V-cycle: z ≈ M⁻¹ r (Views in the plugin's MemSpace).
 
void finalize ()
 
bool ready () const noexcept
 
void invalidate () noexcept
 

Detailed Description

BoomerAMG preconditioner over the Kokkos surface Newton matrix.

Lives entirely in the plugin's ExecSpace/MemSpace. Construct once, then per CVODE psetup call setup(), per psolve call solve().

Constructor & Destructor Documentation

◆ KokkosAmgPreconditioner() [1/2]

openswmm::twoD::gpu::KokkosAmgPreconditioner::KokkosAmgPreconditioner ( )
default
Here is the caller graph for this function:

◆ ~KokkosAmgPreconditioner()

openswmm::twoD::gpu::KokkosAmgPreconditioner::~KokkosAmgPreconditioner ( )
Here is the call graph for this function:

◆ KokkosAmgPreconditioner() [2/2]

openswmm::twoD::gpu::KokkosAmgPreconditioner::KokkosAmgPreconditioner ( const KokkosAmgPreconditioner & )
delete
Here is the call graph for this function:

Member Function Documentation

◆ finalize()

void openswmm::twoD::gpu::KokkosAmgPreconditioner::finalize ( )
Here is the caller graph for this function:

◆ initialize()

void openswmm::twoD::gpu::KokkosAmgPreconditioner::initialize ( const MeshViews & mesh)

Build static CSR sparsity from the mesh topology + allocate hypre objects in the active memory location. Call once per solver initialize().

Here is the call graph for this function:

◆ invalidate()

void openswmm::twoD::gpu::KokkosAmgPreconditioner::invalidate ( )
inlinenoexcept

Drop the lagged-reuse cache: the next setup() rebuilds the matrix and hierarchy regardless of the recompute flag. Call after the solver state is re-seeded (CVodeReInit).

◆ operator=()

KokkosAmgPreconditioner & openswmm::twoD::gpu::KokkosAmgPreconditioner::operator= ( const KokkosAmgPreconditioner & )
delete
Here is the call graph for this function:

◆ ready()

bool openswmm::twoD::gpu::KokkosAmgPreconditioner::ready ( ) const
inlinenoexcept

◆ setup()

void openswmm::twoD::gpu::KokkosAmgPreconditioner::setup ( const MeshViews & mesh,
const StateViews & state,
double gamma,
bool recompute )

Assemble M = I − γ·J from the current Views and (re)build the hierarchy. When recompute is false and a hierarchy exists, the prior matrix + hierarchy are reused verbatim (CVODE's lagged-preconditioner policy — mirrors the serial HypreAmgPreconditioner).

◆ solve()

void openswmm::twoD::gpu::KokkosAmgPreconditioner::solve ( DView r,
DView z,
double gamma )

Apply one BoomerAMG V-cycle: z ≈ M⁻¹ r (Views in the plugin's MemSpace).


The documentation for this class was generated from the following files: