spherical.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) 2025 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::clouds::spherical
26 
27 Description
28  Base class for clouds with spherical particles
29 
30 SourceFiles
31  spherical.C
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef spherical_H
36 #define spherical_H
37 
38 #include "shaped.H"
39 
40 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41 
42 namespace Foam
43 {
44 namespace clouds
45 {
46 
47 /*---------------------------------------------------------------------------*\
48  Class spherical Declaration
49 \*---------------------------------------------------------------------------*/
50 
51 class spherical
52 :
53  public shaped
54 {
55 private:
56 
57  // Private Member Functions
58 
59  //- Return the IO object for the diameter field
60  static IOobject dIo(const cloud&);
61 
62  //- Calculate the particles' volumes
63  virtual tmp<LagrangianSubScalarField> calcv
64  (
65  const LagrangianModelRef& model,
66  const LagrangianSubMesh& subMesh
67  ) const;
68 
69  //- Calculate the particles' surface areas
70  virtual tmp<LagrangianSubScalarField> calca
71  (
72  const LagrangianModelRef& model,
73  const LagrangianSubMesh& subMesh
74  ) const;
75 
76  //- Calculate the particles' surface area per unit volumes
77  virtual tmp<LagrangianSubScalarField> calcaByV
78  (
79  const LagrangianModelRef& model,
80  const LagrangianSubMesh& subMesh
81  ) const;
82 
83 
84 protected:
85 
86  // Protected Member Functions
87 
88  //- Correct the shape to match the given volume
90 
91 
92 public:
93 
94  // Public Static Data
95 
96  //- Run-time type information
97  TypeName("spherical");
98 
99 
100  // Public Data
101 
102  //- Diameter
104 
105 
106  // Constructors
107 
108  //- Construct from a reference to the cloud
109  spherical(const cloud&);
110 
111  //- Construct from a reference to the cloud and its base classes
112  spherical(const cloud&, const grouped&);
113 
114 
115  //- Destructor
116  virtual ~spherical();
117 };
118 
119 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 
121 } // End namespace clouds
122 } // End namespace Foam
123 
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
125 
126 #endif
127 
128 // ************************************************************************* //
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
Definition: IOobject.H:99
Simple wrapper to provide an optional reference to a Lagrangian model.
Mesh that relates to a sub-section of a Lagrangian mesh. This is used to construct fields that relate...
Base class for clouds. Provides a basic evolution algorithm, models, and a database for caching deriv...
Definition: cloud.H:61
Base class for clouds in which particles are grouped into parcels.
Definition: grouped.H:51
Base class for clouds with particles with mass.
Definition: shaped.H:51
const CloudDerivedField< scalar > & v
Volume.
Definition: shaped.H:90
Base class for clouds with spherical particles.
Definition: spherical.H:53
CloudStateField< scalar > d
Diameter.
Definition: spherical.H:102
TypeName("spherical")
Run-time type information.
spherical(const cloud &)
Construct from a reference to the cloud.
Definition: spherical.C:102
virtual ~spherical()
Destructor.
Definition: spherical.C:118
void correct(const LagrangianSubScalarSubField &v)
Correct the shape to match the given volume.
Definition: spherical.C:90
A class for managing temporary objects.
Definition: tmp.H:55
Namespace for OpenFOAM.