Loading...
Searching...
No Matches
filmPyrolysisTemperatureCoupledFvPatchScalarField.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) 2011-2016 OpenFOAM Foundation
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::filmPyrolysisTemperatureCoupledFvPatchScalarField
28
29Description
30 This boundary condition is designed to be used in conjunction with surface
31 film and pyrolysis modelling. It provides a temperature boundary condition
32 for patches on the primary region based on whether the patch is seen to
33 be 'wet', retrieved from the film alpha field.
34
35 - if the patch is wet, the temperature is set using the film temperature
36 - otherwise, it is set using pyrolysis temperature
37
38 Example of the boundary condition specification:
39 \verbatim
40 <patchName>
41 {
42 type filmPyrolysisTemperatureCoupled;
43 phi phi; // name of flux field (default = phi)
44 rho rho; // name of density field (default = rho)
45 deltaWet 1e-4; // threshold height for 'wet' film
46 value uniform 300; // initial temperature / [K]
47 }
48 \endverbatim
49
50SourceFiles
51 filmPyrolysisTemperatureCoupledFvPatchScalarField.C
52
53\*---------------------------------------------------------------------------*/
54
55#ifndef filmPyrolysisTemperatureCoupledFvPatchScalarField_H
56#define filmPyrolysisTemperatureCoupledFvPatchScalarField_H
57
59
60// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
61
62namespace Foam
63{
65/*---------------------------------------------------------------------------*\
66 Class filmPyrolysisTemperatureCoupledFvPatchScalarField Declaration
67\*---------------------------------------------------------------------------*/
68
70:
71 public fixedValueFvPatchScalarField
72{
73 // Private data
74
75 //- Name of film region
76 const word filmRegionName_;
77
78 //- Name of pyrolysis region
79 const word pyrolysisRegionName_;
80
81 //- Name of flux field
82 word phiName_;
83
84 //- Name of density field
85 word rhoName_;
86
87
88public:
89
90 //- Runtime type information
91 TypeName("filmPyrolysisTemperatureCoupled");
92
93
94 // Constructors
95
96 //- Construct from patch and internal field
98 (
99 const fvPatch&,
101 );
102
103 //- Construct from patch, internal field and dictionary
105 (
106 const fvPatch&,
108 const dictionary&
109 );
110
111 //- Construct by mapping given
112 // filmPyrolysisTemperatureCoupledFvPatchScalarField onto a new patch
114 (
116 const fvPatch&,
118 const fvPatchFieldMapper&
119 );
120
121 //- Construct as copy
123 (
125 );
126
127 //- Construct as copy setting internal field reference
129 (
132 );
133
134 //- Return a clone
135 virtual tmp<fvPatchField<scalar>> clone() const
136 {
137 return fvPatchField<scalar>::Clone(*this);
138 }
139
140 //- Clone with an internal field reference
142 (
144 ) const
145 {
146 return fvPatchField<scalar>::Clone(*this, iF);
147 }
148
149
150 // Member functions
151
152 // Access
154 //- Return the name of phi
155 const word& phiName() const
156 {
157 return phiName_;
158 }
159
160 //- Return reference to the name of phi to allow adjustment
162 {
163 return phiName_;
164 }
165
166 //- Return the name of rho
167 const word& rhoName() const
168 {
169 return rhoName_;
170 }
171
172 //- Return reference to the name of rho to allow adjustment
173 word& rhoName()
174 {
175 return rhoName_;
176 }
178
179 //- Update the coefficients associated with the patch field
180 virtual void updateCoeffs();
181
182 //- Write
183 virtual void write(Ostream&) const;
184};
186
187// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
188
189} // End namespace Foam
190
191// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
192
193#endif
194
195// ************************************************************************* //
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:59
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition dictionary.H:133
word & phiName()
Return reference to the name of phi to allow adjustment.
virtual tmp< fvPatchField< scalar > > clone(const DimensionedField< scalar, volMesh > &iF) const
Clone with an internal field reference.
TypeName("filmPyrolysisTemperatureCoupled")
Runtime type information.
word & rhoName()
Return reference to the name of rho to allow adjustment.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
filmPyrolysisTemperatureCoupledFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
A FieldMapper for finite-volume patch fields.
static tmp< fvPatchField< Type > > Clone(const DerivedPatchField &pf, Args &&... args)
Clone a patch field, optionally with internal field reference etc.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
Definition fvPatch.H:71
A class for managing temporary objects.
Definition tmp.H:75
A class for handling words, derived from Foam::string.
Definition word.H:66
Namespace for OpenFOAM.
runTime write()
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition typeInfo.H:68