Arcane  v4.1.10.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
Référence du modèle de la classe Arcane::Alina::AMG< Backend, Coarsening, Relax >

Algebraic multigrid method. Plus de détails...

#include </__w/arcaneframework.github.io/arcaneframework.github.io/framework/arccore/src/alina/arccore/alina/AMG.h>

+ Graphe de collaboration de Arcane::Alina::AMG< Backend, Coarsening, Relax >:

Classes

struct  AMGLevel
 
struct  params
 Parameters of the method. Plus de détails...
 

Types publics

typedef Backend backend_type
 
typedef Backend::value_type value_type
 
typedef Backend::col_type col_type
 
typedef Backend::ptr_type ptr_type
 
typedef Backend::matrix matrix
 
typedef Backend::vector vector
 
typedef Coarsening< Backendcoarsening_type
 
typedef Relax< Backendrelax_type
 
typedef BuiltinBackend< value_type, col_type, ptr_type >::matrix build_matrix
 
typedef math::scalar_of< value_type >::type scalar_type
 
typedef Backend::params backend_params
 Backend parameters.
 

Fonctions membres publiques

template<class Matrix>
 AMG (const Matrix &M, const params &p=params(), const backend_params &bprm=backend_params())
 Builds the AMG hierarchy for the system matrix.
 
 AMG (std::shared_ptr< build_matrix > A, const params &p=params(), const backend_params &bprm=backend_params())
 Builds the AMG hierarchy for the system matrix.
 
template<class Matrix>
void rebuild (const Matrix &M, const backend_params &bprm=backend_params())
 Rebuild the hierarchy using the new system matrix.
 
void rebuild (std::shared_ptr< build_matrix > A, const backend_params &bprm=backend_params())
 Rebuild the hierarchy using the new system matrix.
 
template<class Vec1, class Vec2>
void cycle (const Vec1 &rhs, Vec2 &&x) const
 Performs single V-cycle for the given right-hand side and solution.
 
template<class Vec1, class Vec2>
void apply (const Vec1 &rhs, Vec2 &&x) const
 Performs single V-cycle after clearing x.
 
std::shared_ptr< matrixsystem_matrix_ptr () const
 Returns the system matrix from the finest level.
 
const matrixsystem_matrix () const
 
size_t bytes () const
 

Attributs publics

params prm
 

Types privés

typedef std::list< AMGLevel >::const_iterator level_iterator
 

Fonctions membres privées

void _initialize (std::shared_ptr< build_matrix > A, const backend_params &bprm=backend_params())
 
template<class Vec1, class Vec2>
void cycle (level_iterator lvl, const Vec1 &rhs, Vec2 &x) const
 

Attributs privés

std::list< AMGLevellevels
 

Amis

template<class B, template< class > class C, template< class > class R>
std::ostream & operator<< (std::ostream &os, const AMG< B, C, R > &a)
 Sends information about the AMG hierarchy to output stream.
 

Description détaillée

template<class Backend, template< class > class Coarsening, template< class > class Relax>
class Arcane::Alina::AMG< Backend, Coarsening, Relax >

Algebraic multigrid method.

AMG is one of the most effective methods for solution of large sparse unstructured systems of equations, arising, for example, from discretization of PDEs on unstructured grids [Trottenberg2001]. The method can be used as a black-box solver for various computational problems, since it does not require any information about the underlying geometry.

The three template parameters allow the user to select the exact components of the method:

  1. Backend to transfer the constructed hierarchy to,
  2. Coarsening strategy for hierarchy construction, and
  3. Relaxation scheme (smoother to use during the solution phase).

Instance of the class builds the AMG hierarchy for the given system matrix and is intended to be used as a preconditioner.

Définition à la ligne 70 du fichier AMG.h.

Documentation des définitions de type membres

◆ backend_params

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend::params Arcane::Alina::AMG< Backend, Coarsening, Relax >::backend_params

Backend parameters.

Définition à la ligne 90 du fichier AMG.h.

◆ backend_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend Arcane::Alina::AMG< Backend, Coarsening, Relax >::backend_type

Définition à la ligne 74 du fichier AMG.h.

