BUG: UListIO: byteSize overflowing on really big faceLists
[OpenFOAM-2.0.x.git] / src / lagrangian / intermediate / submodels / Reacting / PhaseChangeModel / LiquidEvaporation / LiquidEvaporation.H
blob6978b60fb3dde619d9157d5062ce220738fae6d6
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 2011 OpenFOAM Foundation
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
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.
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.
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/>.
24 Class
25     Foam::LiquidEvaporation
27 Description
28     Liquid evaporation model
29     - uses ideal gas assumption
31 \*---------------------------------------------------------------------------*/
33 #ifndef LiquidEvaporation_H
34 #define LiquidEvaporation_H
36 #include "PhaseChangeModel.H"
37 #include "liquidMixtureProperties.H"
39 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41 namespace Foam
43 /*---------------------------------------------------------------------------*\
44                      Class LiquidEvaporation Declaration
45 \*---------------------------------------------------------------------------*/
47 template<class CloudType>
48 class LiquidEvaporation
50     public PhaseChangeModel<CloudType>
52 protected:
54     // Protected data
56         //- Global liquid properties data
57         const liquidMixtureProperties& liquids_;
59         //- List of active liquid names
60         List<word> activeLiquids_;
62         //- Mapping between liquid and carrier species
63         List<label> liqToCarrierMap_;
65         //- Mapping between local and global liquid species
66         List<label> liqToLiqMap_;
69     // Protected Member Functions
71         //- Sherwood number as a function of Reynolds and Schmidt numbers
72         scalar Sh(const scalar Re, const scalar Sc) const;
74         //- Calculate the carrier phase component volume fractions at cellI
75         tmp<scalarField> calcXc(const label cellI) const;
78 public:
80     //- Runtime type information
81     TypeName("liquidEvaporation");
84     // Constructors
86         //- Construct from dictionary
87         LiquidEvaporation(const dictionary& dict, CloudType& cloud);
89         //- Construct copy
90         LiquidEvaporation(const LiquidEvaporation<CloudType>& pcm);
92         //- Construct and return a clone
93         virtual autoPtr<PhaseChangeModel<CloudType> > clone() const
94         {
95             return autoPtr<PhaseChangeModel<CloudType> >
96             (
97                 new LiquidEvaporation<CloudType>(*this)
98             );
99         }
102     //- Destructor
103     virtual ~LiquidEvaporation();
106     // Member Functions
108         //- Update model
109         virtual void calculate
110         (
111             const scalar dt,
112             const label cellI,
113             const scalar Re,
114             const scalar d,
115             const scalar nu,
116             const scalar T,
117             const scalar Ts,
118             const scalar pc,
119             scalarField& dMassPC
120         ) const;
122         //- Return the enthalpy per unit mass
123         virtual scalar dh
124         (
125             const label idc,
126             const label idl,
127             const label p,
128             const label T
129         ) const;
133 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135 } // End namespace Foam
137 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
139 #ifdef NoRepository
140 #   include "LiquidEvaporation.C"
141 #endif
143 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
145 #endif
147 // ************************************************************************* //