ConstantRateDevolatilisation.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | Copyright (C) 2011-2013 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::ConstantRateDevolatilisation
26 
27 Description
28  Constant rate devolatisation model
29  - need to set vapourisation temperature to 600 K
30 
31 \*---------------------------------------------------------------------------*/
32 
33 #ifndef ConstantRateDevolatilisation_H
34 #define ConstantRateDevolatilisation_H
35 
36 #include "DevolatilisationModel.H"
37 
38 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
39 
40 namespace Foam
41 {
42 /*---------------------------------------------------------------------------*\
43  Class ConstantRateDevolatilisation Declaration
44 \*---------------------------------------------------------------------------*/
45 
46 template<class CloudType>
48 :
49  public DevolatilisationModel<CloudType>
50 {
51  // Private data
52 
53  // Model constants
54 
55  //- List of volatile data - (name A0)
57 
58  //- List of initial volatile mass fractions
60 
61  //- Mapping between local and cloud gaseous species
63 
64  //- Volatile residual coefficient (0-1)
65  // When the fraction of volatiles are depleted below this
66  // threshold, combustion can occur
67  const scalar residualCoeff_;
68 
69 
70 public:
71 
72  //- Runtime type information
73  TypeName("constantRateDevolatilisation");
74 
75 
76  // Constructors
77 
78  //- Construct from dictionary
80 
81  //- Construct copy
83  (
85  );
86 
87  //- Construct and return a clone
89  {
91  (
93  );
94  }
95 
96 
97  //- Destructor
99 
100 
101  // Member Functions
102 
103  //- Update model
104  virtual void calculate
105  (
106  const scalar dt,
107  const scalar age,
108  const scalar mass0,
109  const scalar mass,
110  const scalar T,
111  const scalarField& YGasEff,
112  const scalarField& YLiquidEff,
113  const scalarField& YSolidEff,
114  label& canCombust,
115  scalarField& dMassDV
116  ) const;
117 };
118 
119 
120 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
121 
122 } // End namespace Foam
123 
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
125 
126 #ifdef NoRepository
128 #endif
129 
130 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
131 
132 #endif
133 
134 // ************************************************************************* //
DevolatilisationModel.H
Foam::ConstantRateDevolatilisation::calculate
virtual void calculate(const scalar dt, const scalar age, const scalar mass0, const scalar mass, const scalar T, const scalarField &YGasEff, const scalarField &YLiquidEff, const scalarField &YSolidEff, label &canCombust, scalarField &dMassDV) const
Update model.
Definition: ConstantRateDevolatilisation.C:96
Foam::ConstantRateDevolatilisation::clone
virtual autoPtr< DevolatilisationModel< CloudType > > clone() const
Construct and return a clone.
Definition: ConstantRateDevolatilisation.H:87
Foam::ConstantRateDevolatilisation::volatileToGasMap_
List< label > volatileToGasMap_
Mapping between local and cloud gaseous species.
Definition: ConstantRateDevolatilisation.H:61
Foam::label
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
Foam::Field
Pre-declare SubField and related Field type.
Definition: Field.H:57
Foam::T
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
Definition: FieldFieldFunctions.C:55
Foam::DevolatilisationModel
Templated devolatilisation model class.
Definition: ReactingMultiphaseCloud.H:53
Foam::DSMCCloud
Templated base class for dsmc cloud.
Definition: DSMCCloud.H:68
dict
dictionary dict
Definition: searchingEngine.H:14
Foam::dictionary
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:137
Foam
Namespace for OpenFOAM.
Definition: combustionModel.C:30
Foam::autoPtr
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:117
Foam::ConstantRateDevolatilisation::TypeName
TypeName("constantRateDevolatilisation")
Runtime type information.
Foam::List
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Definition: HashTable.H:59
Foam::ConstantRateDevolatilisation::YVolatile0_
List< scalar > YVolatile0_
List of initial volatile mass fractions.
Definition: ConstantRateDevolatilisation.H:58
Foam::ConstantRateDevolatilisation
Constant rate devolatisation model.
Definition: ConstantRateDevolatilisation.H:46
Foam::ConstantRateDevolatilisation::volatileData_
List< Tuple2< word, scalar > > volatileData_
List of volatile data - (name A0)
Definition: ConstantRateDevolatilisation.H:55
ConstantRateDevolatilisation.C
Foam::ConstantRateDevolatilisation::residualCoeff_
const scalar residualCoeff_
Volatile residual coefficient (0-1)
Definition: ConstantRateDevolatilisation.H:66
Foam::ConstantRateDevolatilisation::ConstantRateDevolatilisation
ConstantRateDevolatilisation(const dictionary &dict, CloudType &owner)
Construct from dictionary.
Definition: ConstantRateDevolatilisation.C:32
Foam::ConstantRateDevolatilisation::~ConstantRateDevolatilisation
virtual ~ConstantRateDevolatilisation()
Destructor.
Definition: ConstantRateDevolatilisation.C:88