icoUncoupledKinematicCloud.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2016-2018 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
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.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::functionObjects::icoUncoupledKinematicCloud
26 
27 Description
28  This functionObject tracks a uncoupled kinematic particle cloud in the
29  specified velocity field of an incompressible flow (laminar, RANS or LES).
30 
31  It may be used in conjunction with any transient single-phase incompressible
32  flow solver such as pisoFoam or pimpleFoam and tracks the particles or
33  parcels without affecting the flow-field.
34 
35  The kinematicCloud requires the density of the fluid which is looked-up
36  from constant/transportProperties dictionary and the acceleration due to
37  gravity which is read from the constant/g file if present or defaults to
38  zero.
39 
40  The kinematicCloud properties are read from the
41  constant/kinematicCloudProperties dictionary in the usual manner.
42 
43  Example of function object specification:
44  \verbatim
45  tracks
46  {
47  libs ("liblagrangianFunctionObjects.so");
48  type icoUncoupledKinematicCloud;
49  }
50  \endverbatim
51 
52 Usage
53  \table
54  Property | Description | Required | Default value
55  type | Type name: icoUncoupledKinematicCloud | yes |
56  U | Name of the velocity field | no | U
57  kinematicCloud | Name of the kinematicCloud | no | kinematicCloud
58  \endtable
59 
60 See also
61  Foam::functionObjects::fvMeshFunctionObject
62 
63 SourceFiles
64  icoUncoupledKinematicCloud.C
65 
66 \*---------------------------------------------------------------------------*/
67 
68 #ifndef functionObjects_icoUncoupledKinematicCloud_H
69 #define functionObjects_icoUncoupledKinematicCloud_H
70 
71 #include "fvMeshFunctionObject.H"
73 #include "volFields.H"
75 
76 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
77 
78 namespace Foam
79 {
80 
81 class singlePhaseTransportModel;
82 
83 namespace functionObjects
84 {
85 
86 /*---------------------------------------------------------------------------*\
87  Class icoUncoupledKinematicCloud Declaration
88 \*---------------------------------------------------------------------------*/
89 
90 class icoUncoupledKinematicCloud
91 :
92  public fvMeshFunctionObject
93 {
94  // Private member data
95 
96  //- Optional acceleration due to gravity
98 
99  //- Reference to the laminar transport model
100  const singlePhaseTransportModel& laminarTransport_;
101 
102  //- Uniform density value
103  dimensionedScalar rhoValue_;
104 
105  //- Density field needed to construct kinematicCloud
106  volScalarField rho_;
107 
108  //- Dynamic viscosity field needed to construct kinematicCloud
110 
111  //- Reference to the velocity field
112  const volVectorField& U_;
113 
114  //- Name of the cloud
115  word kinematicCloudName_;
116 
117  //- The kinematic cloud
118  basicKinematicCollidingCloud kinematicCloud_;
119 
120 
121  // Private member functions
122 
123  //- Disallow default bitwise copy construct
125 
126  //- Disallow default bitwise assignment
127  void operator==(const icoUncoupledKinematicCloud&);
128 
129 
130 public:
131 
132  //- Runtime type information
133  TypeName("icoUncoupledKinematicCloud");
134 
135 
136  // Constructors
137 
138  //- Construct for given objectRegistry and dictionary.
139  // Allow the possibility to load fields from files
141  (
142  const word& name,
143  const Time& runTime,
144  const dictionary& dict
145  );
146 
147 
148  //- Destructor
149  virtual ~icoUncoupledKinematicCloud();
150 
151 
152  // Member Functions
153 
154  //- Read the controls
155  virtual bool read(const dictionary&);
156 
157  //- Track the cloud
158  virtual bool execute();
159 
160  //- Write the cloud
161  virtual bool write();
162 };
163 
164 
165 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
166 
167 } // End namespace functionObjects
168 } // End namespace Foam
169 
170 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
171 
172 #endif
173 
174 // ************************************************************************* //
Cloud class to introduce kinematic colliding parcels.
dictionary dict
const word & name() const
Return the name of this functionObject.
UniformDimensionedField< vector > uniformDimensionedVectorField
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:137
engineTime & runTime
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:68
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:52
A class for handling words, derived from string.
Definition: word.H:59
TypeName("icoUncoupledKinematicCloud")
Runtime type information.
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
virtual bool read(const dictionary &)
Read the controls.
This functionObject tracks a uncoupled kinematic particle cloud in the specified velocity field of an...
Namespace for OpenFOAM.