1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend 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 3 of the License, or (at your
14 option) any later version.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
24 \*---------------------------------------------------------------------------*/
27 #include "addToRunTimeSelectionTable.H"
29 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
33 namespace incompressible
38 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
40 defineTypeNameAndDebug(laminar, 0);
41 addToRunTimeSelectionTable(LESModel, laminar, dictionary);
44 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
48 const volVectorField& U,
49 const surfaceScalarField& phi,
50 transportModel& transport
53 LESModel(typeName, U, phi, transport)
57 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
59 tmp<volScalarField> laminar::k() const
61 return tmp<volScalarField>
74 dimensionedScalar("k", sqr(U().dimensions()), 0.0)
79 tmp<volScalarField> laminar::epsilon() const
81 return 2*nu()*magSqr(symm(fvc::grad(U())));
84 tmp<volScalarField> laminar::nuSgs() const
86 return tmp<volScalarField>
99 dimensionedScalar("nuSgs", nu().dimensions(), 0.0)
104 tmp<volScalarField> laminar::nuEff() const
106 return tmp<volScalarField>
108 new volScalarField("nuEff", nu())
113 tmp<volSymmTensorField> laminar::B() const
115 return tmp<volSymmTensorField>
117 new volSymmTensorField
128 dimensionedSymmTensor
130 "B", sqr(U().dimensions()), symmTensor::zero
137 tmp<volSymmTensorField> laminar::devBeff() const
139 return -nu()*dev(twoSymm(fvc::grad(U())));
143 tmp<fvVectorMatrix> laminar::divDevBeff(volVectorField& U) const
147 - fvm::laplacian(nu(), U) - fvc::div(nu()*dev(fvc::grad(U)().T()))
154 return LESModel::read();
158 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
160 } // End namespace LESModels
161 } // End namespace incompressible
162 } // End namespace Foam
164 // ************************************************************************* //