XiEqModel.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-2025 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::XiEqModel
26 
27 Description
28  Base class for equilibrium flame wrinkling \c XiEq models
29 
30 SourceFiles
31  XiEqModel.C
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef XiEqModel_H
36 #define XiEqModel_H
37 
38 #include "IOdictionary.H"
39 #include "ubRhoThermo.H"
41 #include "runTimeSelectionTables.H"
42 
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
44 
45 namespace Foam
46 {
47 
48 /*---------------------------------------------------------------------------*\
49  Class XiEqModel Declaration
50 \*---------------------------------------------------------------------------*/
51 
52 class XiEqModel
53 {
54 
55 protected:
56 
57  // Protected data
58 
59  //- Thermo
60  const ubRhoThermo& thermo_;
61 
62  //- Turbulence
64 
65  //- Laminar burning velocity
66  const volScalarField& Su_;
67 
68  //- Update coefficients from given dictionary
69  virtual bool readCoeffs(const dictionary& dict) = 0;
70 
71 
72 public:
73 
74  //- Runtime type information
75  TypeName("XiEqModel");
76 
77 
78  // Declare run-time constructor selection table
79 
81  (
82  autoPtr,
83  XiEqModel,
84  dictionary,
85  (
86  const dictionary& dict,
87  const ubRhoThermo& thermo,
88  const compressibleMomentumTransportModel& momentumTransport,
89  const volScalarField& Su
90  ),
91  (
92  dict,
93  thermo,
94  momentumTransport,
95  Su
96  )
97  );
98 
99 
100  // Constructors
101 
102  //- Construct from components
103  XiEqModel
104  (
105  const ubRhoThermo& thermo,
106  const compressibleMomentumTransportModel& momentumTransport,
107  const volScalarField& Su
108  );
109 
110  //- Disallow default bitwise copy construction
111  XiEqModel(const XiEqModel&) = delete;
112 
113 
114  // Selectors
115 
116  //- Return a reference to the selected XiEq model
117  static autoPtr<XiEqModel> New
118  (
119  const dictionary& XiProperties,
120  const ubRhoThermo& thermo,
122  const volScalarField& Su
123  );
124 
125 
126  //- Destructor
127  virtual ~XiEqModel();
128 
129 
130  // Member Functions
131 
132  //- Return the flame-wrinkling XiEq
133  virtual tmp<volScalarField> XiEq() const = 0;
134 
135  //- Return the flame diffusivity
136  virtual tmp<volScalarField> Db() const
137  {
138  return volScalarField::New
139  (
140  "Db",
142  );
143  }
144 
145  //- Update properties from the given XiProperties dictionary
146  bool read(const dictionary& XiProperties);
147 
148 
149  // Member Operators
150 
151  //- Disallow default bitwise assignment
152  void operator=(const XiEqModel&) = delete;
153 };
154 
155 
156 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
157 
158 } // End namespace Foam
159 
160 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
161 
162 #endif
163 
164 // ************************************************************************* //
Generic GeometricField class.
static tmp< GeometricField< Type, GeoMesh, PrimitiveField > > New(const word &name, const Internal &, const PtrList< Patch > &, const HashPtrTable< Source > &=HashPtrTable< Source >())
Return a temporary field constructed from name,.
Base class for equilibrium flame wrinkling XiEq models.
Definition: XiEqModel.H:52
const compressibleMomentumTransportModel & momentumTransport_
Turbulence.
Definition: XiEqModel.H:62
const volScalarField & Su_
Laminar burning velocity.
Definition: XiEqModel.H:65
TypeName("XiEqModel")
Runtime type information.
virtual ~XiEqModel()
Destructor.
Definition: XiEqModel.C:62
virtual tmp< volScalarField > Db() const
Return the flame diffusivity.
Definition: XiEqModel.H:135
declareRunTimeSelectionTable(autoPtr, XiEqModel, dictionary,(const dictionary &dict, const ubRhoThermo &thermo, const compressibleMomentumTransportModel &momentumTransport, const volScalarField &Su),(dict, thermo, momentumTransport, Su))
void operator=(const XiEqModel &)=delete
Disallow default bitwise assignment.
static autoPtr< XiEqModel > New(const dictionary &XiProperties, const ubRhoThermo &thermo, const compressibleMomentumTransportModel &turbulence, const volScalarField &Su)
Return a reference to the selected XiEq model.
Definition: XiEqModelNew.C:31
virtual tmp< volScalarField > XiEq() const =0
Return the flame-wrinkling XiEq.
bool read(const dictionary &XiProperties)
Update properties from the given XiProperties dictionary.
Definition: XiEqModel.C:68
virtual bool readCoeffs(const dictionary &dict)=0
Update coefficients from given dictionary.
Definition: XiEqModel.C:39
const ubRhoThermo & thermo_
Thermo.
Definition: XiEqModel.H:59
XiEqModel(const ubRhoThermo &thermo, const compressibleMomentumTransportModel &momentumTransport, const volScalarField &Su)
Construct from components.
Definition: XiEqModel.C:48
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: autoPtr.H:51
Base class for single-phase compressible momentum transport models.
const rhoField & rho() const
Return the density field.
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
Definition: dictionary.H:162
virtual tmp< volScalarField > nut() const =0
Return the turbulence viscosity.
A class for managing temporary objects.
Definition: tmp.H:55
tmp< VolField< Type > > Su(const VolField< Type > &su, const VolField< Type > &vf)
Definition: fvcSup.C:44
Namespace for OpenFOAM.
Macros to ease declaration of run-time selection tables.
dictionary dict
autoPtr< incompressible::momentumTransportModel > turbulence(incompressible::momentumTransportModel::New(U, phi, viscosity))
fluidMulticomponentThermo & thermo
Definition: createFields.H:15