SERiF v0.0.1a
Stellar Evolution and Rotation in Four Dimensions
Loading...
Searching...
No Matches
serif::solver::preconditioner::backend::mfem::SparseDirectCache Class Referencefinal

The symbolic analysis (fill-reducing ordering) of the last matrix factored through this cache. More...

#include <sparse_direct.hpp>

Collaboration diagram for serif::solver::preconditioner::backend::mfem::SparseDirectCache:
[legend]

Classes

struct  State
 

Public Member Functions

 SparseDirectCache ()
 
 ~SparseDirectCache ()
 
 SparseDirectCache (const SparseDirectCache &)=delete
 
SparseDirectCache & operator= (const SparseDirectCache &)=delete
 
std::shared_ptr< const detail::DirectLUPattern > pattern (int size, const long *column_starts, const int *row_indices, const double *values, int &status)
 The cached analysis when it matches this pattern, otherwise a new analysis, which replaces it.
 

Private Attributes

std::unique_ptr< State > m_state
 

Detailed Description

The symbolic analysis (fill-reducing ordering) of the last matrix factored through this cache.

Note
A preconditioner keeps one per sparse-direct block for its lifetime, so Newton steps whose matrix keeps the same sparsity pattern repeat only the numeric factorization (0.03 instead of 0.26 s on the benchmark potential block with Accelerate). The reused analysis gives bitwise the same factorization as a fresh one, so results do not depend on the cache. Safe to share between threads.

Constructor & Destructor Documentation

◆ SparseDirectCache() [1/2]

serif::solver::preconditioner::backend::mfem::SparseDirectCache::SparseDirectCache ( )

◆ ~SparseDirectCache()

serif::solver::preconditioner::backend::mfem::SparseDirectCache::~SparseDirectCache ( )
default

◆ SparseDirectCache() [2/2]

serif::solver::preconditioner::backend::mfem::SparseDirectCache::SparseDirectCache ( const SparseDirectCache & )
delete

Member Function Documentation

◆ operator=()

SparseDirectCache & serif::solver::preconditioner::backend::mfem::SparseDirectCache::operator= ( const SparseDirectCache & )
delete

◆ pattern()

std::shared_ptr< const detail::DirectLUPattern > serif::solver::preconditioner::backend::mfem::SparseDirectCache::pattern ( int size,
const long * column_starts,
const int * row_indices,
const double * values,
int & status )
nodiscard

The cached analysis when it matches this pattern, otherwise a new analysis, which replaces it.

Member Data Documentation

◆ m_state

std::unique_ptr<State> serif::solver::preconditioner::backend::mfem::SparseDirectCache::m_state
private

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