temperaturePhaseChangeTwoPhaseMixture.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) 2016-2020 OpenCFD Ltd.
9-------------------------------------------------------------------------------
10License
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
26Class
27 Foam::temperaturePhaseChangeTwoPhaseMixture
28
29Description
30
31SourceFiles
32 temperaturePhaseChangeTwoPhaseMixture.C
33 newtemperaturePhaseChangeTwoPhaseMixture.C
34
35\*---------------------------------------------------------------------------*/
36
37#ifndef temperaturePhaseChangeTwoPhaseMixture_H
38#define temperaturePhaseChangeTwoPhaseMixture_H
39
41#include "typeInfo.H"
43#include "volFields.H"
44#include "dimensionedScalar.H"
45#include "fvMatrices.H"
46
47// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
48
49namespace Foam
50{
51
52/*---------------------------------------------------------------------------*\
53 Class temperaturePhaseChangeTwoPhaseMixture Declaration
54\*---------------------------------------------------------------------------*/
57:
58 public IOdictionary
59{
60
61protected:
62
63 // Protected data
64
65 //- Reference to the thermoIncompressibleTwoPhaseMixture
67
68 //- Reference to fvMesh
69 const fvMesh& mesh_;
70
71
72 // Private Member Functions
73
74 //- No copy construct
76 (
78 ) = delete;
79
80 //- No copy assignment
82
83
84public:
85
86 //- Runtime type information
87 TypeName("temperaturePhaseChangeTwoPhaseMixture");
88
89
90 // Declare run-time constructor selection table
93 (
94 autoPtr,
96 components,
97 (
99 const fvMesh& mesh
100 ),
101 (mixture, mesh)
102 );
103
104
105 // Selectors
106
107 //- Return a reference to the selected phaseChange model
109 (
111 const fvMesh& mesh
112 );
113
114
115 // Constructors
116
117 //- Construct from components
119 (
121 const fvMesh& mesh
122 );
123
124
125 //- Destructor
126 virtual ~temperaturePhaseChangeTwoPhaseMixture() = default;
127
128
129 // Member Functions
130
131
132 //- Return the mass condensation and vaporisation rates as a
133 // coefficient to multiply (1 - alphal) for the condensation rate
134 // and a coefficient to multiply alphal for the vaporisation rate
135 virtual Pair<tmp<volScalarField>> mDotAlphal() const = 0;
136
137 //- Return the mass condensation and vaporisation rates as coefficients
138 virtual Pair<tmp<volScalarField>> mDot() const = 0;
139
140 //- Return the mass condensation and vaporisation rates as a
141 // coefficient to multiply (Tsat - T) for the condensation rate
142 // and a coefficient to multiply (T - Tsat) for the vaporisation rate
143 virtual Pair<tmp<volScalarField>> mDotDeltaT() const = 0;
144
145 //- Source for T equarion
146 virtual tmp<fvScalarMatrix> TSource() const = 0;
147
148 //- Return the volumetric condensation and vaporisation rates as a
149 // coefficient to multiply (1 - alphal) for the condensation rate
150 // and a coefficient to multiply alphal for the vaporisation rate
151 virtual Pair<tmp<volScalarField>> vDotAlphal() const;
152
153 //- Return the volumetric condensation and vaporisation rates as
154 // coefficients
155 virtual Pair<tmp<volScalarField>> vDot() const;
156
157 //- Correct the phaseChange model
158 virtual void correct() = 0;
159
160 //- Read the transportProperties dictionary and update
161 virtual bool read();
162};
163
164
165// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
166
167} // End namespace Foam
168
169// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
170
171#endif
172
173// ************************************************************************* //
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Definition: IOdictionary.H:57
An ordered pair of two objects of type <T> with first() and second() elements.
Definition: Pair.H:69
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:91
temperaturePhaseChangeTwoPhaseMixture(const temperaturePhaseChangeTwoPhaseMixture &)=delete
No copy construct.
declareRunTimeSelectionTable(autoPtr, temperaturePhaseChangeTwoPhaseMixture, components,(const thermoIncompressibleTwoPhaseMixture &mixture, const fvMesh &mesh),(mixture, mesh))
virtual Pair< tmp< volScalarField > > mDotDeltaT() const =0
Return the mass condensation and vaporisation rates as a.
virtual Pair< tmp< volScalarField > > vDot() const
Return the volumetric condensation and vaporisation rates as.
virtual ~temperaturePhaseChangeTwoPhaseMixture()=default
Destructor.
temperaturePhaseChangeTwoPhaseMixture(const thermoIncompressibleTwoPhaseMixture &mixture, const fvMesh &mesh)
Construct from components.
void operator=(const temperaturePhaseChangeTwoPhaseMixture &)=delete
No copy assignment.
const thermoIncompressibleTwoPhaseMixture & mixture_
Reference to the thermoIncompressibleTwoPhaseMixture.
virtual void correct()=0
Correct the phaseChange model.
TypeName("temperaturePhaseChangeTwoPhaseMixture")
Runtime type information.
virtual Pair< tmp< volScalarField > > vDotAlphal() const
Return the volumetric condensation and vaporisation rates as a.
virtual bool read()
Read the transportProperties dictionary and update.
virtual Pair< tmp< volScalarField > > mDot() const =0
Return the mass condensation and vaporisation rates as coefficients.
static autoPtr< temperaturePhaseChangeTwoPhaseMixture > New(const thermoIncompressibleTwoPhaseMixture &mixture, const fvMesh &mesh)
Return a reference to the selected phaseChange model.
virtual Pair< tmp< volScalarField > > mDotAlphal() const =0
Return the mass condensation and vaporisation rates as a.
virtual tmp< fvScalarMatrix > TSource() const =0
Source for T equarion.
A two-phase incompressible transportModel.
A class for managing temporary objects.
Definition: tmp.H:65
dynamicFvMesh & mesh
A special matrix type and solver, designed for finite volume solutions of scalar equations.
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)
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73