icoUncoupledKinematicCloud.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) 2016 OpenFOAM Foundation
9 Copyright (C) 2020 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::functionObjects::icoUncoupledKinematicCloud
29
30Group
31 grpLagrangianFunctionObjects
32
33Description
34 This functionObject tracks a uncoupled kinematic particle cloud in the
35 specified velocity field of an incompressible flow (laminar, RANS or LES).
36
37 It may be used in conjunction with any transient single-phase incompressible
38 flow solver such as pisoFoam or pimpleFoam and tracks the particles or
39 parcels without affecting the flow-field.
40
41 The kinematicCloud requires the density of the fluid which is looked-up
42 from constant/transportProperties dictionary and the acceleration due to
43 gravity which is read from the constant/g file if present or defaults to
44 zero.
45
46 The kinematicCloud properties are read from the
47 constant/kinematicCloudProperties dictionary in the usual manner.
48
49Usage
50 Example of function object specification:
51 \verbatim
52 tracks
53 {
54 type icoUncoupledKinematicCloud;
55 libs (lagrangianFunctionObjects);
56 }
57 \endverbatim
58
59 Where the entries comprise:
60 \table
61 Property | Description | Required | Default value
62 type | Type name: icoUncoupledKinematicCloud | yes |
63 U | Name of the velocity field | no | U
64 kinematicCloud | Name of the kinematicCloud | no | kinematicCloud
65 \endtable
66
67See also
68 Foam::functionObjects::fvMeshFunctionObject
69
70SourceFiles
71 icoUncoupledKinematicCloud.C
72
73\*---------------------------------------------------------------------------*/
74
75#ifndef functionObjects_icoUncoupledKinematicCloud_H
76#define functionObjects_icoUncoupledKinematicCloud_H
77
80#include "volFields.H"
82
83// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
84
85namespace Foam
86{
87
88class singlePhaseTransportModel;
89
90namespace functionObjects
91{
92
93/*---------------------------------------------------------------------------*\
94 Class icoUncoupledKinematicCloud Declaration
95\*---------------------------------------------------------------------------*/
96
97class icoUncoupledKinematicCloud
98:
99 public fvMeshFunctionObject
100{
101 // Private member data
102
103 //- Optional acceleration due to gravity
105
106 //- Reference to the laminar transport model
107 const singlePhaseTransportModel& laminarTransport_;
108
109 //- Uniform density value
110 dimensionedScalar rhoValue_;
111
112 //- Density field needed to construct kinematicCloud
113 volScalarField rho_;
114
115 //- Dynamic viscosity field needed to construct kinematicCloud
117
118 //- Reference to the velocity field
119 const volVectorField& U_;
120
121 //- Name of the cloud
122 word kinematicCloudName_;
123
124 //- The kinematic cloud
125 basicKinematicCollidingCloud kinematicCloud_;
126
127
128 // Private member functions
129
130 //- No copy construct
132
133 //- No copy assignment
134 void operator==(const icoUncoupledKinematicCloud&) = delete;
135
136
137public:
138
139 //- Runtime type information
140 TypeName("icoUncoupledKinematicCloud");
141
142
143 // Constructors
144
145 //- Construct for given objectRegistry and dictionary.
146 // Allow the possibility to load fields from files
148 (
149 const word& name,
150 const Time& runTime,
151 const dictionary& dict
152 );
153
154
155 //- Destructor
157
158
159 // Member Functions
160
161 //- Read the controls
162 virtual bool read(const dictionary&);
163
164 //- Track the cloud
165 virtual bool execute();
166
167 //- Write the cloud
168 virtual bool write();
169};
170
171
172// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
173
174} // End namespace functionObjects
175} // End namespace Foam
176
177// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
178
179#endif
180
181// ************************************************************************* //
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:80
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
const word & name() const noexcept
Return the name of this functionObject.
Specialization of Foam::functionObject for an Foam::fvMesh, providing a reference to the Foam::fvMesh...
This functionObject tracks a uncoupled kinematic particle cloud in the specified velocity field of an...
TypeName("icoUncoupledKinematicCloud")
Runtime type information.
virtual bool read(const dictionary &)
Read the controls.
A simple single-phase transport model based on viscosityModel.
A class for handling words, derived from Foam::string.
Definition: word.H:68
engineTime & runTime
Namespace for OpenFOAM.
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:82
UniformDimensionedField< vector > uniformDimensionedVectorField
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73