41 scalar maxRatio = 1 + coeff;
51 const label own = owner[facei];
52 const label nbr = neighbour[facei];
55 if (field[own] > maxRatio*field[nbr])
60 else if (field[nbr] > maxRatio*field[own])
84 changedPatchAndFaces.
shrink();
91 cellData[celli] = field[celli];
115 changedPatchAndFaces,
126 field[celli] = cellData[celli].value();
138 const scalar alphaDiff,
140 const scalar alphaMin
153 const label own = owner[facei];
154 const label nbr = neighbour[facei];
177 alpha.boundaryField()[
patchi].patchNeighbourField()
180 if (
mag(
alpha[own] - alphapn[patchFacei]) > alphaDiff)
189 changedPatchAndFaces.
shrink();
190 changedFacesInfo.
shrink();
196 cellData[celli] = field[celli];
226 smoothData.setFaceInfo(changedPatchAndFaces, changedFacesInfo);
232 field[celli] = cellData[celli].value();
244 const scalar alphaDiff
259 const label own = owner[facei];
260 const label nbr = neighbour[facei];
286 alpha.boundaryField()[
patchi].patchNeighbourField()
289 if (
mag(
alpha[own] - alphapn[patchFacei]) > alphaDiff)
301 changedPatchAndFaces.
shrink();
302 changedFacesInfo.
shrink();
329 sweepData.setFaceInfo(changedPatchAndFaces, changedFacesInfo);
337 field[celli] =
max(field[celli], cellData[celli].value());
#define forAll(list, i)
Loop across all elements in list.
const Mesh & mesh() const
Return mesh.
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
DynamicList< T, SizeInc, SizeMult, SizeDiv > & append(const T &)
Append an element at the end of the list.
DynamicList< T, SizeInc, SizeMult, SizeDiv > & shrink()
Shrink the allocated space to the number of elements used.
Wave propagation of information through grid. Every iteration information goes through one layer of c...
Generic GeometricBoundaryField class.
Generic GeometricField class.
const Boundary & boundaryField() const
Return const-reference to the boundary field.
void correctBoundaryConditions()
Correct boundary field.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
void size(const label)
Override size to be inconsistent with allocated storage.
Mesh data needed to do the Finite Volume discretisation.
const labelUList & owner() const
Internal face owner.
const fvBoundaryMesh & boundary() const
Return reference to boundary mesh.
const surfaceVectorField & Cf() const
Return face centres.
const labelUList & neighbour() const
Internal face neighbour.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
virtual bool coupled() const
Return true if this patch is coupled.
virtual const labelUList & faceCells() const
Return faceCells.
label nTotalCells() const
Return total number of cells in decomposed mesh.
const globalMeshData & globalData() const
Return parallel info.
label nInternalFaces() const
Class used to pass additional data in.
scalar maxRatio
Cut off distance.
Helper class used by the fvc::smooth and fvc::spread functions.
Helper class used by fvc::sweep function.
Provides functions smooth spread and sweep which use the FvFaceCellWave algorithm to smooth and redis...
dimensionedScalar alphaMax(viscosity->lookup("alphaMax"))
volScalarField alpha(IOobject("alpha", runTime.name(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
bool valid(const PtrList< ModelType > &l)
void sweep(volScalarField &field, const volScalarField &alpha, const label nLayers, const scalar alphaDiff=0.2)
void smooth(volScalarField &field, const scalar coeff)
void spread(volScalarField &field, const volScalarField &alpha, const label nLayers, const scalar alphaDiff=0.2, const scalar alphaMax=0.99, const scalar alphaMin=0.01)
Pair< label > labelPair
Label pair.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensioned< scalar > mag(const dimensioned< Type > &)
layerAndWeight max(const layerAndWeight &a, const layerAndWeight &b)