ML Version of the Day
MLAPI::MultiLevelAdaptiveSA Class Reference

Black-box multilevel adaptive smoothed aggregation preconditioner. More...

#include <MLAPI_MultiLevelAdaptiveSA.h>

Inheritance diagram for MLAPI::MultiLevelAdaptiveSA:
Inheritance graph
[legend]
Collaboration diagram for MLAPI::MultiLevelAdaptiveSA:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 MultiLevelAdaptiveSA (const Operator FineMatrix, Teuchos::ParameterList &List, const int NumPDEEqns, const int MaxLevels=20)
 Constructs the hierarchy for given Operator and parameters.
virtual ~MultiLevelAdaptiveSA ()
 Destructor.
const Space GetOperatorDomainSpace () const
 Returns a copy of the internally stored domain space.
const Space GetOperatorRangeSpace () const
 Returns a copy of the internally stored range space.
const Space GetDomainSpace () const
 Returns a copy of the internally stored domain space.
const Space GetRangeSpace () const
 Returns a copy of the internally stored range space.
OperatorR (const int i)
 Returns a reference to the restriction operator of level i.
const OperatorR (const int i) const
 Returns a reference to the restriction operator of level i.
OperatorA (const int i)
 Returns a reference to the operator of level i.
const OperatorA (const int i) const
 Returns a reference to the operator of level i.
OperatorP (const int i)
 Returns a reference to the prolongator operator of level i.
const OperatorP (const int i) const
 Returns a reference to the prolongator operator of level i.
InverseOperatorS (const int i)
 Returns a reference to the inverse operator of level i.
const InverseOperatorS (const int i) const
 Returns a reference to the inverse operator of level i.
int GetMaxLevels () const
 Returns the actual number of levels.
void SetMaxLevels (const int MaxLevels)
 Returns the actual number of levels.
const MultiVector GetNullSpace () const
 Gets a reference to the internally stored null space.
void SetNullSpace (MultiVector &NullSpace)
 Sets the null space multi-vector to NullSpace.
bool IsComputed () const
 Returns true if the hierarchy has been successfully computed.
void SetList (Teuchos::ParameterList &List)
 Sets the internally stored list to List.
std::string GetSmootherType ()
 Returns the smoother solver type.
std::string GetCoarseType ()
 Returns the coarse solver type.
void SetInputNumPDEEqns (const int n)
 Returns the number of PDE equations on the finest level.
int GetInputNumPDEEqns ()
 Returns the number of PDE equations on the current level.
int GetNumPDEEqns ()
 Sets the number of PDE equations on the current level.
void SetNumPDEEqns (const int NumPDEEqns)
int GetMaxCoarseSize ()
 Returns the maximum allowed coarse size.
double GetMaxReduction ()
 Returns the maximum allowed reduction.
int GetNumItersCoarse ()
 Returns the maximum number of applications on the coarser levels.
int GetNumItersFine ()
 Returns the maximum number of applications on the finest level.
double GetComplexity ()
 Returns the multigrid preconditioner operator complexity.
void Compute ()
 Creates an hierarchy using the provided or default null space.
void AdaptCompute (const bool UseDefaultOrSpecified, int AdditionalCandidates)
 Setup the adaptive multilevel hierarchy.
void SetupInitialNullSpace ()
 Computes the first component of the null space.
bool IncrementNullSpace ()
 Increments the null space dimension by one.
int Apply (const MultiVector &b_f, MultiVector &x_f) const
 Applies the preconditioner to b_f, returns the result in x_f.
int SolveMultiLevelSA (const MultiVector &b_f, MultiVector &x_f, int level) const
 Recursively called core of the multi level preconditioner.
std::ostream & Print (std::ostream &os, const bool verbose=true) const
 Prints basic information about this preconditioner.

Detailed Description

Black-box multilevel adaptive smoothed aggregation preconditioner.

This class implements an adaptive smoothed aggregation preconditioner. An example of usage is reported in file AdaptiveSA.cpp. We note that the usage of this class is slightly different from that of MultiLevelSA.

An instance of this class can be created as follows:

int NumPDEEqns = 1;
int MaxLevels = 10;
MultiLevelAdaptiveSA Prec(FineMatrix, List, NumPDEEqns, MaxLevels);

Important methods of this class:

The general usage is:

Author:
Marzio Sala, Ray Tuminaro, Jonathan Hu, Michael Gee, Marian Brezina.
Date:
Last updated on Mar-05.
Todo:

store the structure of the aggregates for all phases.

Current implementation supposes zero threshold.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends