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/>.
25 Foam::constSolidThermo
28 The thermophysical properties of a constSolidThermo
33 \*---------------------------------------------------------------------------*/
35 #ifndef constSolidThermo_H
36 #define constSolidThermo_H
38 #include "basicSolidThermo.H"
40 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45 /*---------------------------------------------------------------------------*\
46 Class constSolidThermo Declaration
47 \*---------------------------------------------------------------------------*/
49 class constSolidThermo
51 public basicSolidThermo
60 //- Constant thermal conductivity [W/(m.K)]
61 dimensionedScalar constK_;
63 //- Thermal conductivity field[W/(m.K)]
67 dimensionedScalar constRho_;
69 //- Specific heat capacity [J/(kg.K)]
70 dimensionedScalar constCp_;
72 //- Heat of formation [J/kg]
73 dimensionedScalar constHf_;
76 dimensionedScalar constEmissivity_;
78 //- Absorptivity [1/m]
79 dimensionedScalar constKappa_;
82 dimensionedScalar constSigmaS_;
87 //- Runtime type information
88 TypeName("constSolidThermo");
93 //- Construct from mesh
94 constSolidThermo(const fvMesh& mesh);
96 //- Construct from mesh and dict
97 constSolidThermo(const fvMesh& mesh, const dictionary& dict);
101 virtual ~constSolidThermo();
106 //- Update properties
107 virtual void correct();
112 //- Constant access to K
113 virtual const volScalarField& K() const;
115 //- Thermal conductivity [W/(m.K)]
116 virtual const volSymmTensorField& directionalK() const;
119 // Derived properties
121 //- Specific heat capacity [J/(kg.K)]
122 virtual tmp<volScalarField> Cp() const;
124 //- Heat of formation [J/kg]
125 virtual tmp<volScalarField> Hf() const;
128 // Per patch calculation
131 virtual tmp<scalarField> rho(const label patchI) const;
133 //- Specific heat capacity [J/kg/K)]
134 virtual tmp<scalarField> Cp(const label patchI) const;
136 //- Thermal conductivity [W//m/K]
137 virtual tmp<scalarField> K(const label patchI) const;
139 //- Thermal conductivity [W//m/K]
140 virtual tmp<symmTensorField>directionalK(const label) const;
142 //- Heat of formation [J/kg]
143 virtual tmp<scalarField> Hf(const label patchI) const;
145 //- Scatter coefficient [1/m]
146 virtual tmp<scalarField> sigmaS(const label) const;
148 //- Absorption coefficient [1/m]
149 virtual tmp<scalarField> kappa(const label) const;
152 virtual tmp<scalarField> emissivity(const label) const;
157 //- Write the constSolidThermo properties
158 virtual bool writeData(Ostream& os) const;
160 //- Read solidThermophysicalProperties dictionary
163 //- Read solidThermophysicalProperties dictionary
164 bool read(const dictionary&);
167 friend Ostream& operator<<(Ostream& os, const constSolidThermo& s);
171 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
173 } // End namespace Foam
175 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
179 // ************************************************************************* //