![]() |
PARALUTION
1.0.0
PARALUTION
|
#include <preconditioner_multicolored.hpp>
Public Member Functions | |
MultiColored () | |
virtual | ~MultiColored () |
virtual void | Clear (void) |
Clear (free all local data) the solver. More... | |
virtual void | Build (void) |
Build the solver (data allocation, structure computation, numerical computation) More... | |
virtual void | SetPrecondMatrixFormat (const unsigned int mat_format) |
Set a specific matrix type of the decomposed block matrices; if not set, CSR matrix format will be used. More... | |
virtual void | SetDecomposition (const bool decomp) |
Set if the preconditioner should be decomposed or not. More... | |
virtual void | Solve (const VectorType &rhs, VectorType *x) |
Solve Operator x = rhs. More... | |
virtual void | SolveZeroSol (const VectorType &rhs, VectorType *x) |
Solve Operator x = rhs; but set first the init x = 0. More... | |
void | SetOperator (const OperatorType &op) |
Set the Operator of the solver. More... | |
virtual void | ResetOperator (const OperatorType &op) |
Reset the operator; see ReBuildNumeric. More... | |
virtual void | Print (void) const =0 |
Print information about the solver. More... | |
virtual void | ReBuildNumeric (void) |
Rebuild only with numerical computation (no allocation or data structure computation) More... | |
virtual void | MoveToHost (void) |
Move all the data (i.e. move the solver) to the host. More... | |
virtual void | MoveToAccelerator (void) |
Move all the data (i.e. move the solver) to the accelerator. More... | |
virtual void | Verbose (const int verb=1) |
Provide verbose output of the solver: verb == 0 no output verb == 1 print info about the solver (start,end); verb == 2 print (iter, residual) via iteration control;. More... | |
Protected Member Functions | |
virtual void | ExtractRHSinX_ (const VectorType &rhs, VectorType *x) |
Extract the rhs into x under the permutation (see Analyse_()) and decompose x into block (x_block_[]) More... | |
virtual void | SolveL_ (void)=0 |
Solve the lower-triangular (left) matrix. More... | |
virtual void | SolveD_ (void)=0 |
Solve the diagonal part (only for SGS) More... | |
virtual void | SolveR_ (void)=0 |
Solve the upper-trianguler (right) matrix. More... | |
virtual void | Solve_ (const VectorType &rhs, VectorType *x)=0 |
Solve directly without block decomposition. More... | |
virtual void | InsertSolution_ (VectorType *x) |
Insert the solution with backward permutation (from x_block_[]) More... | |
virtual void | Build_Analyser_ (void) |
Build the analyzing matrix. More... | |
virtual void | Analyse_ (void) |
Analyse the matrix (i.e. multi-coloring decomposition) More... | |
virtual void | Permute_ (void) |
Permute the preconditioning matrix. More... | |
virtual void | Factorize_ (void) |
Factorize (i.e. build the preconditioner) More... | |
virtual void | Decompose_ (void) |
Decompose the structure into blocks (preconditioner_block_[] for the preconditioning matrix; and x_block_[] for the x vector) More... | |
virtual void | PostAnalyse_ (void) |
Post-analyzing if the preconditioner is not decomposed. More... | |
virtual void | MoveToHostLocalData_ (void) |
Move all local data to the host. More... | |
virtual void | MoveToAcceleratorLocalData_ (void) |
Move all local data to the accelerator. More... | |
virtual void | PrintStart_ (void) const |
Print starting msg of the solver. More... | |
virtual void | PrintEnd_ (void) const |
Print ending msg of the solver. More... | |
Protected Attributes | |
OperatorType * | analyzer_op_ |
OperatorType * | preconditioner_ |
OperatorType *** | preconditioner_block_ |
VectorType ** | x_block_ |
VectorType ** | diag_block_ |
VectorType | x_ |
VectorType | diag_ |
Solver< OperatorType, VectorType, ValueType > ** | diag_solver_ |
int | num_blocks_ |
int * | block_sizes_ |
bool | op_mat_format_ |
Keep the precond matrix in CSR or not. More... | |
unsigned int | precond_mat_format_ |
Precond matrix format. More... | |
bool | decomp_ |
Decompose the preconditioner into blocks or not. More... | |
const OperatorType * | op_ |
Pointer to the operator. More... | |
Solver< OperatorType, VectorType, ValueType > * | precond_ |
Pointer to the defined preconditioner. More... | |
bool | build_ |
Flag == true after building the solver (e.g. Build()) More... | |
LocalVector< int > | permutation_ |
Permutation vector (used if the solver performs permutation/re-ordering techniques) More... | |
int | verb_ |
Verbose flag verb == 0 no output verb == 1 print info about the solver (start,end); verb == 2 print (iter, residual) via iteration control;. More... | |
size_t | global_obj_id |
paralution::MultiColored< OperatorType, VectorType, ValueType >::MultiColored | ( | ) |
|
virtual |
|
protectedvirtual |
Analyse the matrix (i.e. multi-coloring decomposition)
|
virtual |
Build the solver (data allocation, structure computation, numerical computation)
Reimplemented from paralution::Solver< OperatorType, VectorType, ValueType >.
|
protectedvirtual |
Build the analyzing matrix.
Reimplemented in paralution::MultiColoredILU< OperatorType, VectorType, ValueType >.
|
virtual |
Clear (free all local data) the solver.
Reimplemented from paralution::Solver< OperatorType, VectorType, ValueType >.
|
protectedvirtual |
Decompose the structure into blocks (preconditioner_block_[] for the preconditioning matrix; and x_block_[] for the x vector)
|
protectedvirtual |
Extract the rhs into x under the permutation (see Analyse_()) and decompose x into block (x_block_[])
|
protectedvirtual |
Factorize (i.e. build the preconditioner)
Reimplemented in paralution::MultiColoredILU< OperatorType, VectorType, ValueType >.
|
protectedvirtual |
Insert the solution with backward permutation (from x_block_[])
|
virtualinherited |
Move all the data (i.e. move the solver) to the accelerator.
Referenced by main(), mexFunction(), and paralution_fortran_solve().
|
protectedvirtual |
Move all local data to the accelerator.
Implements paralution::Solver< OperatorType, VectorType, ValueType >.
|
virtualinherited |
Move all the data (i.e. move the solver) to the host.
|
protectedvirtual |
Move all local data to the host.
Implements paralution::Solver< OperatorType, VectorType, ValueType >.
|
protectedvirtual |
Permute the preconditioning matrix.
|
protectedvirtual |
Post-analyzing if the preconditioner is not decomposed.
Reimplemented in paralution::MultiColoredGS< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, and paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >.
|
pure virtualinherited |
Print information about the solver.
Implemented in paralution::IC< OperatorType, VectorType, ValueType >, paralution::FixedPoint< OperatorType, VectorType, ValueType >, paralution::ILUT< OperatorType, VectorType, ValueType >, paralution::TNS< OperatorType, VectorType, ValueType >, paralution::ILU< OperatorType, VectorType, ValueType >, paralution::SGS< OperatorType, VectorType, ValueType >, paralution::SPAI< OperatorType, VectorType, ValueType >, paralution::GS< OperatorType, VectorType, ValueType >, paralution::RAS< OperatorType, VectorType, ValueType >, paralution::FSAI< OperatorType, VectorType, ValueType >, paralution::FSAI< paralution::LocalMatrix< ValueTypeL >, paralution::LocalVector< ValueTypeL >, ValueTypeL >, paralution::FSAI< paralution::LocalMatrix< ValueTypeH >, paralution::LocalVector< ValueTypeH >, ValueTypeH >, paralution::MultiColoredGS< OperatorType, VectorType, ValueType >, paralution::SIRA< OperatorTypeH, VectorTypeH, ValueTypeH, OperatorTypeL, VectorTypeL, ValueTypeL >, paralution::CG_HN< OperatorType, VectorType, ValueType >, paralution::CG_HN< OperatorTypeL, VectorTypeL, ValueTypeL >, paralution::CG_HN< OperatorTypeH, VectorTypeH, ValueTypeH >, paralution::DPCG< OperatorType, VectorType, ValueType >, paralution::Jacobi< OperatorType, VectorType, ValueType >, paralution::MultiElimination< OperatorType, VectorType, ValueType >, paralution::AMG< OperatorType, VectorType, ValueType >, paralution::BaseMultiGrid< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, paralution::IDR< OperatorType, VectorType, ValueType >, paralution::AIChebyshev< OperatorType, VectorType, ValueType >, paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >, paralution::BlockPreconditioner< OperatorType, VectorType, ValueType >, paralution::DiagJacobiSaddlePointPrecond< OperatorType, VectorType, ValueType >, paralution::Chebyshev< OperatorType, VectorType, ValueType >, paralution::BiCGStab< OperatorType, VectorType, ValueType >, paralution::CG< OperatorType, VectorType, ValueType >, paralution::CR< OperatorType, VectorType, ValueType >, paralution::FGMRES< OperatorType, VectorType, ValueType >, paralution::GMRES< OperatorType, VectorType, ValueType >, paralution::CG< OperatorTypeL, VectorTypeL, ValueTypeL >, paralution::CG< OperatorTypeH, VectorTypeH, ValueTypeH >, paralution::MixedPrecisionDC< OperatorTypeH, VectorTypeH, ValueTypeH, OperatorTypeL, VectorTypeL, ValueTypeL >, paralution::AS< OperatorType, VectorType, ValueType >, paralution::Inversion< OperatorType, VectorType, ValueType >, paralution::LU< OperatorType, VectorType, ValueType >, and paralution::QR< OperatorType, VectorType, ValueType >.
|
protectedvirtualinherited |
Print ending msg of the solver.
Implements paralution::Solver< OperatorType, VectorType, ValueType >.
|
protectedvirtualinherited |
Print starting msg of the solver.
Implements paralution::Solver< OperatorType, VectorType, ValueType >.
|
virtualinherited |
Rebuild only with numerical computation (no allocation or data structure computation)
Reimplemented in paralution::FixedPoint< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, and paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >.
|
virtualinherited |
Reset the operator; see ReBuildNumeric.
Reimplemented in paralution::SGS< OperatorType, VectorType, ValueType >, paralution::GS< OperatorType, VectorType, ValueType >, and paralution::Jacobi< OperatorType, VectorType, ValueType >.
Referenced by main().
|
virtual |
Set if the preconditioner should be decomposed or not.
|
inherited |
Set the Operator of the solver.
Referenced by paralution::BaseAMG< OperatorType, VectorType, ValueType >::Build(), paralution::MultiElimination< OperatorType, VectorType, ValueType >::Build(), paralution::MultiColored< OperatorType, VectorType, ValueType >::Decompose_(), main(), mexFunction(), paralution_fortran_solve(), and paralution_solve().
|
virtual |
Set a specific matrix type of the decomposed block matrices; if not set, CSR matrix format will be used.
Referenced by paralution::AMG< OperatorType, VectorType, ValueType >::BuildSmoothers(), main(), and paralution_fortran_solve().
|
virtual |
Solve Operator x = rhs.
Implements paralution::Solver< OperatorType, VectorType, ValueType >.
|
protectedpure virtual |
Solve directly without block decomposition.
Implemented in paralution::MultiColoredGS< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, and paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >.
|
protectedpure virtual |
Solve the diagonal part (only for SGS)
Implemented in paralution::MultiColoredGS< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, and paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >.
|
protectedpure virtual |
Solve the lower-triangular (left) matrix.
Implemented in paralution::MultiColoredGS< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, and paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >.
|
protectedpure virtual |
Solve the upper-trianguler (right) matrix.
Implemented in paralution::MultiColoredGS< OperatorType, VectorType, ValueType >, paralution::MultiColoredILU< OperatorType, VectorType, ValueType >, and paralution::MultiColoredSGS< OperatorType, VectorType, ValueType >.
|
virtualinherited |
Solve Operator x = rhs; but set first the init x = 0.
Reimplemented from paralution::Solver< OperatorType, VectorType, ValueType >.
|
virtualinherited |
Provide verbose output of the solver: verb == 0 no output verb == 1 print info about the solver (start,end); verb == 2 print (iter, residual) via iteration control;.
Reimplemented in paralution::DirectLinearSolver< OperatorType, VectorType, ValueType >, paralution::IterativeLinearSolver< OperatorType, VectorType, ValueType >, paralution::IterativeLinearSolver< OperatorTypeL, VectorTypeL, ValueTypeL >, paralution::IterativeLinearSolver< OperatorTypeH, VectorTypeH, ValueTypeH >, and paralution::SIRA< OperatorTypeH, VectorTypeH, ValueTypeH, OperatorTypeL, VectorTypeL, ValueTypeL >.
|
protected |
|
protected |
|
protectedinherited |
Flag == true after building the solver (e.g. Build())
|
protected |
Decompose the preconditioner into blocks or not.
|
protected |
|
protected |
|
protected |
|
protectedinherited |
|
protected |
|
protectedinherited |
Pointer to the operator.
|
protected |
Keep the precond matrix in CSR or not.
|
protectedinherited |
Permutation vector (used if the solver performs permutation/re-ordering techniques)
|
protectedinherited |
Pointer to the defined preconditioner.
|
protected |
Precond matrix format.
|
protected |
|
protected |
|
protectedinherited |
Verbose flag verb == 0 no output verb == 1 print info about the solver (start,end); verb == 2 print (iter, residual) via iteration control;.
|
protected |
|
protected |