BreakupModel.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) 2011-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 
26 #include "BreakupModel.H"
27 
28 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
29 
30 template<class CloudType>
32 (
33  CloudType& owner
34 )
35 :
37  solveOscillationEq_(false),
38  y0_(0.0),
39  yDot0_(0.0),
40  TABComega_(0.0),
41  TABCmu_(0.0),
42  TABtwoWeCrit_(0.0)
43 {}
44 
45 
46 template<class CloudType>
48 (
49  const BreakupModel<CloudType>& bum
50 )
51 :
53  solveOscillationEq_(bum.solveOscillationEq_),
54  y0_(bum.y0_),
55  yDot0_(bum.yDot0_),
56  TABComega_(bum.TABComega_),
57  TABCmu_(bum.TABCmu_),
58  TABtwoWeCrit_(bum.TABtwoWeCrit_)
59 {}
60 
61 
62 template<class CloudType>
64 (
65  const dictionary& dict,
66  CloudType& owner,
67  const word& type,
68  bool solveOscillationEq
69 )
70 :
71  CloudSubModelBase<CloudType>(owner, dict, typeName, type),
72  solveOscillationEq_(solveOscillationEq),
73  y0_(this->coeffDict().template lookupOrDefault<scalar>("y0", 0.0)),
74  yDot0_(this->coeffDict().template lookupOrDefault<scalar>("yDot0", 0.0)),
75  TABComega_(8),
76  TABCmu_(5),
77  TABtwoWeCrit_(12)
78 {
79  if (solveOscillationEq_ && dict.found("TABCoeffs"))
80  {
81  const dictionary coeffs(dict.subDict("TABCoeffs"));
82  coeffs.lookup("Comega") >> TABComega_;
83  coeffs.lookup("Cmu") >> TABCmu_;
84  scalar WeCrit(coeffs.template lookup<scalar>("WeCrit"));
85  TABtwoWeCrit_ = 2*WeCrit;
86  }
87 }
88 
89 
90 // * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
91 
92 template<class CloudType>
94 {}
95 
96 
97 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
98 
99 #include "BreakupModelNew.C"
100 
101 // ************************************************************************* //
dictionary dict
BreakupModel(CloudType &owner)
Construct null from owner.
Definition: BreakupModel.C:32
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:156
Base class for cloud sub-models.
A class for handling words, derived from string.
Definition: word.H:59
Switch solveOscillationEq_
Definition: BreakupModel.H:61
virtual ~BreakupModel()
Destructor.
Definition: BreakupModel.C:93
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
Definition: POSIX.C:488
Templated break-up model class.
Definition: SprayCloud.H:55
Templated base class for dsmc cloud.
Definition: DSMCCloud.H:75
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
Definition: dictionary.C:864