|
|
|
XiFoam.CGo to the documentation of this file.00001 /*---------------------------------------------------------------------------*\ 00002 ========= | 00003 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox 00004 \\ / O peration | 00005 \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd. 00006 \\/ M anipulation | 00007 ------------------------------------------------------------------------------- 00008 License 00009 This file is part of OpenFOAM. 00010 00011 OpenFOAM is free software; you can redistribute it and/or modify it 00012 under the terms of the GNU General Public License as published by the 00013 Free Software Foundation; either version 2 of the License, or (at your 00014 option) any later version. 00015 00016 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT 00017 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00018 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 00019 for more details. 00020 00021 You should have received a copy of the GNU General Public License 00022 along with OpenFOAM; if not, write to the Free Software Foundation, 00023 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00024 00025 Application 00026 XiFoam 00027 00028 Description 00029 Solver for compressible premixed/partially-premixed combustion with 00030 turbulence modelling. 00031 00032 Combusting RANS code using the b-Xi two-equation model. 00033 Xi may be obtained by either the solution of the Xi transport 00034 equation or from an algebraic exression. Both approaches are 00035 based on Gulder's flame speed correlation which has been shown 00036 to be appropriate by comparison with the results from the 00037 spectral model. 00038 00039 Strain effects are encorporated directly into the Xi equation 00040 but not in the algebraic approximation. Further work need to be 00041 done on this issue, particularly regarding the enhanced removal rate 00042 caused by flame compression. Analysis using results of the spectral 00043 model will be required. 00044 00045 For cases involving very lean Propane flames or other flames which are 00046 very strain-sensitive, a transport equation for the laminar flame 00047 speed is present. This equation is derived using heuristic arguments 00048 involving the strain time scale and the strain-rate at extinction. 00049 the transport velocity is the same as that for the Xi equation. 00050 00051 \*---------------------------------------------------------------------------*/ 00052 00053 #include "fvCFD.H" 00054 #include "hhuCombustionThermo.H" 00055 #include "turbulenceModel.H" 00056 #include "laminarFlameSpeed.H" 00057 #include "ignition.H" 00058 #include "Switch.H" 00059 00060 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00061 00062 int main(int argc, char *argv[]) 00063 { 00064 #include "setRootCase.H" 00065 00066 #include "createTime.H" 00067 #include "createMesh.H" 00068 #include "readCombustionProperties.H" 00069 #include "readGravitationalAcceleration.H" 00070 #include "createFields.H" 00071 #include "initContinuityErrs.H" 00072 #include "readTimeControls.H" 00073 #include "compressibleCourantNo.H" 00074 #include "setInitialDeltaT.H" 00075 00076 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00077 00078 Info<< "\nStarting time loop\n" << endl; 00079 00080 while (runTime.run()) 00081 { 00082 #include "readTimeControls.H" 00083 #include "readPISOControls.H" 00084 #include "compressibleCourantNo.H" 00085 #include "setDeltaT.H" 00086 00087 runTime++; 00088 Info<< "Time = " << runTime.timeName() << nl << endl; 00089 00090 // --- Pressure-velocity PIMPLE corrector loop 00091 for (int oCorr=0; oCorr<nOuterCorr; oCorr++) 00092 { 00093 #include "rhoEqn.H" 00094 #include "UEqn.H" 00095 00096 #include "ftEqn.H" 00097 #include "bEqn.H" 00098 #include "huEqn.H" 00099 #include "hEqn.H" 00100 00101 if (!ign.ignited()) 00102 { 00103 hu == h; 00104 } 00105 00106 // --- PISO loop 00107 for (int corr=1; corr<=nCorr; corr++) 00108 { 00109 #include "pEqn.H" 00110 } 00111 00112 turbulence->correct(); 00113 } 00114 00115 rho = thermo.rho(); 00116 00117 runTime.write(); 00118 00119 Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s" 00120 << " ClockTime = " << runTime.elapsedClockTime() << " s" 00121 << nl << endl; 00122 } 00123 00124 Info<< "End\n" << endl; 00125 00126 return 0; 00127 } 00128 00129 00130 // ************************************************************************* // |