1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
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
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
29 Combination of heatConductionFoam and buoyantFoam for conjugate heat
30 transfer between a solid region and fluid region
32 \*---------------------------------------------------------------------------*/
35 #include "basicPsiThermo.H"
36 #include "turbulenceModel.H"
37 #include "fixedGradientFvPatchFields.H"
38 #include "regionProperties.H"
39 #include "compressibleCourantNo.H"
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 int main(int argc, char *argv[])
45 #include "setRootCase.H"
46 #include "createTime.H"
48 regionProperties rp(runTime);
50 #include "createFluidMeshes.H"
51 #include "createSolidMeshes.H"
53 #include "createFluidFields.H"
54 #include "createSolidFields.H"
56 #include "initContinuityErrs.H"
58 #include "readTimeControls.H"
60 if (fluidRegions.size())
62 #include "compressibleMultiRegionCourantNo.H"
63 #include "setInitialDeltaT.H"
68 #include "readTimeControls.H"
69 #include "readPIMPLEControls.H"
71 if (fluidRegions.size())
73 #include "compressibleMultiRegionCourantNo.H"
74 #include "setDeltaT.H"
79 Info<< "Time = " << runTime.timeName() << nl << endl;
83 forAll(fluidRegions, i)
85 #include "setRegionFluidFields.H"
86 #include "storeOldFluidFields.H"
92 for (int oCorr=0; oCorr<nOuterCorr; oCorr++)
94 forAll(fluidRegions, i)
96 Info<< "\nSolving for fluid region "
97 << fluidRegions[i].name() << endl;
98 #include "setRegionFluidFields.H"
99 #include "readFluidMultiRegionPIMPLEControls.H"
100 #include "solveFluid.H"
103 forAll(solidRegions, i)
105 Info<< "\nSolving for solid region "
106 << solidRegions[i].name() << endl;
107 #include "setRegionSolidFields.H"
108 #include "readSolidMultiRegionPIMPLEControls.H"
109 #include "solveSolid.H"
115 Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
116 << " ClockTime = " << runTime.elapsedClockTime() << " s"
120 Info << "End\n" << endl;
126 // ************************************************************************* //