fixed writing out entries in advective bc
[OpenFOAM-1.6-ext.git] / src / lagrangian / intermediate / clouds / Templates / ReactingCloud / ReactingCloudI.H
blob6cd313884bedb94e624459a22a89e7aeabc1f2d3
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright held by original author
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 the
13     Free Software Foundation; either version 2 of the License, or (at your
14     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, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 \*---------------------------------------------------------------------------*/
27 // * * * * * * * * * * * * * * * Member Functions  * * * * * * * * * * * * * //
29 template<class ParcelType>
30 inline const typename ParcelType::constantProperties&
31 Foam::ReactingCloud<ParcelType>::constProps() const
33     return constProps_;
37 template<class ParcelType>
38 inline const Foam::multiComponentMixture<typename ParcelType::thermoType>&
39 Foam::ReactingCloud<ParcelType>::mcCarrierThermo() const
41     return mcCarrierThermo_;
45 template<class ParcelType>
46 inline Foam::multiComponentMixture<typename ParcelType::thermoType>&
47 Foam::ReactingCloud<ParcelType>::mcCarrierThermo()
49     return mcCarrierThermo_;
53 template<class ParcelType>
54 inline const Foam::CompositionModel<Foam::ReactingCloud<ParcelType> >&
55 Foam::ReactingCloud<ParcelType>::composition() const
57     return compositionModel_;
61 template<class ParcelType>
62 inline const Foam::PhaseChangeModel<Foam::ReactingCloud<ParcelType> >&
63 Foam::ReactingCloud<ParcelType>::phaseChange() const
65     return phaseChangeModel_;
69 template<class ParcelType>
70 inline Foam::DimensionedField<Foam::scalar, Foam::volMesh>&
71 Foam::ReactingCloud<ParcelType>::rhoTrans(const label i)
73     return rhoTrans_[i];
77 template<class ParcelType>
78 inline Foam::PtrList<Foam::DimensionedField<Foam::scalar, Foam::volMesh> >&
79 Foam::ReactingCloud<ParcelType>::rhoTrans()
81     return rhoTrans_;
85 template<class ParcelType>
86 inline Foam::tmp<Foam::DimensionedField<Foam::scalar, Foam::volMesh> >
87 Foam::ReactingCloud<ParcelType>::Srho(const label i) const
89     return rhoTrans_[i]/(this->db().time().deltaT()*this->mesh().V());
93 template<class ParcelType>
94 inline Foam::tmp<Foam::DimensionedField<Foam::scalar, Foam::volMesh> >
95 Foam::ReactingCloud<ParcelType>::Srho() const
97     tmp<DimensionedField<scalar, volMesh> > trhoTrans
98     (
99         new DimensionedField<scalar, volMesh>
100         (
101             IOobject
102             (
103                 this->name() + "rhoTrans",
104                 this->db().time().timeName(),
105                 this->db(),
106                 IOobject::NO_READ,
107                 IOobject::NO_WRITE,
108                 false
109             ),
110             this->mesh(),
111             dimensionedScalar("zero", rhoTrans_[0].dimensions(), 0.0)
112         )
113     );
115     scalarField& sourceField = trhoTrans().field();
116     forAll (rhoTrans_, i)
117     {
118         sourceField += rhoTrans_[i];
119     }
121     return trhoTrans/(this->db().time().deltaT()*this->mesh().V());
125 // ************************************************************************* //