57 template<
class LimiterFunc>
70 const scalar cdWeight,
71 const scalar faceFlux,
72 const typename LimiterFunc::phiType& phiP,
73 const typename LimiterFunc::phiType& phiN,
74 const typename LimiterFunc::gradPhiType& gradcP,
75 const typename LimiterFunc::gradPhiType& gradcN,
79 vector gradfV = phiN - phiP;
81 scalar phiCD = gradfV & (cdWeight*phiP + (1 - cdWeight)*phiN);
88 phif = 0.5*(phiCD + phiU + (1 - cdWeight)*(gradfV & (d & gradcP)));
93 phif = 0.5*(phiCD + phiU - cdWeight*(gradfV & (d & gradcN)));
97 scalar QLimiter = (phif - phiU)/
stabilise(phiCD - phiU, small);
100 return max(
min(QLimiter, 2), 0);
scalar limiter(const scalar cdWeight, const scalar faceFlux, const typename LimiterFunc::phiType &phiP, const typename LimiterFunc::phiType &phiN, const typename LimiterFunc::gradPhiType &gradcP, const typename LimiterFunc::gradPhiType &gradcN, const vector &d) const
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
tmp< DimensionedField< scalar, GeoMesh > > stabilise(const DimensionedField< scalar, GeoMesh > &dsf, const dimensioned< scalar > &ds)
Class with limiter function which returns the limiter for the quadratic-upwind differencing scheme...