/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2011-2022 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM. If not, see .
Class
Foam::patchDistWave
Description
Takes a set of patches to start FaceCellWave from and computed the distance
at patches and possibly additional transported data.
SourceFiles
patchDistWave.C
\*---------------------------------------------------------------------------*/
#ifndef patchDistWave_H
#define patchDistWave_H
#include "Field.H"
#include "FieldField.H"
#include "UPtrList.H"
#include "FaceCellWave.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// Forward declaration of classes
class polyMesh;
class wallPoint;
namespace patchDistWave
{
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
//- Set initial set of changed faces
template
void setChangedFaces
(
const polyMesh& mesh,
const labelHashSet& patchIDs,
labelList& changedFaces,
List& faceDist,
const InitialPatchData& ... initialPatchData
);
//- Copy FaceCellWave values into the cell fields
template
label getCellValues
(
const polyMesh& mesh,
FaceCellWave& waveInfo,
Field& cellValues,
DataMethod method,
const DataType& stabiliseValue = pTraits::zero
);
//- Copy FaceCellWave values into the patch field-fields
template
<
class PatchPointType,
template class PatchField,
class DataType,
class DataMethod
>
label getPatchValues
(
const polyMesh& mesh,
FaceCellWave& wave,
FieldField& patchValues,
DataMethod method,
const DataType& stabiliseValue = pTraits::zero
);
//- Wave distance data from the patches to the cells
template
label wave
(
const polyMesh& mesh,
const labelHashSet& patchIDs,
scalarField& cellDistance,
bool correct = true
);
//- Wave distance and auxiliary data from the patches to the cells and other
// patch faces
template class PatchField>
label wave
(
const polyMesh& mesh,
const labelHashSet& patchIDs,
const FieldField&
initialPatchData,
scalarField& cellDistance,
FieldField& patchDistance,
Field& cellData,
FieldField& patchData,
bool correct = true
);
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace patchDistWave
} // End namespace Foam
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#ifdef NoRepository
#include "patchDistWaveTemplates.C"
#endif
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
// ************************************************************************* //