Dune::Amg::AMG< M, X, S, PI, A > Class Template Reference
[Parallel Algebraic Multigrid]

Parallel algebraic multigrid based on agglomeration. More...

#include <dune/istl/paamg/amg.hh>

Inheritance diagram for Dune::Amg::AMG< M, X, S, PI, A >:
Inheritance graph

List of all members.

Public Types

enum  { category = S::category }
typedef M Operator
 The matrix operator type.
typedef PI ParallelInformation
 The type of the parallel information. Either OwnerOverlapCommunication or another type describing the parallel data distribution and providing communication methods.
typedef MatrixHierarchy< M,
ParallelInformation, A
OperatorHierarchy
 The operator hierarchy type.
typedef
OperatorHierarchy::ParallelInformationHierarchy 
ParallelInformationHierarchy
 The parallal data distribution hierarchy type.
typedef X Domain
 The domain type.
typedef X Range
 The range type.
typedef InverseOperator< X, X > CoarseSolver
 the type of the coarse solver.
typedef S Smoother
 The type of the smoother.
typedef SmootherTraits
< Smoother >::Arguments 
SmootherArgs
 The argument type for the construction of the smoother.
typedef X domain_type
 The domain type of the preconditioner.
typedef X range_type
 The range type of the preconditioner.
typedef X::field_type field_type
 The field type of the preconditioner.

Public Member Functions

 AMG (const OperatorHierarchy &matrices, CoarseSolver &coarseSolver, const SmootherArgs &smootherArgs, std::size_t gamma, std::size_t preSmoothingSteps, std::size_t postSmoothingSteps, bool additive=false)
 Construct a new amg with a specific coarse solver.
template<class C >
 AMG (const Operator &fineOperator, const C &criterion, const SmootherArgs &smootherArgs, std::size_t gamma=1, std::size_t preSmoothingSteps=2, std::size_t postSmoothingSteps=2, bool additive=false, const ParallelInformation &pinfo=ParallelInformation())
 Construct an AMG with an inexact coarse solver based on the smoother.
 ~AMG ()
void pre (Domain &x, Range &b)
void apply (Domain &v, const Range &d)
void post (Domain &x)
template<class A1 >
void getCoarsestAggregateNumbers (std::vector< std::size_t, A1 > &cont)
 Get the aggregate number of each unknown on the coarsest level.
std::size_t levels ()
std::size_t maxlevels ()
void recalculateHierarchy ()
 Recalculate the matrix hierarchy.
template<class C >
 AMG (const Operator &matrix, const C &criterion, const SmootherArgs &smootherArgs, std::size_t gamma, std::size_t preSmoothingSteps, std::size_t postSmoothingSteps, bool additive_, const PI &pinfo)
virtual void pre (X &x, X &b)=0
 Prepare the preconditioner.
virtual void apply (X &v, const X &d)=0
 Apply one step of the preconditioner to the system A(v)=d.
virtual void post (X &x)=0
 Clean up.

Friends

class KAMG
class KAmgTwoGrid< AMG >

Detailed Description

template<class M, class X, class S, class PI = SequentialInformation, class A = std::allocator<X>>
class Dune::Amg::AMG< M, X, S, PI, A >

Parallel algebraic multigrid based on agglomeration.

Template Parameters:
M The matrix type
X The vector type
A An allocator for X

Member Typedef Documentation

typedef X Dune::Preconditioner< X, X >::domain_type [inherited]

The domain type of the preconditioner.

Reimplemented in Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, and Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >.

typedef X::field_type Dune::Preconditioner< X, X >::field_type [inherited]

The field type of the preconditioner.

Reimplemented in Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, and Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >.

typedef X Dune::Preconditioner< X, X >::range_type [inherited]

The range type of the preconditioner.

Reimplemented in Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, and Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >.


Member Function Documentation

virtual void Dune::Preconditioner< X, X >::apply ( X &  v,
const X &  d 
) [pure virtual, inherited]

Apply one step of the preconditioner to the system A(v)=d.

On entry v=0 and d=b-A(x) (although this might not be computed in that way. On exit v contains the update, i.e one step computes $ v = M^{-1} d $ where $ M $ is the approximate inverse of the operator $ A $ characterizing the preconditioner.

Parameters:
[out] v The update to be computed
d The current defect.

Implemented in Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >, and Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >.

virtual void Dune::Preconditioner< X, X >::post ( X &  x  )  [pure virtual, inherited]

Clean up.

This method is called after the last apply call for the linear system to be solved. Memory may be deallocated safely here. x is the solution of the linear equation.

Parameters:
x The right hand side of the equation.

Implemented in Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, and Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >.

virtual void Dune::Preconditioner< X, X >::pre ( X &  x,
X &  b 
) [pure virtual, inherited]

Prepare the preconditioner.

A solver solves a linear operator equation A(x)=b by applying one or several steps of the preconditioner. The method pre() is called before the first apply operation. b and x are right hand side and solution vector of the linear system respectively. It may. e.g., scale the system, allocate memory or compute a (I)LU decomposition. Note: The ILU decomposition could also be computed in the constructor or with a separate method of the derived method if several linear systems with the same matrix are to be solved.

Parameters:
x The left hand side of the equation.
b The right hand side of the equation.

Implemented in Dune::SeqOverlappingSchwarz< M, X, TM, TD, TA >, and Dune::SeqOverlappingSchwarz< M, X, TM, TS, TA >.


Friends And Related Function Documentation

template<class M , class X , class S , class PI = SequentialInformation, class A = std::allocator<X>>
friend class KAMG [friend]

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

Generated on Fri Apr 29 2011 with Doxygen (ver 1.7.1) [doxygen-log,error-log].