
Public Member Functions | |
| MGSmootherPrecondition (VectorMemory< VECTOR > &mem, const unsigned int steps=1, const bool variable=false, const bool symmetric=false, const bool transpose=false) | |
| template<class MATRIX2 > | |
| void | initialize (const MGLevelObject< MATRIX2 > &matrices, const typename PRECONDITIONER::AdditionalData &additional_data=typename PRECONDITIONER::AdditionalData()) |
| template<class MATRIX2 , class DATA > | |
| void | initialize (const MGLevelObject< MATRIX2 > &matrices, const MGLevelObject< DATA > &additional_data) |
| template<class MATRIX2 , class DATA > | |
| void | initialize (const MGLevelObject< MATRIX2 > &matrices, const DATA &additional_data, const unsigned int block_row, const unsigned int block_col) |
| template<class MATRIX2 , class DATA > | |
| void | initialize (const MGLevelObject< MATRIX2 > &matrices, const MGLevelObject< DATA > &additional_data, const unsigned int block_row, const unsigned int block_col) |
| void | clear () |
| virtual void | smooth (const unsigned int level, VECTOR &u, const VECTOR &rhs) const |
| std::size_t | memory_consumption () const |
Public Attributes | |
| MGLevelObject< PRECONDITIONER > | smoothers |
Private Attributes | |
| MGLevelObject< PointerMatrix < MATRIX, VECTOR > > | matrices |
Smoother using preconditioner classes.
This class performs smoothing on each level. The operation can be controlled by several parameters. First, the relaxation parameter omega is used in the underlying relaxation method. steps is the number of relaxation steps on the finest level (on all levels if variable is off). If variable is true, the number of smoothing steps is doubled on each coarser level. This results in a method having the complexity of the W-cycle, but saving grid transfers. This is the method proposed by Bramble at al.
The option symmetric switches on alternating between the smoother and its transpose in each step as proposed by Bramble.
transpose uses the transposed smoothing operation using Tvmult instead of the regular vmult of the relaxation scheme.
If you are using block matrices, the second initialize function offers the possibility to extract a single block for smoothing. In this case, the multigrid method must be used only with the vector associated to that single block.
The library contains instantiation for SparseMatrix<.> and Vector<.>, where the template arguments are all combinations of float and double. Additional instantiations may be created by including the file mg_smoother.templates.h.
Definition at line 525 of file mg_smoother.h.
| MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::MGSmootherPrecondition | ( | VectorMemory< VECTOR > & | mem, |
| const unsigned int | steps = 1, |
||
| const bool | variable = false, |
||
| const bool | symmetric = false, |
||
| const bool | transpose = false |
||
| ) |
Constructor. Sets memory and smoothing parameters.
| void MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::initialize | ( | const MGLevelObject< MATRIX2 > & | matrices, |
| const typename PRECONDITIONER::AdditionalData & | additional_data = typename PRECONDITIONER::AdditionalData() |
||
| ) |
Initialize for matrices. This function stores pointers to the level matrices and initializes the smoothing operator with the same smoother for each level.
additional_data is an object of type PRECONDITIONER::AdditionalData and is handed to the initialization function of the relaxation method.
| void MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::initialize | ( | const MGLevelObject< MATRIX2 > & | matrices, |
| const MGLevelObject< DATA > & | additional_data | ||
| ) |
Initialize for matrices. This function stores pointers to the level matrices and initializes the smoothing operator with the according smoother for each level.
additional_data is an object of type PRECONDITIONER::AdditionalData and is handed to the initialization function of the relaxation method.
| void MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::initialize | ( | const MGLevelObject< MATRIX2 > & | matrices, |
| const DATA & | additional_data, | ||
| const unsigned int | block_row, | ||
| const unsigned int | block_col | ||
| ) |
Initialize for single blocks of matrices. Of this block matrix, the block indicated by block_row and block_col is selected on each level. This function stores pointers to the level matrices and initializes the smoothing operator with the same smoother for each level.
additional_data is an object of type PRECONDITIONER::AdditionalData and is handed to the initialization function of the relaxation method.
| void MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::initialize | ( | const MGLevelObject< MATRIX2 > & | matrices, |
| const MGLevelObject< DATA > & | additional_data, | ||
| const unsigned int | block_row, | ||
| const unsigned int | block_col | ||
| ) |
Initialize for single blocks of matrices. Of this block matrix, the block indicated by block_row and block_col is selected on each level. This function stores pointers to the level matrices and initializes the smoothing operator with the according smoother for each level.
additional_data is an object of type PRECONDITIONER::AdditionalData and is handed to the initialization function of the relaxation method.
| void MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::clear | ( | ) | [virtual] |
Empty all vectors.
Implements MGSmootherBase< VECTOR >.
| virtual void MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::smooth | ( | const unsigned int | level, |
| VECTOR & | u, | ||
| const VECTOR & | rhs | ||
| ) | const [virtual] |
The actual smoothing method.
Implements MGSmootherBase< VECTOR >.
| std::size_t MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::memory_consumption | ( | ) | const |
Memory used by this object.
| MGLevelObject<PRECONDITIONER> MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::smoothers |
Object containing relaxation methods.
Definition at line 644 of file mg_smoother.h.
MGLevelObject<PointerMatrix<MATRIX, VECTOR> > MGSmootherPrecondition< MATRIX, PRECONDITIONER, VECTOR >::matrices [private] |
Pointer to the matrices.
Definition at line 656 of file mg_smoother.h.
documentation generated on Fri Feb 3 2012 06:04:09 by
doxygen
1.7.2