turbGen.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 OpenFOAM Foundation
9-------------------------------------------------------------------------------
10License
11 This file is part of OpenFOAM.
12
13 OpenFOAM is free software: you can redistribute it and/or modify it
14 under the terms of the GNU General Public License as published by
15 the Free Software Foundation, either version 3 of the License, or
16 (at your option) any later version.
17
18 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 for more details.
22
23 You should have received a copy of the GNU General Public License
24 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25
26Class
27 Foam::turbGen
28
29Description
30 Generate a turbulent velocity field conforming to a given
31 energy spectrum and being divergence free.
32
33SourceFiles
34 turbGen.C
35 turbGenIO.C
36
37\*---------------------------------------------------------------------------*/
38
39#ifndef turbGen_H
40#define turbGen_H
41
42#include "Random.H"
43#include "primitiveFields.H"
44
45// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47namespace Foam
48{
49
50class Kmesh;
51
52/*---------------------------------------------------------------------------*\
53 Class turbGen Declaration
54\*---------------------------------------------------------------------------*/
56class turbGen
57{
58 // Private data
59
60 const Kmesh& K;
61 const scalar Ea;
62 const scalar k0;
63 Random RanGen;
64
65
66public:
67
68 // Constructors
69
70 //- Construct from components
71 turbGen(const Kmesh& k, const scalar EA, const scalar K0);
72
73
74 // Member Functions
75
76 //- Generate and return a velocity field
77 vectorField U();
78};
79
80
81// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
82
83} // End namespace Foam
84
85// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
86
87#endif
88
89// ************************************************************************* //
CGAL::Exact_predicates_exact_constructions_kernel K
label k
Calculate the wavenumber vector field corresponding to the space vector field of a finite volume mesh...
Definition: Kmesh.H:54
Random number generator.
Definition: Random.H:60
Generate a turbulent velocity field conforming to a given energy spectrum and being divergence free.
Definition: turbGen.H:56
vectorField U()
Generate and return a velocity field.
Definition: turbGen.C:50
Namespace for OpenFOAM.
Specialisations of Field<T> for scalar, vector and tensor.