All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
parcelCloud.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) 2020-2021 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::parcelCloud
26 
27 Description
28  Virtual abstract base class for parcel clouds. As parcelCloudBase but with
29  additional virtualisation of the evolve method, plus some additional
30  methods that are defined below the parcel-cloud layer (i.e., in Cloud).
31  These methods are implemented by forwarding in the ParcelCloud class.
32 
33  This class contains the selection table and represents the high level
34  interface used by a solver.
35 
36 SourceFiles
37  parcelCloud.C
38 
39 \*---------------------------------------------------------------------------*/
40 
41 #ifndef parcelCloud_H
42 #define parcelCloud_H
43 
44 #include "parcelCloudBase.H"
45 
46 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 
48 namespace Foam
49 {
50 
51 class fluidThermo;
52 
53 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 
55 class parcelCloud
56 :
57  virtual public parcelCloudBase
58 {
59 public:
60 
61  //- Runtime type information
62  TypeName("parcelCloud");
63 
64 
65  // Declare viscosity-based runtime construction
67  (
68  autoPtr,
70  viscosity,
71  (
72  const word& name,
73  const volScalarField& rho,
74  const volVectorField& U,
75  const volScalarField& mu,
76  const dimensionedVector& g
77  ),
78  (name, rho, U, mu, g)
79  );
80 
81  // Declare thermo-based runtime construction
83  (
84  autoPtr,
86  thermo,
87  (
88  const word& name,
89  const volScalarField& rho,
90  const volVectorField& U,
91  const dimensionedVector& g,
92  const fluidThermo& carrierThermo
93  ),
94  (name, rho, U, g, carrierThermo)
95  );
96 
97 
98  // Constructors
99 
100  //- Null constructor
101  parcelCloud();
102 
103  //- Disallow default bitwise copy construction
104  parcelCloud(const parcelCloud&) = delete;
105 
106 
107  //- Selectors
108 
109  //- Select and construct with given carrier fields
111  (
112  const word& name,
113  const volScalarField& rho,
114  const volVectorField& U,
115  const volScalarField& mu,
116  const dimensionedVector& g
117  );
118 
119  //- Select and construct with given carrier fields and thermo
121  (
122  const word& name,
123  const volScalarField& rho,
124  const volVectorField& U,
125  const dimensionedVector& g,
126  const fluidThermo& carrierThermo
127  );
128 
129 
130  //- Destructor
131  virtual ~parcelCloud();
132 
133 
134  // Member Functions
135 
136  //- Call this before a topology change. Stores the particles global
137  // positions in the database for use during mapping.
138  virtual void storeGlobalPositions() = 0;
139 
140 
141  // Evolution
142 
143  //- Evolve the cloud
144  virtual void evolve() = 0;
145 
146 
147  // Member Operators
148 
149  //- Disallow default bitwise assignment
150  void operator=(const parcelCloud&) = delete;
151 };
152 
153 
154 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
155 
156 } // End namespace Foam
157 
158 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
159 
160 #endif
161 
162 // ************************************************************************* //
Virtual abstract base class for parcel clouds. As parcelCloudBase but with additional virtualisation ...
Definition: parcelCloud.H:54
fluidReactionThermo & thermo
Definition: createFields.H:28
static autoPtr< parcelCloud > New(const word &name, const volScalarField &rho, const volVectorField &U, const volScalarField &mu, const dimensionedVector &g)
Selectors.
virtual ~parcelCloud()
Destructor.
Definition: parcelCloud.C:46
virtual void storeGlobalPositions()=0
Call this before a topology change. Stores the particles global.
declareRunTimeSelectionTable(autoPtr, parcelCloud, viscosity,(const word &name, const volScalarField &rho, const volVectorField &U, const volScalarField &mu, const dimensionedVector &g),(name, rho, U, mu, g))
A class for handling words, derived from string.
Definition: word.H:59
Base-class for fluid thermodynamic properties.
Definition: fluidThermo.H:53
const dimensionedScalar mu
Atomic mass unit.
parcelCloud()
Null constructor.
Definition: parcelCloud.C:40
word name(const complex &)
Return a string representation of a complex.
Definition: complex.C:47
virtual void evolve()=0
Evolve the cloud.
U
Definition: pEqn.H:72
Virtual abstract base class for parcel clouds. Inserted by ParcelCloudBase into the base of the cloud...
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
void operator=(const parcelCloud &)=delete
Disallow default bitwise assignment.
const dimensionedVector & g
TypeName("parcelCloud")
Runtime type information.
Namespace for OpenFOAM.