1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
11 OpenFOAM is free software: you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by
13 the Free Software Foundation, either version 3 of the License, or
14 (at your option) any later version.
16 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 You should have received a copy of the GNU General Public License
22 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
28 Common functions to emissivity. It gets supplied from lookup into a
29 dictionary or calculated by the solidThermo:
31 - 'lookup' : lookup volScalarField with name
32 - 'solidThermo' : use basicSolidThermo emissivity()
35 radiationCoupledBase.C
37 \*---------------------------------------------------------------------------*/
39 #ifndef radiationCoupledBase_H
40 #define radiationCoupledBase_H
42 #include "scalarField.H"
43 #include "NamedEnum.H"
46 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
51 /*---------------------------------------------------------------------------*\
52 Class radiationCoupledBase Declaration
53 \*---------------------------------------------------------------------------*/
55 class radiationCoupledBase
58 //- Type of supplied emissivity
59 enum emissivityMethodType
69 static const NamedEnum<emissivityMethodType, 2>
70 emissivityMethodTypeNames_;
73 const fvPatch& patch_;
79 //- How to get emissivity
80 const emissivityMethodType method_;
83 // Cached locally when is read from dictionary (lookup mode)
84 scalarField emissivity_;
91 //- Construct from patch, emissivity mode and emissivity
95 const word& calculationMethod,
96 const scalarField& emissivity
99 //- Construct from patch and dictionary
102 const fvPatch& patch,
103 const dictionary& dict
109 //- Method to obtain emissivity
110 word emissivityMethod() const
112 return emissivityMethodTypeNames_[method_];
116 //- Calculate corresponding emissivity field
117 scalarField emissivity() const;
120 void write(Ostream&) const;
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
126 } // End namespace Foam
128 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
132 // ************************************************************************* //