QGDsolver
The open source CFD toolbox
Main Page
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Friends
Macros
Groups
QGD
thermoModels
psiQGDThermo
psiQGDThermo.C
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-2016 OpenFOAM Foundation
9
Copyright (C) 2019 OpenCFD Ltd.
10
Copyright (C) 2016-2019 ISP RAS (www.ispras.ru) UniCFD Group (www.unicfd.ru)
11
-------------------------------------------------------------------------------
12
13
License
14
This file is part of QGDsolver, based on OpenFOAM library.
15
16
OpenFOAM is free software: you can redistribute it and/or modify it
17
under the terms of the GNU General Public License as published by
18
the Free Software Foundation, either version 3 of the License, or
19
(at your option) any later version.
20
21
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
22
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
23
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
24
for more details.
25
26
You should have received a copy of the GNU General Public License
27
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
28
29
Group
30
grpPsiQGDThermo
31
\*---------------------------------------------------------------------------*/
32
33
34
35
#include "
psiQGDThermo.H
"
36
#include "surfaceFields.H"
37
#include "typeInfo.H"
38
#include "coupledPolyPatch.H"
39
#include "coupledFvPatch.H"
40
#include "emptyFvPatch.H"
41
#include "wedgeFvPatch.H"
42
#include "symmetryPlaneFvPatch.H"
43
#include "symmetryFvPatch.H"
44
#include "wallFvPatch.H"
45
46
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47
48
namespace
Foam
49
{
50
defineTypeNameAndDebug
(
psiQGDThermo
, 0);
51
defineRunTimeSelectionTable
(
psiQGDThermo
, fvMesh);
52
}
53
54
55
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
56
57
Foam::psiQGDThermo::psiQGDThermo
(
const
fvMesh& mesh,
const
word& phaseName)
58
:
59
psiThermo(mesh, phaseName),
60
QGDThermo
(mesh, *this),
61
c_
62
(
63
"thermo:c"
,
64
qgdCoeffs().hQGD()/mesh.time().deltaT()
65
),
66
gamma_
67
(
68
"thermo:gamma"
,
69
c_ / c_
70
)
71
{
72
this->
read
();
73
}
74
75
Foam::psiQGDThermo::psiQGDThermo
(
const
fvMesh& mesh,
const
word& phaseName,
const
word& dictName)
76
:
77
psiThermo(mesh, phaseName, dictName),
78
QGDThermo
(mesh, *this),
79
c_
80
(
81
"thermo:c"
,
82
qgdCoeffs().hQGD()/mesh.time().deltaT()
83
),
84
gamma_
85
(
86
"thermo:gamma"
,
87
c_ / c_
88
)
89
{
90
this->
read
();
91
}
92
93
94
95
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
96
97
Foam::autoPtr<Foam::psiQGDThermo>
Foam::psiQGDThermo::New
98
(
99
const
fvMesh& mesh,
100
const
word& phaseName
101
)
102
{
103
return
basicThermo::New<psiQGDThermo>(mesh, phaseName);
104
}
105
106
Foam::autoPtr<Foam::psiQGDThermo>
Foam::psiQGDThermo::New
107
(
108
const
fvMesh& mesh,
109
const
word& phaseName,
110
const
word& dictName
111
)
112
{
113
return
basicThermo::New<psiQGDThermo>(mesh, phaseName);
114
}
115
116
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
117
118
Foam::psiQGDThermo::~psiQGDThermo
()
119
{}
120
121
122
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
123
124
125
126
bool
Foam::psiQGDThermo::read
()
127
{
128
if
(!basicThermo::read())
129
{
130
return
false
;
131
}
132
133
if
(!
QGDThermo::read
())
134
{
135
return
false
;
136
}
137
138
return
true
;
139
}
140
141
const
Foam::volScalarField&
Foam::psiQGDThermo::c
()
const
142
{
143
return
this->c_;
144
}
145
146
const
Foam::volScalarField&
Foam::psiQGDThermo::p
()
const
147
{
148
return
psiThermo::p
();
149
}
150
151
Foam::volScalarField&
Foam::psiQGDThermo::p
()
152
{
153
return
psiThermo::p
();
154
}
155
156
Foam::tmp<Foam::volScalarField>
Foam::psiQGDThermo::rho
()
const
157
{
158
return
psiThermo::rho
();
159
}
160
161
Foam::tmp<Foam::volScalarField>
Foam::psiQGDThermo::mu
()
const
162
{
163
return
psiThermo::mu();
164
}
165
166
// ************************************************************************* //
Foam::psiQGDThermo::p
virtual const volScalarField & p() const
Definition:
psiQGDThermo.C:139
Foam::psiQGDThermo::~psiQGDThermo
virtual ~psiQGDThermo()
Destructor.
Definition:
psiQGDThermo.C:111
Foam::psiQGDThermo::c
const volScalarField & c() const
Definition:
psiQGDThermo.C:134
psiQGDThermo.H
rho
volScalarField rho(IOobject("rho", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE), thermo.rho())
Foam::QGDThermo::read
virtual bool read()
Definition:
QGDThermo.C:65
Foam::psiQGDThermo::mu
virtual tmp< volScalarField > mu() const
Definition:
psiQGDThermo.C:154
Foam::psiQGDThermo::rho
virtual tmp< volScalarField > rho() const
Definition:
psiQGDThermo.C:149
Foam::psiQGDThermo::New
static autoPtr< psiQGDThermo > New(const fvMesh &mesh, const word &phaseName=word::null)
Selector.
Definition:
psiQGDThermo.C:91
Foam::psiQGDThermo::read
bool read()
Definition:
psiQGDThermo.C:119
Foam::defineRunTimeSelectionTable
defineRunTimeSelectionTable(psiQGDReactionThermo, fvMesh)
p
volScalarField & p
Definition:
createFields.H:14
Foam::psiQGDThermo
Class describing thermophysical properties of perfect gas with motion governed by Quasi- Gas dynamics...
Definition:
psiQGDThermo.H:56
Foam::QGDThermo
Abstract base class for classes implementing thermophysical properties of gases and fluids governed b...
Definition:
QGDThermo.H:52
Foam::psiQGDThermo::psiQGDThermo
psiQGDThermo(const psiQGDThermo &)
Construct as copy (not implemented)
Foam::defineTypeNameAndDebug
defineTypeNameAndDebug(psiQGDReactionThermo, 0)
Generated by
1.8.5