initial commit for version 1.5.x patch release
[OpenFOAM-1.5.x.git] / src / turbulenceModels / LES / LESdeltas / LESdelta / LESdelta.H
blobfa13c45c32fdd4f290829de7b4e23608eef82606
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2008 OpenCFD Ltd.
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
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 the
13     Free Software Foundation; either version 2 of the License, or (at your
14     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
19     for more details.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM; if not, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 Class
26     Foam::LESdelta
28 Description
29     Abstract base class for LES deltas
31 SourceFiles
32     LESdelta.C
33     newDelta.C
35 \*---------------------------------------------------------------------------*/
37 #ifndef LESdelta_H
38 #define LESdelta_H
40 #include "volFields.H"
41 #include "typeInfo.H"
42 #include "autoPtr.H"
43 #include "runTimeSelectionTables.H"
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 namespace Foam
50 class fvMesh;
52 /*---------------------------------------------------------------------------*\
53                            Class LESdelta Declaration
54 \*---------------------------------------------------------------------------*/
56 class LESdelta
59 protected:
61     // Protected data
63         const fvMesh& mesh_;
65         volScalarField delta_;
68 private:
70     // Private Member Functions
72         // Disallow default bitwise copy construct and assignment
73         LESdelta(const LESdelta&);
74         void operator=(const LESdelta&);
77 public:
79     //- Runtime type information
80     TypeName("LESdelta");
83     // Declare run-time constructor selection table
85         declareRunTimeSelectionTable
86         (
87             autoPtr,
88             LESdelta,
89             dictionary,
90             (
91                 const word& name,
92                 const fvMesh& mesh,
93                 const dictionary& LESdeltaDict
94             ),
95             (name, mesh, LESdeltaDict)
96         );
99     // Constructors
101         //- Construct from name and mesh
102         LESdelta(const word& name, const fvMesh& mesh);
105     // Selectors
107         //- Return a reference to the selected LES delta
108         static autoPtr<LESdelta> New
109         (
110             const word& name,
111             const fvMesh& mesh,
112             const dictionary& LESdeltaDict
113         );
116     // Destructor
118         virtual ~LESdelta()
119         {}
122     // Member Functions
124         //- Return mesh reference
125         const fvMesh& mesh() const
126         {
127             return mesh_;
128         }
130         //- Read the LESdelta dictionary
131         virtual void read(const dictionary&) = 0;
133         // Correct values
134         virtual void correct() = 0;
137     // Member Operators
139         virtual operator const volScalarField&() const
140         {
141             return delta_;
142         }
146 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
148 } // End namespace Foam
150 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
152 #endif
154 // ************************************************************************* //