56 const scalar& maxDelta,
57 const scalar& minDelta,
58 const scalar& extrapolate
61 if (extrapolate > maxDelta + VSMALL)
65 else if (extrapolate < minDelta - VSMALL)
78 const Type& extrapolate
81 for (
direction cmpt = 0; cmpt < Type::nComponents; ++cmpt)
86 maxDelta.component(cmpt),
87 minDelta.component(cmpt),
88 extrapolate.component(cmpt)
102 const faMesh&
mesh = vsf.mesh();
104 tmp<areaVectorField> tGrad = basicGradScheme_().grad(vsf);
124 label own = owner[facei];
125 label nei = neighbour[facei];
127 scalar vsfOwn = vsf[own];
128 scalar vsfNei = vsf[nei];
130 maxVsf[own] =
max(maxVsf[own], vsfNei);
131 minVsf[own] =
min(minVsf[own], vsfNei);
133 maxVsf[nei] =
max(maxVsf[nei], vsfOwn);
134 minVsf[nei] =
min(minVsf[nei], vsfOwn);
138 const areaScalarField::Boundary& bsf = vsf.boundaryField();
152 label own = pOwner[pFacei];
153 scalar vsfNei = psfNei[pFacei];
155 maxVsf[own] =
max(maxVsf[own], vsfNei);
156 minVsf[own] =
min(minVsf[own], vsfNei);
163 label own = pOwner[pFacei];
164 scalar vsfNei = psf[pFacei];
166 maxVsf[own] =
max(maxVsf[own], vsfNei);
167 minVsf[own] =
min(minVsf[own], vsfNei);
177 scalarField maxMinVsf((1.0/k_ - 1.0)*(maxVsf - minVsf));
188 label own = owner[facei];
189 label nei = neighbour[facei];
197 (Cf[facei] -
C[own]) &
g[own]
206 (Cf[facei] -
C[nei]) &
g[nei]
213 const vectorField& pCf = Cf.boundaryField()[patchi];
217 label own = pOwner[pFacei];
224 (pCf[pFacei] -
C[own]) &
g[own]
231 Info<<
"gradient limiter for: " << vsf.name()
238 g.correctBoundaryConditions();
251 const faMesh&
mesh = vsf.mesh();
253 tmp<areaTensorField> tGrad = basicGradScheme_().grad(vsf);
273 label own = owner[facei];
274 label nei = neighbour[facei];
276 const vector& vsfOwn = vsf[own];
277 const vector& vsfNei = vsf[nei];
279 maxVsf[own] =
max(maxVsf[own], vsfNei);
280 minVsf[own] =
min(minVsf[own], vsfNei);
282 maxVsf[nei] =
max(maxVsf[nei], vsfOwn);
283 minVsf[nei] =
min(minVsf[nei], vsfOwn);
287 const areaVectorField::Boundary& bsf = vsf.boundaryField();
300 label own = pOwner[pFacei];
301 const vector& vsfNei = psfNei[pFacei];
303 maxVsf[own] =
max(maxVsf[own], vsfNei);
304 minVsf[own] =
min(minVsf[own], vsfNei);
311 label own = pOwner[pFacei];
312 const vector& vsfNei = psf[pFacei];
314 maxVsf[own] =
max(maxVsf[own], vsfNei);
315 minVsf[own] =
min(minVsf[own], vsfNei);
325 vectorField maxMinVsf((1.0/k_ - 1.0)*(maxVsf - minVsf));
339 label own = owner[facei];
340 label nei = neighbour[facei];
348 (Cf[facei] -
C[own]) &
g[own]
357 (Cf[facei] -
C[nei]) &
g[nei]
364 const vectorField& pCf = Cf.boundaryField()[patchi];
368 label own = pOwner[pFacei];
375 ((pCf[pFacei] -
C[own]) &
g[own])
382 Info<<
"gradient limiter for: " << vsf.name()
400 g.correctBoundaryConditions();