LESdelta.H
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ========= |
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 \\ / O peration |
5 \\ / A nd | www.openfoam.com
6 \\/ M anipulation |
7-------------------------------------------------------------------------------
8 Copyright (C) 2011-2015 OpenFOAM Foundation
9 Copyright (C) 2019-2021 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::LESdelta
29
30Description
31 Abstract base class for LES deltas
32
33SourceFiles
34 LESdelta.C
35
36\*---------------------------------------------------------------------------*/
37
38#ifndef LESdelta_H
39#define LESdelta_H
40
41#include "turbulenceModel.H"
42#include "volFields.H"
44
45// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47namespace Foam
48{
49
50/*---------------------------------------------------------------------------*\
51 Class LESdelta Declaration
52\*---------------------------------------------------------------------------*/
54class LESdelta
55{
56protected:
57
58 // Protected Data
63
64
65 // Protected Member Functions
66
67 //- No copy construct
68 LESdelta(const LESdelta&) = delete;
69
70 //- No copy assignment
71 void operator=(const LESdelta&) = delete;
72
73
74public:
75
76 //- Runtime type information
77 TypeName("LESdelta");
78
79
80 // Declare run-time constructor selection table
83 (
84 autoPtr,
87 (
88 const word& name,
90 const dictionary& dict
91 ),
93 );
94
95
96 // Constructors
97
98 //- Construct from name, turbulenceModel and dictionary
100 (
101 const word& name,
103 );
104
105
106 // Selectors
107
108 //- Return a reference to the selected LES delta
110 (
111 const word& name,
113 const dictionary& dict,
114 const word& lookupName = "delta"
115 );
116
117 //- Return a reference to the selected LES delta
119 (
120 const word& name,
122 const dictionary& dict,
123 const dictionaryConstructorTableType& additionalConstructors,
124 const word& lookupName = "delta"
125 );
126
127
128 //- Destructor
129 virtual ~LESdelta() = default;
130
131
132 // Member Functions
133
134 //- Return turbulenceModel reference
135 const turbulenceModel& turbulence() const
136 {
137 return turbulenceModel_;
138 }
139
140 //- Read the LESdelta dictionary
141 virtual void read(const dictionary&) = 0;
142
143 // Correct values
144 virtual void correct() = 0;
145
146
147 // Member Operators
149 virtual operator const volScalarField&() const
150 {
151 return delta_;
152 }
153};
154
155
156// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
157
158} // End namespace Foam
159
160// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
161
162#endif
163
164// ************************************************************************* //
Abstract base class for LES deltas.
Definition: LESdelta.H:54
LESdelta(const LESdelta &)=delete
No copy construct.
static autoPtr< LESdelta > New(const word &name, const turbulenceModel &turbulence, const dictionary &dict, const word &lookupName="delta")
Return a reference to the selected LES delta.
Definition: LESdelta.C:69
virtual void read(const dictionary &)=0
Read the LESdelta dictionary.
const turbulenceModel & turbulence() const
Return turbulenceModel reference.
Definition: LESdelta.H:134
virtual void correct()=0
volScalarField delta_
Definition: LESdelta.H:61
declareRunTimeSelectionTable(autoPtr, LESdelta, dictionary,(const word &name, const turbulenceModel &turbulence, const dictionary &dict),(name, turbulence, dict))
virtual ~LESdelta()=default
Destructor.
void operator=(const LESdelta &)=delete
No copy assignment.
TypeName("LESdelta")
Runtime type information.
const turbulenceModel & turbulenceModel_
Definition: LESdelta.H:59
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
Abstract base class for turbulence models (RAS, LES and laminar).
A class for handling words, derived from Foam::string.
Definition: word.H:68
Namespace for OpenFOAM.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
Definition: exprTraits.C:59
Macros to ease declaration of run-time selection tables.
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes)
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73