◆ build_matrix

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef BuiltinBackend<value_type,col_type,ptr_type>::matrix Arcane::Alina::AMG< Backend, Coarsening, Relax >::build_matrix

Définition à la ligne 85 du fichier AMG.h.

◆ coarsening_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Coarsening<Backend> Arcane::Alina::AMG< Backend, Coarsening, Relax >::coarsening_type

Définition à la ligne 82 du fichier AMG.h.

◆ col_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend::col_type Arcane::Alina::AMG< Backend, Coarsening, Relax >::col_type

Définition à la ligne 77 du fichier AMG.h.

◆ level_iterator

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef std::list<AMGLevel>::const_iterator Arcane::Alina::AMG< Backend, Coarsening, Relax >::level_iterator
private

Définition à la ligne 475 du fichier AMG.h.

◆ matrix

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend::matrix Arcane::Alina::AMG< Backend, Coarsening, Relax >::matrix

Définition à la ligne 79 du fichier AMG.h.

◆ ptr_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend::ptr_type Arcane::Alina::AMG< Backend, Coarsening, Relax >::ptr_type

Définition à la ligne 78 du fichier AMG.h.

◆ relax_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Relax<Backend> Arcane::Alina::AMG< Backend, Coarsening, Relax >::relax_type

Définition à la ligne 83 du fichier AMG.h.

◆ scalar_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef math::scalar_of<value_type>::type Arcane::Alina::AMG< Backend, Coarsening, Relax >::scalar_type

Définition à la ligne 87 du fichier AMG.h.

◆ value_type

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend::value_type Arcane::Alina::AMG< Backend, Coarsening, Relax >::value_type

Définition à la ligne 76 du fichier AMG.h.

◆ vector

template<class Backend, template< class > class Coarsening, template< class > class Relax>
typedef Backend::vector Arcane::Alina::AMG< Backend, Coarsening, Relax >::vector

Définition à la ligne 80 du fichier AMG.h.

Documentation des constructeurs et destructeur

◆ AMG() [1/2]

template<class Backend, template< class > class Coarsening, template< class > class Relax>
template<class Matrix>
Arcane::Alina::AMG< Backend, Coarsening, Relax >::AMG ( const Matrix & M,
const params & p = params(),
const backend_params & bprm = backend_params() )
inlineexplicit

Builds the AMG hierarchy for the system matrix.

The input matrix is copied here and is safe to delete afterwards.

Paramètres
AThe system matrix. Should be convertible to a CSRMatrix.
pAMG parameters.

Définition à la ligne 190 du fichier AMG.h.

◆ AMG() [2/2]

template<class Backend, template< class > class Coarsening, template< class > class Relax>
Arcane::Alina::AMG< Backend, Coarsening, Relax >::AMG ( std::shared_ptr< build_matrix > A,
const params & p = params(),
const backend_params & bprm = backend_params() )
inlineexplicit

Builds the AMG hierarchy for the system matrix.

The shared pointer to the input matrix is passed here. The matrix will not be copied and should out-live the amg instance. The matrix should be either in CSRMatrix format, or inherit from the class and override its ptr(), col(), and val() virtual functions.

Paramètres
AThe system matrix.
pAMG parameters.

Définition à la ligne 212 du fichier AMG.h.

Documentation des fonctions membres

◆ _initialize()

template<class Backend, template< class > class Coarsening, template< class > class Relax>
void Arcane::Alina::AMG< Backend, Coarsening, Relax >::_initialize ( std::shared_ptr< build_matrix > A,
const backend_params & bprm = backend_params() )
inlineprivate

Définition à la ligne 479 du fichier AMG.h.

◆ apply()

template<class Backend, template< class > class Coarsening, template< class > class Relax>
template<class Vec1, class Vec2>
void Arcane::Alina::AMG< Backend, Coarsening, Relax >::apply ( const Vec1 & rhs,
Vec2 && x ) const
inline

Performs single V-cycle after clearing x.

This is intended for use as a preconditioning procedure.

Paramètres
rhsRight-hand side vector.
xSolution vector.

Définition à la ligne 278 du fichier AMG.h.

◆ bytes()

