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