fluidThermo.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) 2012-2017 OpenFOAM Foundation
9 Copyright (C) 2017 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::fluidThermo
29
30Description
31 Fundamental fluid thermodynamic properties
32
33SourceFiles
34 fluidThermo.C
35
36\*---------------------------------------------------------------------------*/
37
38#ifndef fluidThermo_H
39#define fluidThermo_H
40
41#include "basicThermo.H"
43
44// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45
46namespace Foam
47{
48
49/*---------------------------------------------------------------------------*\
50 Class fluidThermo Declaration
51\*---------------------------------------------------------------------------*/
53class fluidThermo
54:
55 public basicThermo,
57{
58
59public:
60
61 //- Runtime type information
62 TypeName("fluidThermo");
63
64
65 //- Declare run-time constructor selection table
67 (
68 autoPtr,
70 fvMesh,
71 (const fvMesh& mesh, const word& phaseName),
72 (mesh, phaseName)
73 );
74
75
76 //- Declare run-time constructor selection table for dictionary based
78 (
79 autoPtr,
81 fvMeshDictPhase,
82 (const fvMesh& mesh, const word& phaseName, const word& dictName),
83 (mesh, phaseName, dictName)
84 );
85
86 // Constructors
87
88 //- Construct from mesh and phase name
90 (
91 const fvMesh&,
92 const word& phaseName
93 );
94
95 //- Construct from mesh and phase name
97 (
98 const fvMesh&,
99 const dictionary&,
100 const word& phaseName
101 );
102
103
104 //- Construct from mesh,dictionary,phase name with a single temperature
106 (
107 const fvMesh&,
108 const word& phaseName,
109 const word& dictionaryName
110 );
111
112
113 //- Selector
115 (
116 const fvMesh&,
117 const word& phaseName=word::null
118 );
119
120
121 //- Selector
123 (
124 const fvMesh&,
125 const word& phaseName,
126 const word& dictName
127 );
128
129
130 //- Destructor
131 virtual ~fluidThermo();
132
133
134 // Member functions
135
136 // Access to thermodynamic state variables
137
138 //- Add the given density correction to the density field.
139 // Used to update the density field following pressure solution
140 // Limit thermo rho between rhoMin and rhoMax
141 virtual void correctRho
142 (
143 const volScalarField& deltaRho,
146 ) = 0;
147
148
149 //- Add the given density correction to the density field.
150 // Used to update the density field following pressure solution
151 virtual void correctRho
152 (
153 const volScalarField& deltaRho
154 ) = 0;
155
156 //- Compressibility [s^2/m^2]
157 virtual const volScalarField& psi() const = 0;
158
159
160 // Access to transport state variables
161
162 //- Dynamic viscosity of mixture [kg/m/s]
163 virtual tmp<volScalarField> mu() const = 0;
164
165 //- Dynamic viscosity of mixture for patch [kg/m/s]
166 virtual tmp<scalarField> mu(const label patchi) const = 0;
167
168 //- Kinematic viscosity of mixture [m^2/s]
169 virtual tmp<volScalarField> nu() const;
170
171 //- Kinematic viscosity of mixture for patch [m^2/s]
172 virtual tmp<scalarField> nu(const label patchi) const;
173};
174
175
176// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
177
178} // End namespace Foam
179
180// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
181
182#endif
183
184// ************************************************************************* //
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
Abstract base-class for fluid and solid thermodynamic properties.
Definition: basicThermo.H:66
static const word dictName
Definition: basicThermo.H:256
Base-class for all transport models used by the compressible turbulence models.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
Fundamental fluid thermodynamic properties.
Definition: fluidThermo.H:56
declareRunTimeSelectionTable(autoPtr, fluidThermo, fvMesh,(const fvMesh &mesh, const word &phaseName),(mesh, phaseName))
Declare run-time constructor selection table.
virtual void correctRho(const volScalarField &deltaRho, const dimensionedScalar &rhoMin, const dimensionedScalar &rhoMax)=0
Add the given density correction to the density field.
virtual tmp< volScalarField > nu() const
Kinematic viscosity of mixture [m^2/s].
Definition: fluidThermo.C:103
virtual const volScalarField & psi() const =0
Compressibility [s^2/m^2].
TypeName("fluidThermo")
Runtime type information.
virtual ~fluidThermo()
Destructor.
Definition: fluidThermo.C:97
declareRunTimeSelectionTable(autoPtr, fluidThermo, fvMeshDictPhase,(const fvMesh &mesh, const word &phaseName, const word &dictName),(mesh, phaseName, dictName))
Declare run-time constructor selection table for dictionary based.
virtual tmp< scalarField > mu(const label patchi) const =0
Dynamic viscosity of mixture for patch [kg/m/s].
virtual tmp< volScalarField > mu() const =0
Dynamic viscosity of mixture [kg/m/s].
static autoPtr< fluidThermo > New(const fvMesh &, const word &phaseName=word::null)
Selector.
Definition: fluidThermo.C:75
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:91
A class for managing temporary objects.
Definition: tmp.H:65
A class for handling words, derived from Foam::string.
Definition: word.H:68
dynamicFvMesh & mesh
const dimensionedScalar rhoMin
const dimensionedScalar rhoMax
Namespace for OpenFOAM.
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes)
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73