saturationModel.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) 2015-2018 OpenFOAM Foundation
9 Copyright (C) 2020 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::saturationModel
29
30Description
31
32SourceFiles
33 saturationModel.C
34
35\*---------------------------------------------------------------------------*/
36
37#ifndef saturationModel_H
38#define saturationModel_H
39
40#include "IOdictionary.H"
41#include "volFields.H"
42#include "dictionary.H"
44
45// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47namespace Foam
48{
49
50/*---------------------------------------------------------------------------*\
51 Class saturationModel Declaration
52\*---------------------------------------------------------------------------*/
55:
56 public IOdictionary
57{
58 // Private Member Functions
59
60 //- No copy construct
61 saturationModel(const saturationModel&) = delete;
62
63 //- No copy assignment
64 void operator=(const saturationModel&) = delete;
65
66
67public:
68
69 //- Runtime type information
70 TypeName("saturationModel");
71
72
73 //- Declare runtime construction
75 (
76 autoPtr,
79 (
80 const dictionary& dict, const objectRegistry& db
81 ),
82 (dict, db)
83 );
84
85
86 // Constructors
87
88 //- Default constructed (from registry)
89 explicit saturationModel(const objectRegistry& db);
90
91
92 // Selectors
93
94 //- Select default constructed
96 (
97 const dictionary& dict,
98 const objectRegistry& db
99 );
100
101
102 //- Destructor
103 virtual ~saturationModel() = default;
104
105
106 // Member Functions
107
108 //- Saturation pressure
110 (
111 const volScalarField& T
112 ) const = 0;
113
114 //- Saturation pressure derivetive w.r.t. temperature
116 (
117 const volScalarField& T
118 ) const = 0;
119
120 //- Natural log of the saturation pressure
122 (
123 const volScalarField& T
124 ) const = 0;
125
126 //- Saturation temperature
128 (
129 const volScalarField& p
130 ) const = 0;
131};
132
133
134// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135
136} // End namespace Foam
137
138// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
139
140#endif
141
142// ************************************************************************* //
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Definition: IOdictionary.H:57
const objectRegistry & db() const noexcept
Return the local objectRegistry.
Definition: IOobject.C:500
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
Registry of regIOobjects.
virtual tmp< volScalarField > pSatPrime(const volScalarField &T) const =0
Saturation pressure derivetive w.r.t. temperature.
TypeName("saturationModel")
Runtime type information.
declareRunTimeSelectionTable(autoPtr, saturationModel, dictionary,(const dictionary &dict, const objectRegistry &db),(dict, db))
Declare runtime construction.
virtual tmp< volScalarField > Tsat(const volScalarField &p) const =0
Saturation temperature.
virtual tmp< volScalarField > lnPSat(const volScalarField &T) const =0
Natural log of the saturation pressure.
virtual ~saturationModel()=default
Destructor.
virtual tmp< volScalarField > pSat(const volScalarField &T) const =0
Saturation pressure.
static autoPtr< saturationModel > New(const dictionary &dict, const objectRegistry &db)
Select default constructed.
A class for managing temporary objects.
Definition: tmp.H:65
volScalarField & p
const volScalarField & T
Namespace for OpenFOAM.
Macros to ease declaration of run-time selection tables.
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes)
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73