1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
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
13 the Free Software Foundation, either version 3 of the License, or
14 (at your 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, see <http://www.gnu.org/licenses/>.
25 Foam::incompressible::LESModels::homogeneousDynOneEqEddy
28 One Equation Eddy Viscosity Model for incompressible flows.
30 Eddy viscosity SGS model using a modeled balance equation to simulate
35 d/dt(k) + div(U*k) - div(nuSgs*grad(k))
41 B = 2/3*k*I - 2*nuSgs*dev(D)
42 Beff = 2/3*k*I - 2*nuEff*dev(D)
47 nuSgs = ck*sqrt(k)*delta
52 homogeneousDynOneEqEddy.C
54 \*---------------------------------------------------------------------------*/
56 #ifndef homogeneousDynOneEqEddy_H
57 #define homogeneousDynOneEqEddy_H
59 #include "GenEddyVisc.H"
60 #include "LESfilter.H"
62 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
66 namespace incompressible
71 /*---------------------------------------------------------------------------*\
72 Class homogeneousDynOneEqEddy Declaration
73 \*---------------------------------------------------------------------------*/
75 class homogeneousDynOneEqEddy
83 autoPtr<LESfilter> filterPtr_;
87 // Private Member Functions
89 //- Update sub-grid scale fields
90 void updateSubGridScaleFields(const volSymmTensorField& D);
92 //- Calculate ck, ce by filtering the velocity field U.
93 dimensionedScalar ck(const volSymmTensorField& D) const;
94 dimensionedScalar ce(const volSymmTensorField& D) const;
96 // Disallow default bitwise copy construct and assignment
97 homogeneousDynOneEqEddy(const homogeneousDynOneEqEddy&);
98 homogeneousDynOneEqEddy& operator=(const homogeneousDynOneEqEddy&);
103 //- Runtime type information
104 TypeName("homogeneousDynOneEqEddy");
108 //- Construct from components
109 homogeneousDynOneEqEddy
111 const volVectorField& U,
112 const surfaceScalarField& phi,
113 transportModel& transport,
114 const word& turbulenceModelName = turbulenceModel::typeName,
115 const word& modelName = typeName
120 virtual ~homogeneousDynOneEqEddy()
126 //- Return SGS kinetic energy
127 virtual tmp<volScalarField> k() const
132 //- Return the effective diffusivity for k
133 tmp<volScalarField> DkEff() const
135 return tmp<volScalarField>
137 new volScalarField("DkEff", nuSgs_ + nu())
141 //- Correct Eddy-Viscosity and related properties
142 virtual void correct(const tmp<volTensorField>& gradU);
144 //- Read LESProperties dictionary
149 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
151 } // End namespace LESModels
152 } // End namespace incompressible
153 } // End namespace Foam
155 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
159 // ************************************************************************* //