All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
pureMixture.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-2023 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::pureMixture
26 
27 Description
28  Pure mixture model. This does no mixing, it just returns the single
29  underlying thermo model.
30 
31 SourceFiles
32  pureMixture.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef pureMixture_H
37 #define pureMixture_H
38 
39 #include "dictionary.H"
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class pureMixture Declaration
48 \*---------------------------------------------------------------------------*/
49 
50 template<class ThermoType>
51 class pureMixture
52 {
53 public:
54 
55  // Public Typedefs
56 
57  //- The type of thermodynamics this mixture is instantiated for
58  typedef ThermoType thermoType;
59 
60  //- Mixing type for thermodynamic properties
61  typedef ThermoType thermoMixtureType;
62 
63  //- Mixing type for transport properties
64  typedef ThermoType transportMixtureType;
65 
66 
67 private:
68 
69  // Private Data
70 
71  //- Thermo model
72  ThermoType mixture_;
73 
74 
75 public:
76 
77  // Constructors
78 
79  //- Construct from a dictionary
80  pureMixture(const dictionary&);
81 
82  //- Disallow default bitwise copy construction
83  pureMixture(const pureMixture<ThermoType>&) = delete;
84 
85 
86  // Member Functions
87 
88  //- Return the instantiated type name
89  static word typeName()
90  {
91  return "pureMixture<" + ThermoType::typeName() + '>';
92  }
93 
94  //- Return the mixture for thermodynamic properties
95  const thermoMixtureType& thermoMixture(const nil) const
96  {
97  return mixture_;
98  }
99 
100  //- Return the mixture for transport properties
101  const transportMixtureType& transportMixture(const nil) const
102  {
103  return mixture_;
104  }
105 
106  //- Return the mixture for transport properties
108  (
109  const nil,
110  const thermoMixtureType&
111  ) const
112  {
113  return mixture_;
114  }
115 
116  //- Read dictionary
117  void read(const dictionary&);
118 
119 
120  // Member Operators
121 
122  //- Disallow default bitwise assignment
123  void operator=(const pureMixture<ThermoType>&) = delete;
124 };
125 
126 
127 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
128 
129 } // End namespace Foam
130 
131 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
132 
133 #ifdef NoRepository
134  #include "pureMixture.C"
135 #endif
136 
137 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
138 
139 #endif
140 
141 // ************************************************************************* //
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:162
A zero-sized class without any storage. Used, for example, in HashSet.
Definition: nil.H:59
Pure mixture model. This does no mixing, it just returns the single underlying thermo model.
Definition: pureMixture.H:51
ThermoType thermoType
The type of thermodynamics this mixture is instantiated for.
Definition: pureMixture.H:57
static word typeName()
Return the instantiated type name.
Definition: pureMixture.H:88
ThermoType transportMixtureType
Mixing type for transport properties.
Definition: pureMixture.H:63
ThermoType thermoMixtureType
Mixing type for thermodynamic properties.
Definition: pureMixture.H:60
void operator=(const pureMixture< ThermoType > &)=delete
Disallow default bitwise assignment.
void read(const dictionary &)
Read dictionary.
Definition: pureMixture.C:40
const transportMixtureType & transportMixture(const nil) const
Return the mixture for transport properties.
Definition: pureMixture.H:100
pureMixture(const dictionary &)
Construct from a dictionary.
Definition: pureMixture.C:31
const thermoMixtureType & thermoMixture(const nil) const
Return the mixture for thermodynamic properties.
Definition: pureMixture.H:94
A class for handling words, derived from string.
Definition: word.H:62
Namespace for OpenFOAM.