initial commit for version 1.5.x patch release
[OpenFOAM-1.5.x.git] / applications / solvers / heatTransfer / lesBuoyantFoam / lesBuoyantFoam.C
blobba0e6349d54ccbbf7cebb0f52ecdcd3a76ba2e51
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2008 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
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 the
13     Free Software Foundation; either version 2 of the License, or (at your
14     option) any later version.
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.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM; if not, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 Application
26     lesBuoyantFoam
28 Description
29     Transient Solver for buoyant, turbulent flow of compressible fluids for
30     ventilation and heat-transfer.  Turbulence is modelled using a run-time
31     selectable compressible LES model.
33 \*---------------------------------------------------------------------------*/
35 #include "fvCFD.H"
36 #include "basicThermo.H"
37 #include "compressible/LESModel/LESModel.H"
39 #define divDevRhoReff divDevRhoBeff
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 int main(int argc, char *argv[])
46 #   include "setRootCase.H"
47 #   include "createTime.H"
48 #   include "createMesh.H"
49 #   include "readEnvironmentalProperties.H"
50 #   include "initContinuityErrs.H"
51 #   include "createFields.H"
52 #   include "readTimeControls.H"
53 #   include "compressibleCourantNo.H"
54 #   include "setInitialDeltaT.H"
56 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
58     Info<< "\nStarting time loop\n" << endl;
60     while (runTime.run())
61     {
62 #       include "readPISOControls.H"
63 #       include "readTimeControls.H"
64 #       include "compressibleCourantNo.H"
65 #       include "setDeltaT.H"
67         runTime++;
68         Info<< "Time = " << runTime.timeName() << nl << endl;
70 #       include "rhoEqn.H"
72         turbulence->correct();
74 #       include "UEqn.H"
75 #       include "hEqn.H"
77         // --- PISO loop
78         for (int corr=0; corr<nCorr; corr++)
79         {
80 #           include "pEqn.H"
81         }
83         runTime.write();
85         Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
86             << "  ClockTime = " << runTime.elapsedClockTime() << " s"
87             << nl << endl;
88     }
90     Info<< "End\n" << endl;
92     return 0;
96 // ************************************************************************* //