OpenFOAM
4.1
The OpenFOAM Foundation
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
applications
solvers
lagrangian
sprayFoam
sprayFoam.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 | Copyright (C) 2011-2016 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
Application
25
sprayFoam
26
27
Description
28
Transient solver for compressible, turbulent flow with a spray particle
29
cloud.
30
31
\*---------------------------------------------------------------------------*/
32
33
#include "
fvCFD.H
"
34
#include "
turbulentFluidThermoModel.H
"
35
#include "
basicSprayCloud.H
"
36
#include "
psiCombustionModel.H
"
37
#include "
radiationModel.H
"
38
#include "
SLGThermo.H
"
39
#include "
pimpleControl.H
"
40
#include "
fvOptions.H
"
41
42
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43
44
int
main(
int
argc,
char
*argv[])
45
{
46
#include "
postProcess.H
"
47
48
#include "
setRootCase.H
"
49
#include "
createTime.H
"
50
#include "
createMesh.H
"
51
#include "createControl.H"
52
#include "
createTimeControls.H
"
53
#include "createFields.H"
54
#include "createFieldRefs.H"
55
#include "
createFvOptions.H
"
56
#include "compressibleCourantNo.H"
57
#include "setInitialDeltaT.H"
58
#include "initContinuityErrs.H"
59
60
turbulence
->validate();
61
62
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
63
64
Info
<<
"\nStarting time loop\n"
<<
endl
;
65
66
while
(runTime.run())
67
{
68
#include "
readTimeControls.H
"
69
#include "compressibleCourantNo.H"
70
#include "setDeltaT.H"
71
72
runTime++;
73
74
Info
<<
"Time = "
<< runTime.timeName() <<
nl
<<
endl
;
75
76
parcels.evolve();
77
78
#include "rhoEqn.H"
79
80
// --- Pressure-velocity PIMPLE corrector loop
81
while
(
pimple
.loop())
82
{
83
#include "UEqn.H"
84
#include "YEqn.H"
85
#include "EEqn.H"
86
87
// --- Pressure corrector loop
88
while
(
pimple
.correct())
89
{
90
#include "pEqn.H"
91
}
92
93
if
(
pimple
.turbCorr())
94
{
95
turbulence
->correct();
96
}
97
}
98
99
rho
=
thermo
.rho();
100
101
if
(runTime.write())
102
{
103
combustion
->dQ()().
write
();
104
}
105
106
Info
<<
"ExecutionTime = "
<< runTime.elapsedCpuTime() <<
" s"
107
<<
" ClockTime = "
<< runTime.elapsedClockTime() <<
" s"
108
<<
nl
<<
endl
;
109
}
110
111
Info
<<
"End\n"
<<
endl
;
112
113
return
0;
114
}
115
116
117
// ************************************************************************* //
turbulence
autoPtr< compressible::turbulenceModel > turbulence
Definition:
createFields.H:23
fvCFD.H
combustion
Info<< "Creating combustion model\n"<< endl;autoPtr< combustionModels::psiCombustionModel > combustion(combustionModels::psiCombustionModel::New(mesh))
createFvOptions.H
radiationModel.H
pimple
const dictionary & pimple
Definition:
readFluidMultiRegionPIMPLEControls.H:1
Foam::endl
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition:
Ostream.H:253
readTimeControls.H
Read the control parameters used by setDeltaT.
createTime.H
basicSprayCloud.H
turbulentFluidThermoModel.H
thermo
psiReactionThermo & thermo
Definition:
createFields.H:31
rho
rho
Definition:
readInitialConditions.H:96
psiCombustionModel.H
Foam::nl
static const char nl
Definition:
Ostream.H:262
createMesh.H
fvOptions.H
setRootCase.H
pimpleControl.H
Foam::Info
messageStream Info
SLGThermo.H
postProcess.H
Execute application functionObjects to post-process existing results.
write
runTime write()
createTimeControls.H
Read the control parameters used by setDeltaT.
Generated by
1.8.11