alphatPhaseChangeWallFunctionFvPatchScalarField.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) 2015-2018 OpenFOAM Foundation
9 Copyright (C) 2021 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::compressible::alphatPhaseChangeWallFunctionFvPatchScalarField
29
30Description
31 Abstract base-class for all alphatWallFunctions supporting phase-change.
32
33Usage
34 Example of the boundary condition specification:
35 \verbatim
36 <patchName>
37 {
38 // Optional entries
39 dmdt <scalarField>;
40 mDotL <scalarField>;
41
42 // Inherited entries
43 ...
44 }
45 \endverbatim
46
47 where the entries mean:
48 \table
49 Property | Description | Type | Reqd | Deflt
50 dmdt | Rate of phase-change | scalarField | no | 0.0
51 mDotL | Latent heat of the phase-change | scalarField | no | 0.0
52 \endtable
53
54 The inherited entries are elaborated in:
55 - \link fixedValueFvPatchFields.H \endlink
56
57See also
58 - Foam::fixedValueFvPatchScalarField
59 - Foam::alphatWallFunctionFvPatchScalarField
60
61SourceFiles
62 alphatPhaseChangeWallFunctionFvPatchScalarField.C
63
64\*---------------------------------------------------------------------------*/
65
66#ifndef alphatPhaseChangeWallFunctionFvPatchScalarField_H
67#define alphatPhaseChangeWallFunctionFvPatchScalarField_H
68
70#include "phasePairKey.H"
71
72// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
73
74namespace Foam
75{
76namespace compressible
77{
78
79/*---------------------------------------------------------------------------*\
80 Class alphatPhaseChangeWallFunctionFvPatchScalarField Declaration
81\*---------------------------------------------------------------------------*/
82
83class alphatPhaseChangeWallFunctionFvPatchScalarField
84:
85 public fixedValueFvPatchScalarField
86{
87protected:
88
89 // Protected Data
90
91 //- Rate of phase-change
93
94 //- Latent heat of the phase-change
96
97
98public:
99
100 //- Runtime type information
101 TypeName("compressible::alphatPhaseChangeWallFunction");
102
103
104 // Constructors
105
106 //- Construct from patch and internal field
108 (
109 const fvPatch&,
111 );
113 //- Construct from patch, internal field and dictionary
115 (
116 const fvPatch&,
119 );
120
121 //- Construct by mapping given
122 //- alphatPhaseChangeWallFunctionFvPatchScalarField
123 //- onto a new patch
125 (
127 const fvPatch&,
129 const fvPatchFieldMapper&
130 );
131
132 //- Construct as copy
134 (
136 );
137
138 //- Construct as copy setting internal field reference
140 (
143 );
144
145 // No clone methods - abstract class
146
147
148 // Member Functions
149
150 //- Return the rate of phase-change
151 virtual const scalarField& dmdt() const
152 {
153 return dmdt_;
154 }
155
156 //- Return the enthalpy source due to phase-change
157 virtual const scalarField& mDotL() const
158 {
159 return mDotL_;
160 }
161
162 //- Is there phase change mass transfer for this phasePair
163 virtual bool activePhasePair(const phasePairKey&) const
164 {
165 return false;
166 }
167
168 //- Return the rate of phase-change for specific phase pair
169 virtual const scalarField& dmdt(const phasePairKey&) const
170 {
171 return dmdt_;
172 }
173
174 //- Return the rate of phase-change for specific phase pair
175 virtual const scalarField& mDotL(const phasePairKey&) const
176 {
177 return mDotL_;
178 }
179
180 //- Return the rate of phase-change for specific phase
181 virtual scalarField dmdt(const word&) const
182 {
183 return dmdt_;
184 }
185
186 //- Return the enthalpy source due to phase-change for specific phase
187 virtual scalarField mDotL(const word&) const
188 {
189 return mDotL_;
190 }
191
193 // Evaluation
194
195 //- Update the coefficients associated with the patch field
196 virtual void updateCoeffs() = 0;
197
199 // I-O
200
201 //- Write
202 virtual void write(Ostream&) const;
203};
205
206// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
207
208} // End namespace compressible
209} // End namespace Foam
210
211// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
212
213#endif
214
215// ************************************************************************* //
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition: Ostream.H:62
Abstract base-class for all alphatWallFunctions supporting phase-change.
virtual const scalarField & dmdt() const
Return the rate of phase-change.
virtual scalarField dmdt(const word &) const
Return the rate of phase-change for specific phase.
virtual bool activePhasePair(const phasePairKey &) const
Is there phase change mass transfer for this phasePair.
virtual scalarField mDotL(const word &) const
Return the enthalpy source due to phase-change for specific phase.
virtual const scalarField & mDotL(const phasePairKey &) const
Return the rate of phase-change for specific phase pair.
TypeName("compressible::alphatPhaseChangeWallFunction")
Runtime type information.
virtual void updateCoeffs()=0
Update the coefficients associated with the patch field.
virtual const scalarField & dmdt(const phasePairKey &) const
Return the rate of phase-change for specific phase pair.
virtual const scalarField & mDotL() const
Return the enthalpy source due to phase-change.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
A FieldMapper for finite-volume patch fields.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
Definition: fvPatch.H:71
An ordered or unorder pair of phase names. Typically specified as follows.
Definition: phasePairKey.H:68
A class for handling words, derived from Foam::string.
Definition: word.H:68
bool compressible
Definition: pEqn.H:2
Namespace for OpenFOAM.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
runTime write()
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73