Go to the documentation of this file.
65 <<
"coefficient = " <<
k_
66 <<
" should be >= 0 and <= 1"
73 const scalar cdWeight,
74 const scalar faceFlux,
81 scalar phiP = Sf&PhiP;
82 scalar phiN = Sf&PhiN;
95 scalar phiCD = cdWeight*phiP + (1 - cdWeight)*phiN;
102 ((faceFlux - phiU)/
stabilise(phiCD - phiU, SMALL) +
k_);
105 return max(
min(PLimiter, 1), 0);
Class with limiter function which returns the limiter for the Phi differencing scheme.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
tmp< DimensionedField< scalar, GeoMesh > > stabilise(const DimensionedField< scalar, GeoMesh > &dsf, const dimensioned< scalar > &ds)
errorManipArg< error, int > exit(error &err, const int errNo=1)
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if succesful.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
scalar limiter(const scalar cdWeight, const scalar faceFlux, const vector &PhiP, const vector &PhiN, const vector &Sf, const scalar &) const
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)