directionalMeshWavePatchDistMethod.H
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ========= |
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 \\ / O peration |
5 \\ / A nd | www.openfoam.com
6 \\/ M anipulation |
7-------------------------------------------------------------------------------
8 Copyright (C) 2020 OpenCFD Ltd.
9-------------------------------------------------------------------------------
10License
11 This file is part of OpenFOAM.
12
13 OpenFOAM is free software: you can redistribute it and/or modify it
14 under the terms of the GNU General Public License as published by
15 the Free Software Foundation, either version 3 of the License, or
16 (at your option) any later version.
17
18 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 for more details.
22
23 You should have received a copy of the GNU General Public License
24 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25
26Class
27 Foam::patchDistMethods::directionalMeshWave
28
29Description
30 Variant of \c meshWave distance-to-patch method.
31
32 Ignores the component in the specified direction. Can be used e.g. to
33 calculate the distance in the z-direction only.
34
35Usage
36 Example of specification in \c fvSchemes.wallDist:
37 \verbatim
38 wallDist
39 {
40 // Mandatory entries (unmodifiable)
41 method directionalMeshWave;
42 n (0 0 1);
43
44 // Optional (inherited) entries (unmodifiable)
45 ...
46 }
47 \endverbatim
48
49 where the entries mean:
50 \table
51 Property | Description | Type | Req'd | Dflt
52 method | Method name: directionalMeshWave | word | yes | -
53 n | The direction component to ignore | vector | yes | -
54 \endtable
55
56 The inherited entries are elaborated in:
57 - \link meshWavePatchDistMethod.H \endlink
58
59See also
60 Foam::wallDist
61 Foam::patchDistMethod::meshWave
62 Foam::patchDistMethod::Poisson
63 Foam::directionalWallPoint
64
65SourceFiles
66 directionalMeshWavePatchDistMethod.C
67
68\*---------------------------------------------------------------------------*/
69
70#ifndef directionalMeshWavePatchDistMethod_H
71#define directionalMeshWavePatchDistMethod_H
72
74
75// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
76
77namespace Foam
78{
79namespace patchDistMethods
80{
81
82/*---------------------------------------------------------------------------*\
83 Class directionalMeshWave Declaration
84\*---------------------------------------------------------------------------*/
85
86class directionalMeshWave
87:
88 public meshWave
89{
90 // Private Member Data
91
92 //- The direction component to ignore
93 const vector n_;
94
95 //- No copy construct
96 directionalMeshWave(const directionalMeshWave&) = delete;
97
98 //- No copy assignment
99 void operator=(const directionalMeshWave&) = delete;
100
101
102public:
104 //- Runtime type information
105 TypeName("directionalMeshWave");
106
107
108 // Constructors
109
110 //- Construct from coefficients dictionary, mesh
111 //- and fixed-value patch set
113 (
114 const dictionary& dict,
115 const fvMesh& mesh,
117 );
118
119
120 // Member Functions
121
122 //- Correct the given distance-to-patch field
123 virtual bool correct(volScalarField& y);
124
125 //- Correct the given distance-to-patch and normal-to-patch fields
126 virtual bool correct(volScalarField& y, volVectorField& n);
127};
128
129
130// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
131
132} // End namespace patchDistMethods
133} // End namespace Foam
134
135// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136
137#endif
138
139// ************************************************************************* //
scalar y
label n
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:91
const labelHashSet & patchIDs() const
Return the patchIDs.
Variant of meshWave distance-to-patch method.
TypeName("directionalMeshWave")
Runtime type information.
Fast topological mesh-wave method for calculating the distance to nearest patch for all cells and bou...
A Vector of values with scalar precision, where scalar is float/double depending on the compilation f...
thermo correct()
dynamicFvMesh & mesh
Namespace for OpenFOAM.
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73