30 template<
class Type,
class DType,
class LUType>
33 const word& fieldName,
49 template<
class Type,
class DType,
class LUType>
56 word preconditionerName(this->controlDict_.lookup(
"preconditioner"));
61 preconditionerName + typeName,
69 Type* __restrict__ psiPtr = psi.
begin();
72 Type* __restrict__ pAPtr = pA.
begin();
75 Type* __restrict__ pTPtr = pT.
begin();
78 Type* __restrict__ wAPtr = wA.
begin();
81 Type* __restrict__ wTPtr = wT.
begin();
84 scalar wArTold = wArT;
87 this->matrix_.Amul(wA, psi);
88 this->matrix_.Tmul(wT, psi);
93 Type* __restrict__ rAPtr = rA.
begin();
94 Type* __restrict__ rTPtr = rT.begin();
97 Type normFactor = this->normFactor(psi, wA, pA);
101 Info<<
" Normalisation factor = " << normFactor <<
endl;
106 solverPerf.finalResidual() = solverPerf.initialResidual();
112 || !solverPerf.checkConvergence(this->tolerance_, this->relTol_)
130 preconPtr->precondition(wA, rA);
131 preconPtr->preconditionT(wT, rT);
146 scalar beta = wArT/wArTold;
157 this->matrix_.Amul(wA, pA);
158 this->matrix_.Tmul(wT, pT);
165 solverPerf.checkSingularity
177 scalar
alpha = wArT/wApT;
181 psiPtr[
cell] += (alpha* pAPtr[
cell]);
182 rAPtr[
cell] -= (alpha* wAPtr[
cell]);
183 rTPtr[
cell] -= (alpha* wTPtr[
cell]);
186 solverPerf.finalResidual() =
192 nIter++ < this->maxIter_
193 && !solverPerf.checkConvergence(this->tolerance_, this->relTol_)
195 || nIter < this->minIter_
199 solverPerf.nIterations() =
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
A list of keyword definitions, which are a keyword followed by any number of values (e...
void size(const label)
Override size to be inconsistent with allocated storage.
volScalarField alpha(IOobject("alpha", runTime.timeName(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
Ostream & endl(Ostream &os)
Add newline and flush stream.
PBiCCCG(const word &fieldName, const LduMatrix< Type, DType, LUType > &matrix, const dictionary &solverDict)
Construct from matrix components and solver data dictionary.
Traits class for primitives.
Type gSumCmptMag(const UList< Type > &f, const label comm)
dimensioned< Type > cmptDivide(const dimensioned< Type > &, const dimensioned< Type > &)
Pre-declare SubField and related Field type.
autoPtr< BasicCompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const typename BasicCompressibleMomentumTransportModel::transportModel &transport)
A class for handling words, derived from string.
iterator begin()
Return an iterator to begin traversing the UList.
scalar gSumProd(const UList< Type > &f1, const UList< Type > &f2, const label comm)
Abstract base-class for LduMatrix solvers.
virtual SolverPerformance< Type > solve(Field< Type > &psi) const
Solve the matrix with this solver.
A cell is defined as a list of faces with extra functionality.
LduMatrix is a general matrix class in which the coefficients are stored as three arrays...
dimensioned< scalar > mag(const dimensioned< Type > &)
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
A class representing the concept of 1 (scalar(1)) used to avoid unnecessary manipulations for objects...