template<class Backend, template< class > class Coarsening, template< class > class Relax>
size_t Arcane::Alina::AMG< Backend, Coarsening, Relax >::bytes ( ) const
inline

Définition à la ligne 301 du fichier AMG.h.

◆ cycle() [1/2]

template<class Backend, template< class > class Coarsening, template< class > class Relax>
template<class Vec1, class Vec2>
void Arcane::Alina::AMG< Backend, Coarsening, Relax >::cycle ( const Vec1 & rhs,
Vec2 && x ) const
inline

Performs single V-cycle for the given right-hand side and solution.

Paramètres
rhsRight-hand side vector.
xSolution vector.

Définition à la ligne 264 du fichier AMG.h.

Référencé par Arcane::Alina::AMG< Backend, Alina::CoarseningRuntime, Alina::RelaxationRuntime >::apply(), et Arcane::Alina::AMG< Backend, Alina::CoarseningRuntime, Alina::RelaxationRuntime >::cycle().

+ Voici le graphe des appelants de cette fonction :

◆ cycle() [2/2]

template<class Backend, template< class > class Coarsening, template< class > class Relax>
template<class Vec1, class Vec2>
void Arcane::Alina::AMG< Backend, Coarsening, Relax >::cycle ( level_iterator lvl,
const Vec1 & rhs,
Vec2 & x ) const
inlineprivate

Définition à la ligne 525 du fichier AMG.h.

◆ rebuild() [1/2]

template<class Backend, template< class > class Coarsening, template< class > class Relax>
template<class Matrix>
void Arcane::Alina::AMG< Backend, Coarsening, Relax >::rebuild ( const Matrix & M,
const backend_params & bprm = backend_params() )
inline

Rebuild the hierarchy using the new system matrix.

This requires for prm.allow_rebuild to be set. The transfer operators created during the initial setup are reused.

Définition à la ligne 227 du fichier AMG.h.

Référencé par Arcane::Alina::AMG< Backend, Alina::CoarseningRuntime, Alina::RelaxationRuntime >::rebuild().

+ Voici le graphe des appelants de cette fonction :

◆ rebuild() [2/2]

template<class Backend, template< class > class Coarsening, template< class > class Relax>
void Arcane::Alina::AMG< Backend, Coarsening, Relax >::rebuild ( std::shared_ptr< build_matrix > A,
const backend_params & bprm = backend_params() )
inline

Rebuild the hierarchy using the new system matrix.

This requires for prm.allow_rebuild to be set. The transfer operators created during the initial setup are reused.

Définition à la ligne 241 du fichier AMG.h.

◆ system_matrix()

template<class Backend, template< class > class Coarsening, template< class > class Relax>
const matrix & Arcane::Alina::AMG< Backend, Coarsening, Relax >::system_matrix ( ) const
inline

Définition à la ligne 296 du fichier AMG.h.

◆ system_matrix_ptr()

template<class Backend, template< class > class Coarsening, template< class > class Relax>
std::shared_ptr< matrix > Arcane::Alina::AMG< Backend, Coarsening, Relax >::system_matrix_ptr ( ) const
inline

Returns the system matrix from the finest level.

Définition à la ligne 291 du fichier AMG.h.

Documentation des fonctions amies et associées

◆ operator<<

template<class Backend, template< class > class Coarsening, template< class > class Relax>
template<class B, template< class > class C, template< class > class R>
std::ostream & operator<< ( std::ostream & os,
const AMG< B, C, R > & a )
friend

Sends information about the AMG hierarchy to output stream.

Définition à la ligne 578 du fichier AMG.h.

Documentation des données membres

◆ levels

template<class Backend, template< class > class Coarsening, template< class > class Relax>
std::list<AMGLevel> Arcane::Alina::AMG< Backend, Coarsening, Relax >::levels
private

Définition à la ligne 477 du fichier AMG.h.

◆ prm

template<class Backend, template< class > class Coarsening, template< class > class Relax>
params Arcane::Alina::AMG< Backend, Coarsening, Relax >::prm

Définition à la ligne 311 du fichier AMG.h.


La documentation de cette classe a été générée à partir du fichier suivant :