All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
DenseDragForce.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) 2019 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::DenseDragForce
26 
27 \*---------------------------------------------------------------------------*/
28 
29 #ifndef DenseDragForce_H
30 #define DenseDragForce_H
31 
32 #include "ParticleForce.H"
33 #include "interpolation.H"
34 
35 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
36 
37 namespace Foam
38 {
39 
40 /*---------------------------------------------------------------------------*\
41  Class DenseDragForce Declaration
42 \*---------------------------------------------------------------------------*/
43 
44 template<class CloudType>
45 class DenseDragForce
46 :
47  public ParticleForce<CloudType>
48 {
49 protected:
50 
51  // Protected Data
52 
53  //- Name of the carrier volume fraction field
54  const word alphacName_;
55 
56  //- The carrier volume fraction field
58 
59  //- Interpolation for the carrier volume fraction field
61 
62 
63 public:
64 
65  // Constructors
66 
67  //- Construct from mesh
69  (
71  const fvMesh& mesh,
72  const dictionary& dict,
73  const word& typeName
74  );
75 
76  //- Construct copy
78 
79 
80  //- Destructor
81  virtual ~DenseDragForce();
82 
83 
84  // Member Functions
85 
86  // Access
87 
88  //- Return the volume fraction interpolation
89  const interpolation<scalar>& alphacInterp() const;
90 
91  // Evaluation
92 
93  //- Cache fields
94  virtual void cacheFields(const bool store);
95 };
96 
97 
98 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
99 
100 } // End namespace Foam
101 
102 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
103 
104 #ifdef NoRepository
105  #include "DenseDragForce.C"
106 #endif
107 
108 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
109 
110 #endif
111 
112 // ************************************************************************* //
dictionary dict
virtual void cacheFields(const bool store)
Cache fields.
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:158
const fvMesh & mesh() const
Return the mesh database.
Abstract base class for particle forces.
Definition: ParticleForce.H:53
const CloudType & owner() const
Return const access to the cloud owner.
DenseDragForce(CloudType &owner, const fvMesh &mesh, const dictionary &dict, const word &typeName)
Construct from mesh.
const word alphacName_
Name of the carrier volume fraction field.
A class for handling words, derived from string.
Definition: word.H:59
autoPtr< volScalarField > alphacPtr_
The carrier volume fraction field.
const interpolation< scalar > & alphacInterp() const
Return the volume fraction interpolation.
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
autoPtr< interpolation< scalar > > alphacInterpPtr_
Interpolation for the carrier volume fraction field.
virtual ~DenseDragForce()
Destructor.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
Templated base class for dsmc cloud.
Definition: DSMCCloud.H:69
Namespace for OpenFOAM.