DistortedSphereDragForce.C
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) 2014-2020 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 \*---------------------------------------------------------------------------*/
25 
27 #include "SphereDragForce.H"
28 
29 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
30 
31 template<class CloudType>
33 (
34  CloudType& owner,
35  const fvMesh& mesh,
36  const dictionary& dict
37 )
38 :
39  ParticleForce<CloudType>(owner, mesh, dict, typeName, false)
40 {}
41 
42 
43 template<class CloudType>
45 (
47 )
48 :
50 {}
51 
52 
53 // * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
54 
55 template<class CloudType>
57 {}
58 
59 
60 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
61 
62 template<class CloudType>
64 (
65  const typename CloudType::parcelType& p,
66  const typename CloudType::parcelType::trackingData& td,
67  const scalar dt,
68  const scalar mass,
69  const scalar Re,
70  const scalar muc
71 ) const
72 {
73  // Limit the drop distortion to y=0 (sphere) and y=1 (disk)
74  const scalar y = min(max(p.y(), 0), 1);
75 
76  const scalar CdRe = SphereDragForce<CloudType>::CdRe(Re);
77 
78  return forceSuSp
79  (
80  Zero,
81  mass*0.75*muc*CdRe*(1 + 2.632*y)/(p.rho()*sqr(p.d()))
82  );
83 }
84 
85 
86 // ************************************************************************* //
dictionary dict
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:156
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
dimensionedSymmTensor sqr(const dimensionedVector &dv)
DistortedSphereDragForce(CloudType &owner, const fvMesh &mesh, const dictionary &dict)
Construct from mesh.
Abstract base class for particle forces.
Definition: ParticleForce.H:53
virtual forceSuSp calcCoupled(const typename CloudType::parcelType &p, const typename CloudType::parcelType::trackingData &td, const scalar dt, const scalar mass, const scalar Re, const scalar muc) const
Calculate the coupled force.
Helper container for force Su and Sp terms.
Definition: forceSuSp.H:61
Drag model for distorted spheres.
scalar y
dynamicFvMesh & mesh
virtual ~DistortedSphereDragForce()
Destructor.
static const zero Zero
Definition: zero.H:97
ParcelType parcelType
Type of parcel the cloud was instantiated for.
Definition: DSMCCloud.H:221
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
Drag model for spheres.
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
Templated base class for dsmc cloud.
Definition: DSMCCloud.H:75