Go to the documentation of this file.
40 for(
direction cmpt=0; cmpt<pTraits<Type>::nComponents; cmpt++)
53 for(
direction cmpt=0; cmpt<pTraits<Type>::nComponents; cmpt++)
55 if (!singular_[cmpt])
return false;
65 const Type& Tolerance,
66 const Type& RelTolerance,
70 if ((logLevel >= 2) || (
debug >= 2))
73 <<
": Iteration " << nIterations_
74 <<
" residual = " << finalResidual_
80 finalResidual_ < Tolerance
82 RelTolerance > small_*pTraits<Type>::one
83 && finalResidual_ <
cmptMultiply(RelTolerance, initialResidual_)
97 for(
direction cmpt=0; cmpt<pTraits<Type>::nComponents; cmpt++)
99 os << solverName_ <<
": Solving for ";
111 os <<
": solution singularity" <<
endl;
115 os <<
", Initial residual = " <<
component(initialResidual_, cmpt)
116 <<
", Final residual = " <<
component(finalResidual_, cmpt)
117 <<
", No Iterations " << nIterations_
127 const Foam::label cmpt,
131 initialResidual_.replace(cmpt, sp.initialResidual());
132 finalResidual_.replace(cmpt, sp.finalResidual());
133 nIterations_.replace(cmpt, sp.nIterations());
134 singular_[cmpt] = sp.singular();
142 return SolverPerformance<typename pTraits<Type>::cmptType>
163 solverName() != sp.solverName()
164 || fieldName() != sp.fieldName()
165 || initialResidual() != sp.initialResidual()
166 || finalResidual() != sp.finalResidual()
167 || nIterations() != sp.nIterations()
168 || converged() != sp.converged()
169 || singular() != sp.singular()
181 return SolverPerformance<Type>
204 >> sp.initialResidual_
209 is.readEnd(
"SolverPerformance");
222 os << token::BEGIN_LIST
223 << sp.solverName_ << token::SPACE
224 << sp.fieldName_ << token::SPACE
225 << sp.initialResidual_ << token::SPACE
226 << sp.finalResidual_ << token::SPACE
227 << sp.nIterations_ << token::SPACE
228 << sp.converged_ << token::SPACE
229 << sp.singular_ << token::SPACE
void component(FieldField< Field, typename FieldField< Field, Type >::cmptType > &sf, const FieldField< Field, Type > &f, const direction d)
Useful combination of include files which define Sin, Sout and Serr and the use of IO streams general...
A class for handling words, derived from Foam::string.
dimensioned< Type > cmptMultiply(const dimensioned< Type > &, const dimensioned< Type > &)
Ostream & endl(Ostream &os)
bool readBegin(const char *funcName)
void cmptMax(FieldField< Field, typename FieldField< Field, Type >::cmptType > &cf, const FieldField< Field, Type > &f)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
label max(const labelHashSet &set, label maxValue=labelMin)
OBJstream os(runTime.globalPath()/outputName)
A traits class, which is primarily used for primitives.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...