Merge branch 'master' of ssh://hunt/home/hunt2/OpenFOAM/OpenFOAM-dev

This commit is contained in:
henry 2008-08-26 11:44:48 +01:00
commit 34ef7ea6da
10 changed files with 22 additions and 40 deletions

View File

@ -191,13 +191,13 @@ void Foam::ReactingParcel<ParcelType>::calcCoupled
+ YMixture_[2]*td.cloud().composition().cpSolid(YSolid_);
// Update particle density or diameter
if (td.cloud().massTransfer().changesVolume())
if (td.constProps().constantVolume())
{
this->d_ = cbrt(mass1/this->rho_*6.0/mathematicalConstant::pi);
this->rho_ = mass1/this->volume();
}
else
{
this->rho_ = mass1/this->volume();
this->d_ = cbrt(mass1/this->rho_*6.0/mathematicalConstant::pi);
}
}
}
@ -296,13 +296,13 @@ void Foam::ReactingParcel<ParcelType>::calcUncoupled
this->cp_ = cp1;
// Update particle density or diameter
if (td.cloud().massTransfer().changesVolume())
if (td.constProps().constantVolume())
{
this->d_ = cbrt(mass1/this->rho_*6.0/mathematicalConstant::pi);
this->rho_ = mass1/this->volume();
}
else
{
this->rho_ = mass1/this->volume();
this->d_ = cbrt(mass1/this->rho_*6.0/mathematicalConstant::pi);
}
}
}

View File

@ -92,6 +92,9 @@ public:
//- Latent heat of devolatilisation [J/kg]
const scalar Ldevol_;
//- Constant volume flag - e.g. during mass transfer
Switch constantVolume_;
public:
@ -108,6 +111,9 @@ public:
//- Return const access to the latent heat of devolatilisation
inline scalar Ldevol() const;
//- Return const access to the constant volume flag
inline Switch constantVolume() const;
};

View File

@ -35,7 +35,8 @@ inline Foam::ReactingParcel<ParcelType>::constantProperties::constantProperties
ThermoParcel<ParcelType>::constantProperties(dict),
Tvap_(dimensionedScalar(dict.lookup("Tvap")).value()),
Tbp_(dimensionedScalar(dict.lookup("Tbp")).value()),
Ldevol_(dimensionedScalar(dict.lookup("Ldevol")).value())
Ldevol_(dimensionedScalar(dict.lookup("Ldevol")).value()),
constantVolume_(dict.lookup("constantVolume"))
{}
@ -136,6 +137,14 @@ Foam::ReactingParcel<ParcelType>::constantProperties::Ldevol() const
}
template<class ParcelType>
inline Foam::Switch
Foam::ReactingParcel<ParcelType>::constantProperties::constantVolume() const
{
return constantVolume_;
}
// * * * * * * * * * * * trackData Member Functions * * * * * * * * * * * * //
template<class ParcelType>

View File

@ -60,13 +60,6 @@ bool Foam::ConstantRateDevolatilisation<CloudType>::active() const
}
template<class CloudType>
bool Foam::ConstantRateDevolatilisation<CloudType>::changesVolume() const
{
return false;
}
template<class CloudType>
Foam::scalar Foam::ConstantRateDevolatilisation<CloudType>::calculate
(

View File

@ -89,9 +89,6 @@ public:
//- Flag to indicate whether model activates mass transfer model
bool active() const;
//- Flag to indicate whether model changes particle volume
bool changesVolume() const;
//- Update model
scalar calculate
(

View File

@ -130,9 +130,6 @@ public:
//- Flag to indicate whether model activates mass transfer model
virtual bool active() const = 0;
//- Flag to indicate whether model changes particle volume
virtual bool changesVolume() const = 0;
//- Update model
virtual scalar calculate
(

View File

@ -55,13 +55,6 @@ bool Foam::NoMassTransfer<CloudType>::active() const
}
template<class CloudType>
bool Foam::NoMassTransfer<CloudType>::changesVolume() const
{
return false;
}
template<class CloudType>
Foam::scalar Foam::NoMassTransfer<CloudType>::calculate
(

View File

@ -75,9 +75,6 @@ public:
//- Flag to indicate whether model activates mass transfer model
bool active() const;
//- Flag to indicate whether model changes particle volume
bool changesVolume() const;
//- Update model
scalar calculate
(

View File

@ -62,13 +62,6 @@ bool Foam::SingleKineticRateDevolatilisation<CloudType>::active() const
}
template<class CloudType>
bool Foam::SingleKineticRateDevolatilisation<CloudType>::changesVolume() const
{
return false;
}
template<class CloudType>
Foam::scalar Foam::SingleKineticRateDevolatilisation<CloudType>::calculate
(

View File

@ -91,9 +91,6 @@ public:
//- Flag to indicate whether model activates mass transfer model
bool active() const;
//- Flag to indicate whether model changes particle volume
bool changesVolume() const;
//- Update model
scalar calculate
(