FreeFOAM The Cross-Platform CFD Toolkit
hhuCombustionThermo.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 | Copyright (C) 1991-2010 OpenCFD Ltd.
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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.
15 
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
19  for more details.
20 
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/>.
23 
24 Class
25  Foam::hhuCombustionThermo
26 
27 Description
28  Foam::hhuCombustionThermo
29 
30 SourceFiles
31  hhuCombustionThermo.C
32  newhhuCombustionThermo.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef hhuCombustionThermo_H
37 #define hhuCombustionThermo_H
38 
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class hhuCombustionThermo Declaration
48 \*---------------------------------------------------------------------------*/
49 
51 :
52  public hCombustionThermo
53 {
54 
55 protected:
56 
57  // Protected data
58 
61 
62 
63  // Protected member functions
64 
67 
68 
69 public:
70 
71  //- Runtime type information
72  TypeName("hhuCombustionThermo");
73 
74 
75  // Declare run-time constructor selection tables
76 
78  (
79  autoPtr,
81  fvMesh,
82  (const fvMesh& mesh),
83  (mesh)
84  );
85 
86 
87  // Constructors
88 
89  //- Construct from dictionary and mesh
91 
92 
93  // Selectors
94 
96 
97 
98  //- Destructor
99  virtual ~hhuCombustionThermo();
100 
101 
102  // Member functions
103 
104  //- Update properties
105  virtual void correct() = 0;
106 
107 
108  // Access to thermodynamic state variables.
109 
110  //- Unburnt gas enthalpy [J/kg]
111  // Non-const access allowed for transport equations
112  virtual volScalarField& hu()
113  {
114  return hu_;
115  }
116 
117  //- Unburnt gas enthalpy [J/kg]
118  virtual const volScalarField& hu() const
119  {
120  return hu_;
121  }
122 
123 
124  // Fields derived from thermodynamic state variables
125 
126  //- Unburnt gas enthalpy for cell-set [J/kg]
127  virtual tmp<scalarField> hu
128  (
129  const scalarField& T,
130  const labelList& cells
131  ) const = 0;
132 
133  //- Unburnt gas enthalpy for patch [J/kg]
134  virtual tmp<scalarField> hu
135  (
136  const scalarField& T,
137  const label patchi
138  ) const = 0;
139 
140  //- Unburnt gas temperature [K]
141  virtual const volScalarField& Tu() const
142  {
143  return Tu_;
144  }
145 
146  //- Burnt gas temperature [K]
147  virtual tmp<volScalarField> Tb() const = 0;
148 
149  //- Unburnt gas density [kg/m^3]
150  virtual tmp<volScalarField> rhou() const
151  {
152  return p_*psiu();
153  }
154 
155  //- Burnt gas density [kg/m^3]
156  virtual tmp<volScalarField> rhob() const
157  {
158  return p_*psib();
159  }
160 
161  //- Unburnt gas compressibility [s^2/m^2]
162  virtual tmp<volScalarField> psiu() const = 0;
163 
164  //- Burnt gas compressibility [s^2/m^2]
165  virtual tmp<volScalarField> psib() const = 0;
166 
167  //- Dynamic viscosity of unburnt gas [kg/ms]
168  virtual tmp<volScalarField> muu() const = 0;
169 
170  //- Dynamic viscosity of burnt gas [kg/ms]
171  virtual tmp<volScalarField> mub() const = 0;
172 };
173 
174 
175 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
176 
177 } // End namespace Foam
178 
179 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
180 
181 #endif
182 
183 // ************************ vim: set sw=4 sts=4 et: ************************ //