Iterative solver for symmetric and assymetric matrices which uses a run-time selected smoother e.g. GaussSeidel to converge the solution to the required tolerance. More...
#include <OpenFOAM/smoothSolver.H>
Iterative solver for symmetric and assymetric matrices which uses a run-time selected smoother e.g. GaussSeidel to converge the solution to the required tolerance.
To improve efficiency, the residual is evaluated after every nSweeps smoothing iterations.
Definition at line 54 of file smoothSolver.H.
Public Member Functions | |
TypeName ("smoothSolver") | |
Runtime type information.
| |
smoothSolver (const word &fieldName, const lduMatrix &matrix, const FieldField< Field, scalar > &interfaceBouCoeffs, const FieldField< Field, scalar > &interfaceIntCoeffs, const lduInterfaceFieldPtrsList &interfaces, const dictionary &solverControls) | |
Construct from matrix components and solver controls.
| |
virtual | ~smoothSolver () |
virtual lduMatrix::solverPerformance | solve (scalarField &psi, const scalarField &source, const direction cmpt=0) const |
Solve the matrix with this solver.
| |
Protected Member Functions | |
virtual void | readControls () |
Read the control parameters from the controlDict_.
| |
Protected Attributes | |
label | nSweeps_ |
Number of sweeps before the evaluation of residual.
|
smoothSolver | ( | const word & | fieldName, |
const lduMatrix & | matrix, | ||
const FieldField< Field, scalar > & | interfaceBouCoeffs, | ||
const FieldField< Field, scalar > & | interfaceIntCoeffs, | ||
const lduInterfaceFieldPtrsList & | interfaces, | ||
const dictionary & | solverControls | ||
) |
Construct from matrix components and solver controls.
Definition at line 45 of file smoothSolver.C.
virtual ~smoothSolver | ( | ) | [inline, virtual]
|
Definition at line 90 of file smoothSolver.H.
void readControls | ( | ) | [protected, virtual]
|
Read the control parameters from the controlDict_.
Reimplemented from lduMatrix::solver.
Definition at line 70 of file smoothSolver.C.
References lduMatrix::solver::controlDict_, dictionary::lookupOrDefault(), and smoothSolver::nSweeps_.
TypeName | ( | "smoothSolver" | ) |
Runtime type information.
Foam::lduMatrix::solverPerformance solve | ( | scalarField & | psi, |
const scalarField & | source, | ||
const direction | cmpt = 0
|
||
) | const [virtual]
|
Solve the matrix with this solver.
Implements lduMatrix::solver.
Definition at line 78 of file smoothSolver.C.
References lduMatrix::solverPerformance::checkConvergence(), Foam::endl(), lduMatrix::solverPerformance::finalResidual(), Foam::gSumMag(), Foam::Info, lduMatrix::solverPerformance::initialResidual(), lduMatrix::smoother::New(), lduMatrix::solverPerformance::nIterations(), and List< T >::size().
label nSweeps_ [protected]
|
Number of sweeps before the evaluation of residual.
Definition at line 63 of file smoothSolver.H.
Referenced by smoothSolver::readControls().