BasicChemistryModel.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) 2011-2017 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 Class
27  Foam::BasicChemistryModel
28 
29 Description
30  Basic chemistry model templated on thermodynamics
31 
32 SourceFiles
33  BasicChemistryModelI.H
34  BasicChemistryModel.C
35 
36 \*---------------------------------------------------------------------------*/
37 
38 #ifndef BasicChemistryModel_H
39 #define BasicChemistryModel_H
40 
41 #include "basicChemistryModel.H"
42 #include "autoPtr.H"
43 #include "runTimeSelectionTables.H"
44 
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 
47 namespace Foam
48 {
49 
50 // Forward declaration of classes
51 class fvMesh;
52 
53 /*---------------------------------------------------------------------------*\
54  class BasicChemistryModel Declaration
55 \*---------------------------------------------------------------------------*/
56 
57 template<class ReactionThermo>
59 :
60  public basicChemistryModel
61 {
62  // Private Member Functions
63 
64  //- Construct as copy (not implemented)
66  (
68  ) = delete;
69 
70  //- No copy assignment
71  void operator=(const BasicChemistryModel<ReactionThermo>&) = delete;
72 
73 
74 protected:
75 
76  // Protected data
77 
78  //- Thermo
79  ReactionThermo& thermo_;
80 
81 
82 public:
83 
84  //- Runtime type information
85  TypeName("BasicChemistryModel");
86 
87 
88  //- Thermo type
89  typedef ReactionThermo reactionThermo;
90 
91 
92  //- Declare run-time constructor selection tables
94  (
95  autoPtr,
97  thermo,
98  (ReactionThermo& thermo),
99  (thermo)
100  );
101 
102 
103  // Constructors
104 
105  //- Construct from thermo
106  BasicChemistryModel(ReactionThermo& thermo);
107 
108 
109  //- Selector
111  (
112  ReactionThermo& thermo
113  );
114 
115 
116  //- Destructor
117  virtual ~BasicChemistryModel();
118 
119 
120  // Member Functions
121 
122  //- Return access to the thermo package
123  inline ReactionThermo& thermo();
124 
125  //- Return const access to the thermo package
126  inline const ReactionThermo& thermo() const;
127 };
128 
129 
130 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
131 
132 } // End namespace Foam
133 
134 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135 
136 #ifdef NoRepository
137  #include "BasicChemistryModel.C"
138 #endif
139 
140 #include "BasicChemistryModelI.H"
141 
142 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
143 
144 #endif
145 
146 // ************************************************************************* //
Foam::basicChemistryModel
Base class for chemistry models.
Definition: basicChemistryModel.H:58
Foam::BasicChemistryModel::New
static autoPtr< BasicChemistryModel< ReactionThermo > > New(ReactionThermo &thermo)
Selector.
Definition: BasicChemistryModel.C:47
Foam::BasicChemistryModel
Basic chemistry model templated on thermodynamics.
Definition: BasicChemistryModel.H:57
thermo
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
BasicChemistryModel.C
BasicChemistryModelI.H
Foam::BasicChemistryModel::declareRunTimeSelectionTable
declareRunTimeSelectionTable(autoPtr, BasicChemistryModel, thermo,(ReactionThermo &thermo),(thermo))
Declare run-time constructor selection tables.
basicChemistryModel.H
Foam::BasicChemistryModel::TypeName
TypeName("BasicChemistryModel")
Runtime type information.
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::autoPtr
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: HashPtrTable.H:53
Foam::BasicChemistryModel::~BasicChemistryModel
virtual ~BasicChemistryModel()
Destructor.
Definition: BasicChemistryModel.C:59
Foam::BasicChemistryModel::thermo
ReactionThermo & thermo()
Return access to the thermo package.
Definition: BasicChemistryModelI.H:33
runTimeSelectionTables.H
Macros to ease declaration of run-time selection tables.
Foam::BasicChemistryModel::thermo_
ReactionThermo & thermo_
Thermo.
Definition: BasicChemistryModel.H:78
Foam::BasicChemistryModel::reactionThermo
ReactionThermo reactionThermo
Thermo type.
Definition: BasicChemistryModel.H:88
autoPtr.H