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"));
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;
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);
177 scalar
alpha = wArT/wApT;
192 ++nIter < this->maxIter_
195 || nIter < this->minIter_
200 if (nIter >
max(this->defaultMaxIter_, this->maxIter_))
203 <<
"PBiCCCG has failed to converge within the maximum number"
205 <<
max(this->defaultMaxIter_, this->maxIter_) <<
nl
206 <<
" Please fund the development of the more robust"
207 " PBiCCCGStab solver."
Pre-declare SubField and related Field type.
static autoPtr< preconditioner > New(const solver &sol, const dictionary &preconditionerDict)
Return a new preconditioner.
LduMatrix is a general matrix class in which the coefficients are stored as three arrays,...
PBiCCCG(const word &fieldName, const LduMatrix< Type, DType, LUType > &matrix, const dictionary &solverDict)
Construct from matrix components and solver data dictionary.
virtual SolverPerformance< Type > solve(Field< Type > &psi) const
Solve the matrix with this solver.
iterator begin()
Return an iterator to begin traversing the UList.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
A cell is defined as a list of faces with extra functionality.
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
A class representing the concept of 1 (scalar(1)) used to avoid unnecessary manipulations for objects...
Traits class for primitives.
Abstract base class for run-time selectable region solvers.
Template function which returns the un-mangled name of a given type. Useful for types which do not ha...
A class for handling words, derived from string.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const volScalarField & psi
volScalarField alpha(IOobject("alpha", runTime.name(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
errorManipArg< error, int > exit(error &err, const int errNo=1)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
scalar gSumProd(const UList< Type > &f1, const UList< Type > &f2, const label comm)
tmp< DimensionedField< Type, GeoMesh, Field > > cmptDivide(const DimensionedField< Type, GeoMesh, PrimitiveField1 > &df1, const DimensionedField< Type, GeoMesh, PrimitiveField2 > &df2)
tmp< DimensionedField< scalar, GeoMesh, Field > > mag(const DimensionedField< Type, GeoMesh, PrimitiveField > &df)
Type gSumCmptMag(const UList< Type > &f, const label comm)
dimensioned< Type > max(const DimensionedField< Type, GeoMesh, PrimitiveField > &df)