|
|
|
LaunderGibsonRSTM.HGo 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 Class 00026 Foam::compressible::RASModels::LaunderGibsonRSTM 00027 00028 Description 00029 Launder-Gibson Reynolds stress turbulence model for compressible flows. 00030 00031 The default model coefficients correspond to the following: 00032 @verbatim 00033 LaunderGibsonRSTMCoeffs 00034 { 00035 Cmu 0.09; 00036 kappa 0.41; 00037 Clg1 1.8; 00038 Clg2 0.6; 00039 C1 1.44; 00040 C2 1.92; 00041 C1Ref 0.5; 00042 C2Ref 0.3; 00043 Cs 0.25; 00044 Ceps 0.15; 00045 sigmah 1.0; // only for compressible 00046 sigmaEps 1.3; 00047 sigmaR 0.81967; 00048 couplingFactor 0.0; 00049 } 00050 @endverbatim 00051 00052 SourceFiles 00053 LaunderGibsonRSTM.C 00054 LaunderGibsonRSTMcorrect.C 00055 00056 \*---------------------------------------------------------------------------*/ 00057 00058 #ifndef compressibleLaunderGibsonRSTM_H 00059 #define compressibleLaunderGibsonRSTM_H 00060 00061 #include "RASModel.H" 00062 #include "wallDistReflection.H" 00063 00064 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00065 00066 namespace Foam 00067 { 00068 namespace compressible 00069 { 00070 namespace RASModels 00071 { 00072 00073 /*---------------------------------------------------------------------------*\ 00074 Class LaunderGibsonRSTM Declaration 00075 \*---------------------------------------------------------------------------*/ 00076 00077 class LaunderGibsonRSTM 00078 : 00079 public RASModel 00080 { 00081 // Private data 00082 00083 // Model coefficients 00084 00085 dimensionedScalar Cmu_; 00086 dimensionedScalar kappa_; 00087 00088 dimensionedScalar Clg1_; 00089 dimensionedScalar Clg2_; 00090 00091 dimensionedScalar C1_; 00092 dimensionedScalar C2_; 00093 dimensionedScalar Cs_; 00094 dimensionedScalar Ceps_; 00095 00096 dimensionedScalar C1Ref_; 00097 dimensionedScalar C2Ref_; 00098 00099 dimensionedScalar couplingFactor_; 00100 00101 dimensionedScalar sigmaR_; 00102 dimensionedScalar sigmaEps_; 00103 dimensionedScalar Prt_; 00104 00105 00106 // Fields 00107 00108 wallDistReflection y_; 00109 00110 volSymmTensorField R_; 00111 volScalarField k_; 00112 volScalarField epsilon_; 00113 volScalarField mut_; 00114 volScalarField alphat_; 00115 00116 00117 public: 00118 00119 //- Runtime type information 00120 TypeName("LaunderGibsonRSTM"); 00121 00122 // Constructors 00123 00124 //- Construct from components 00125 LaunderGibsonRSTM 00126 ( 00127 const volScalarField& rho, 00128 const volVectorField& U, 00129 const surfaceScalarField& phi, 00130 const basicThermo& thermophysicalModel 00131 ); 00132 00133 00134 //- Destructor 00135 virtual ~LaunderGibsonRSTM() 00136 {} 00137 00138 00139 // Member Functions 00140 00141 //- Return the effective diffusivity for R 00142 tmp<volScalarField> DREff() const 00143 { 00144 return tmp<volScalarField> 00145 ( 00146 new volScalarField("DREff", mut_/sigmaR_ + mu()) 00147 ); 00148 } 00149 00150 //- Return the effective diffusivity for epsilon 00151 tmp<volScalarField> DepsilonEff() const 00152 { 00153 return tmp<volScalarField> 00154 ( 00155 new volScalarField("DepsilonEff", mut_/sigmaEps_ + mu()) 00156 ); 00157 } 00158 00159 //- Return the turbulence viscosity 00160 virtual tmp<volScalarField> mut() const 00161 { 00162 return mut_; 00163 } 00164 00165 //- Return the effective turbulent thermal diffusivity 00166 virtual tmp<volScalarField> alphaEff() const 00167 { 00168 return tmp<volScalarField> 00169 ( 00170 new volScalarField("alphaEff", alphat_ + alpha()) 00171 ); 00172 } 00173 00174 //- Return the turbulence kinetic energy 00175 virtual tmp<volScalarField> k() const 00176 { 00177 return k_; 00178 } 00179 00180 //- Return the turbulence kinetic energy dissipation rate 00181 virtual tmp<volScalarField> epsilon() const 00182 { 00183 return epsilon_; 00184 } 00185 00186 //- Return the Reynolds stress tensor 00187 virtual tmp<volSymmTensorField> R() const 00188 { 00189 return R_; 00190 } 00191 00192 //- Return the effective stress tensor including the laminar stress 00193 virtual tmp<volSymmTensorField> devRhoReff() const; 00194 00195 //- Return the source term for the momentum equation 00196 virtual tmp<fvVectorMatrix> divDevRhoReff(volVectorField& U) const; 00197 00198 //- Solve the turbulence equations and correct the turbulence viscosity 00199 virtual void correct(); 00200 00201 //- Read RASProperties dictionary 00202 virtual bool read(); 00203 }; 00204 00205 00206 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00207 00208 } // End namespace RASModels 00209 } // End namespace compressible 00210 } // End namespace Foam 00211 00212 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00213 00214 #endif 00215 00216 // ************************************************************************* // |