reactingParcelFoam.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-2015 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  reactingParcelFoam
26 
27 Group
28  grpLagrangianSolvers
29 
30 Description
31  Transient PIMPLE solver for compressible, laminar or turbulent flow with
32  reacting multiphase Lagrangian parcels.
33 
34  Note:
35  - includes run-time selectable finite volume options, e.g. sources,
36  constraints
37 
38 \*---------------------------------------------------------------------------*/
39 
40 #include "fvCFD.H"
43 #include "rhoCombustionModel.H"
44 #include "radiationModel.H"
45 #include "fvOptions.H"
46 #include "SLGThermo.H"
47 #include "pimpleControl.H"
48 #include "localEulerDdtScheme.H"
49 #include "fvcSmooth.H"
50 
51 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
52 
53 int main(int argc, char *argv[])
54 {
55  #include "setRootCase.H"
56 
57  #include "createTime.H"
58  #include "createMesh.H"
59  #include "readGravitationalAcceleration.H"
60 
61  pimpleControl pimple(mesh);
62 
63  #include "createTimeControls.H"
64  #include "createRDeltaT.H"
65  #include "initContinuityErrs.H"
66  #include "createFields.H"
67  #include "createRadiationModel.H"
68  #include "createClouds.H"
69  #include "createMRF.H"
70  #include "createFvOptions.H"
71 
72  turbulence->validate();
73 
74  if (!LTS)
75  {
76  #include "compressibleCourantNo.H"
77  #include "setInitialDeltaT.H"
78  }
79 
80  // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
81 
82  Info<< "\nStarting time loop\n" << endl;
83 
84  while (runTime.run())
85  {
86  #include "readTimeControls.H"
87 
88  if (!LTS)
89  {
90  #include "compressibleCourantNo.H"
91  #include "setDeltaT.H"
92  }
93 
94  runTime++;
95 
96  Info<< "Time = " << runTime.timeName() << nl << endl;
97 
98  parcels.evolve();
99 
100  if (LTS)
101  {
102  #include "setRDeltaT.H"
103  }
104 
105  #include "rhoEqn.H"
106 
107  // --- Pressure-velocity PIMPLE corrector loop
108  while (pimple.loop())
109  {
110  #include "UEqn.H"
111  #include "YEqn.H"
112  #include "EEqn.H"
113 
114  // --- Pressure corrector loop
115  while (pimple.correct())
116  {
117  #include "pEqn.H"
118  }
119 
120  if (pimple.turbCorr())
121  {
122  turbulence->correct();
123  }
124  }
125 
126  rho = thermo.rho();
127 
128  runTime.write();
129 
130  Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
131  << " ClockTime = " << runTime.elapsedClockTime() << " s"
132  << nl << endl;
133  }
134 
135  Info<< "End\n" << endl;
136 
137  return 0;
138 }
139 
140 
141 // ************************************************************************* //
basicReactingMultiphaseCloud.H
fvOptions.H
thermo
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
createRDeltaT.H
Foam::endl
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:251
createRadiationModel.H
SLGThermo.H
pimpleControl.H
createFvOptions.H
localEulerDdtScheme.H
turbulence
autoPtr< compressible::turbulenceModel > turbulence
Definition: createFields.H:23
Foam::nl
static const char nl
Definition: Ostream.H:260
Foam::Info
messageStream Info
main
int main(int argc, char *argv[])
Definition: postCalc.C:54
LTS
bool LTS
Definition: createRDeltaT.H:1
mesh
dynamicFvMesh & mesh
Definition: createDynamicFvMesh.H:18
rho
rho
Definition: pEqn.H:3
setRootCase.H
createTimeControls.H
Read the control parameters used by setDeltaT.
readTimeControls.H
Read the control parameters used by setDeltaT.
createMesh.H
createTime.H
fvCFD.H
pimple
const dictionary & pimple
Definition: readFluidMultiRegionPIMPLEControls.H:1
radiationModel.H
rhoCombustionModel.H
turbulentFluidThermoModel.H
fvcSmooth.H
Provides functions smooth spread and sweep which use the FaceCellWave algorithm to smooth and redistr...