34 lduMatrix::solver::addasymMatrixConstructorToTable<PBiCG>
43 const word& fieldName,
81 scalar* __restrict__ psiPtr = psi.
begin();
84 scalar* __restrict__ pAPtr = pA.
begin();
87 scalar* __restrict__ wAPtr = wA.
begin();
90 matrix_.Amul(wA, psi, interfaceBouCoeffs_, interfaces_, cmpt);
94 scalar* __restrict__ rAPtr = rA.
begin();
97 const scalar normFactor = this->normFactor(psi, source, wA, pA);
99 if (lduMatrix::debug >= 2)
101 Info<<
" Normalisation factor = " << normFactor <<
endl;
118 scalar* __restrict__ pTPtr = pT.
begin();
121 scalar* __restrict__ wTPtr = wT.
begin();
124 matrix_.Tmul(wT, psi, interfaceIntCoeffs_, interfaces_, cmpt);
128 scalar* __restrict__ rTPtr = rT.
begin();
145 const scalar wArTold = wArT;
148 preconPtr->precondition(wA, rA, cmpt);
149 preconPtr->preconditionT(wT, rT, cmpt);
164 const scalar beta = wArT/wArTold;
175 matrix_.Amul(wA, pA, interfaceBouCoeffs_, interfaces_, cmpt);
176 matrix_.Tmul(wT, pT, interfaceIntCoeffs_, interfaces_, cmpt);
178 const scalar wApT =
gSumProd(wA, pT, matrix().
mesh().comm());
189 const scalar
alpha = wArT/wApT;
215 <<
"PBiCG has failed to converge within the maximum number" 216 " of iterations " <<
max(defaultMaxIter_, maxIter_) <<
nl 217 <<
" Please try the more robust PBiCGStab solver." scalar gSumMag(const FieldField< Field, Type > &f)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A list of keyword definitions, which are a keyword followed by any number of values (e...
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
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.
PBiCG(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 data stream.
virtual solverPerformance solve(scalarField &psi, const scalarField &source, const direction cmpt=0) const
Solve the matrix with this solver.
A class for handling words, derived from string.
static autoPtr< preconditioner > New(const solver &sol, const dictionary &solverControls)
Return a new preconditioner.
Abstract base-class for lduMatrix solvers.
iterator begin()
Return an iterator to begin traversing the UList.
lduMatrix::solver::addasymMatrixConstructorToTable< PBiCG > addPBiCGAsymMatrixConstructorToTable_
scalar gSumProd(const UList< Type > &f1, const UList< Type > &f2, const label comm)
defineTypeNameAndDebug(combustionModel, 0)
lduMatrix is a general matrix class in which the coefficients are stored as three arrays...
A cell is defined as a list of faces with extra functionality.
dimensioned< scalar > mag(const dimensioned< Type > &)
static word getName(const dictionary &)
Find the preconditioner name (directly or from a sub-dictionary)
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
const lduMesh & mesh() const
Return the LDU mesh from which the addressing is obtained.