All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
CombustionModel.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
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::CombustionModel
26 
27 Description
28  Combustion models for templated thermodynamics
29 
30 SourceFiles
31  CombustionModelI.H
32  CombustionModel.C
33  CombustionModelNew.C
34 
35 \*---------------------------------------------------------------------------*/
36 
37 #ifndef CombustionModel_H
38 #define CombustionModel_H
39 
40 #include "combustionModel.H"
41 #include "autoPtr.H"
42 #include "runTimeSelectionTables.H"
43 
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45 
46 namespace Foam
47 {
48 
49 /*---------------------------------------------------------------------------*\
50  class CombustionModel Declaration
51 \*---------------------------------------------------------------------------*/
52 
53 template<class ReactionThermo>
54 class CombustionModel
55 :
56  public combustionModel
57 {
58 public:
59 
60  //- Thermo type
61  typedef ReactionThermo reactionThermo;
62 
63 
64  //- Runtime type information
65  TypeName("CombustionModel");
66 
67 
68  //- Declare run-time constructor selection tables
70  (
71  autoPtr,
73  dictionary,
74  (
75  const word& modelType,
76  const ReactionThermo& thermo,
78  const word& combustionProperties
79  ),
80  (modelType, thermo, turb, combustionProperties)
81  );
82 
83 
84  // Constructors
85 
86  //- Construct from components
88  (
89  const word& modelType,
90  const ReactionThermo& thermo,
92  const word& combustionProperties
93  );
94 
95 
96  //- Selector
98  (
99  const ReactionThermo& thermo,
101  const word& combustionProperties=combustionPropertiesName
102  );
103 
104 
105  //- Destructor
106  virtual ~CombustionModel();
107 
108 
109  // Member Functions
110 
111  //- Return const access to the thermo package
112  virtual const ReactionThermo& thermo() const = 0;
113 
114 
115  // IO
116 
117  //- Update properties from given dictionary
118  virtual bool read();
119 };
120 
121 
122 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
123 
124 } // End namespace Foam
125 
126 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
127 
128 #ifdef NoRepository
129  #include "CombustionModel.C"
130 #endif
131 
132 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
133 
134 #endif
135 
136 // ************************************************************************* //
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
virtual ~CombustionModel()
Destructor.
TypeName("CombustionModel")
Runtime type information.
static autoPtr< CombustionModel > New(const ReactionThermo &thermo, const compressibleMomentumTransportModel &turb, const word &combustionProperties=combustionPropertiesName)
Selector.
CombustionModel(const word &modelType, const ReactionThermo &thermo, const compressibleMomentumTransportModel &turb, const word &combustionProperties)
Construct from components.
virtual const ReactionThermo & thermo() const =0
Return const access to the thermo package.
ReactionThermo reactionThermo
Thermo type.
A class for handling words, derived from string.
Definition: word.H:59
virtual bool read()
Update properties from given dictionary.
declareRunTimeSelectionTable(autoPtr, CombustionModel, dictionary,(const word &modelType, const ReactionThermo &thermo, const compressibleMomentumTransportModel &turb, const word &combustionProperties),(modelType, thermo, turb, combustionProperties))
Declare run-time constructor selection tables.
Base class for combustion models.
Combustion models for templated thermodynamics.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
Macros to ease declaration of run-time selection tables.
Abstract base class for turbulence models (RAS, LES and laminar).
Namespace for OpenFOAM.
static const word combustionPropertiesName
Default combustionProperties dictionary name.