From 8883e2b87e8873d05b5935af033454c531d8af16 Mon Sep 17 00:00:00 2001 From: andy Date: Tue, 19 May 2009 15:03:00 +0100 Subject: [PATCH 01/10] fixed: wrong calculation of H1 --- .../intermediate/parcels/Templates/ThermoParcel/ThermoParcel.C | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lagrangian/intermediate/parcels/Templates/ThermoParcel/ThermoParcel.C b/src/lagrangian/intermediate/parcels/Templates/ThermoParcel/ThermoParcel.C index 6a476110dd..5885512511 100644 --- a/src/lagrangian/intermediate/parcels/Templates/ThermoParcel/ThermoParcel.C +++ b/src/lagrangian/intermediate/parcels/Templates/ThermoParcel/ThermoParcel.C @@ -110,7 +110,7 @@ void Foam::ThermoParcel::calc scalar T1 = calcHeatTransfer(td, dt, cellI, d0, U0, rho0, T0, cp0, Sh); // Calculate new enthalpy state - scalar H1 = cp0 - T1; + scalar H1 = cp0*T1; // Motion From 2ca4831e61fadd7a02022b6f6dae0e95d6cd2b48 Mon Sep 17 00:00:00 2001 From: andy Date: Tue, 19 May 2009 15:06:43 +0100 Subject: [PATCH 02/10] multiple updates --- .../ReactingMultiphaseParcel.C | 17 +++++---- .../ReactingMultiphaseParcelI.H | 3 +- .../ReactingMultiphaseParcelIO.C | 12 ++---- .../Templates/ReactingParcel/ReactingParcel.C | 5 ++- .../phaseProperties/phaseProperties.C | 36 +++++++++--------- .../phaseProperties/phaseProperties.H | 14 +++---- .../phaseProperties/phasePropertiesIO.C | 6 +-- .../CompositionModel/CompositionModel.C | 37 +++++++++++++++++-- .../CompositionModel/CompositionModel.H | 7 +++- 9 files changed, 85 insertions(+), 52 deletions(-) diff --git a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C index 4d4eae98fb..3ad7743863 100644 --- a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C +++ b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C @@ -341,19 +341,19 @@ void Foam::ReactingMultiphaseParcel::calc // Transfer mass lost from particle to carrier mass source forAll(YGas_, i) { - label id = td.cloud().composition().localToGlobalGasId(GAS, i); + label id = td.cloud().composition().localToGlobalCarrierId(GAS, i); td.cloud().rhoTrans(id)[cellI] += np0*dMassGas[i]; } forAll(YLiquid_, i) { - label id = td.cloud().composition().localToGlobalGasId(LIQ, i); + label id = td.cloud().composition().localToGlobalCarrierId(LIQ, i); td.cloud().rhoTrans(id)[cellI] += np0*dMassLiquid[i]; } /* // No mapping between solid components and carrier phase forAll(YSolid_, i) { - label id = td.cloud().composition().localToGlobalGasId(SLD, i); + label id = td.cloud().composition().localToGlobalCarrierId(SLD, i); td.cloud().rhoTrans(id)[cellI] += np0*dMassSolid[i]; } */ @@ -385,12 +385,14 @@ void Foam::ReactingMultiphaseParcel::calc // Absorb parcel into carrier phase forAll(YGas_, i) { - label id = td.cloud().composition().localToGlobalGasId(GAS, i); + label id = + td.cloud().composition().localToGlobalCarrierId(GAS, i); td.cloud().rhoTrans(id)[cellI] += np0*mass1*YMix[GAS]*YGas_[i]; } forAll(YLiquid_, i) { - label id = td.cloud().composition().localToGlobalGasId(LIQ, i); + label id = + td.cloud().composition().localToGlobalCarrierId(LIQ, i); td.cloud().rhoTrans(id)[cellI] += np0*mass1*YMix[LIQ]*YLiquid_[i]; } @@ -398,13 +400,14 @@ void Foam::ReactingMultiphaseParcel::calc // No mapping between solid components and carrier phase forAll(YSolid_, i) { - label id = td.cloud().composition().localToGlobalGasId(SLD, i); + label id = + td.cloud().composition().localToGlobalCarrierId(SLD, i); td.cloud().rhoTrans(id)[cellI] += np0*mass1*YMix[SLD]*YSolid_[i]; } */ - td.cloud().hsTrans()[cellI] += np0*mass1*H1; td.cloud().UTrans()[cellI] += np0*mass1*U1; + td.cloud().hsTrans()[cellI] += np0*mass1*H1; } } diff --git a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelI.H b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelI.H index 9709da663d..ef40cdc994 100644 --- a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelI.H +++ b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelI.H @@ -104,7 +104,8 @@ inline Foam::ReactingMultiphaseParcel::ReactingMultiphaseParcel ), YGas_(YGas0), YLiquid_(YLiquid0), - YSolid_(YSolid0) + YSolid_(YSolid0), + canCombust_(false) {} diff --git a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelIO.C b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelIO.C index b37f7c715e..bbf58e49a0 100644 --- a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelIO.C +++ b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcelIO.C @@ -40,7 +40,8 @@ Foam::ReactingMultiphaseParcel::ReactingMultiphaseParcel ReactingParcel(cloud, is, readFields), YGas_(0), YLiquid_(0), - YSolid_(0) + YSolid_(0), + canCombust_(false) { if (readFields) { @@ -58,14 +59,7 @@ Foam::ReactingMultiphaseParcel::ReactingMultiphaseParcel YLiquid_.setSize(nLiquid); YSolid_.setSize(nSolid); - if (is.format() == IOstream::ASCII) - { - is >> YGas_ >> YLiquid_ >> YSolid_; - } - else - { - is >> YGas_ >> YLiquid_ >> YSolid_; - } + is >> YGas_ >> YLiquid_ >> YSolid_; // scale the mass fractions const scalarField& YMix = this->Y_; diff --git a/src/lagrangian/intermediate/parcels/Templates/ReactingParcel/ReactingParcel.C b/src/lagrangian/intermediate/parcels/Templates/ReactingParcel/ReactingParcel.C index 3ea161f28f..39658fcf2f 100644 --- a/src/lagrangian/intermediate/parcels/Templates/ReactingParcel/ReactingParcel.C +++ b/src/lagrangian/intermediate/parcels/Templates/ReactingParcel/ReactingParcel.C @@ -187,7 +187,7 @@ void Foam::ReactingParcel::calc // Transfer mass lost from particle to carrier mass source forAll(dMassPC, i) { - label id = td.cloud().composition().localToGlobalGasId(0, i); + label id = td.cloud().composition().localToGlobalCarrierId(0, i); td.cloud().rhoTrans(id)[cellI] += np0*dMassPC[i]; } @@ -210,7 +210,8 @@ void Foam::ReactingParcel::calc // Absorb parcel into carrier phase forAll(Y_, i) { - label id = td.cloud().composition().localToGlobalGasId(0, i); + label id = + td.cloud().composition().localToGlobalCarrierId(0, i); td.cloud().rhoTrans(id)[cellI] += np0*mass1*Y_[i]; } td.cloud().UTrans()[cellI] += np0*mass1*U1; diff --git a/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.C b/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.C index 1da9161508..eb451ba36f 100644 --- a/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.C +++ b/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.C @@ -63,22 +63,22 @@ void Foam::phaseProperties::setGlobalIds } if (globalIds_[i] == -1) { - wordList globalGasNames(YGas.size()); + wordList globalCarrierNames(YGas.size()); forAll (YGas, k) { - globalGasNames[k] = YGas[k].name(); + globalCarrierNames[k] = YGas[k].name(); } FatalErrorIn ( - "void phaseProperties::setGlobalGasIds" + "void phaseProperties::setGlobalIds" "(" "const PtrList&" ")" - ) << "Could not find gas species " << names_[i] + ) << "Could not find carrier species " << names_[i] << " in species list" << nl - << "Available species are: " << nl << globalGasNames << nl + << "Available species are: " << nl << globalCarrierNames << nl << exit(FatalError); } } @@ -111,11 +111,13 @@ void Foam::phaseProperties::setGlobalIds(const wordList& globalNames) } -void Foam::phaseProperties::setGlobalGasIds +void Foam::phaseProperties::setGlobalCarrierIds ( const PtrList& YGas ) { + globalCarrierIds_ = -1; + forAll(names_, i) { forAll (YGas, j) @@ -124,11 +126,11 @@ void Foam::phaseProperties::setGlobalGasIds if (specieName == names_[i]) { - globalGasIds_[i] = j; + globalCarrierIds_[i] = j; break; } } - if (globalGasIds_[i] == -1) + if (globalCarrierIds_[i] == -1) { wordList gasNames(YGas.size()); forAll(YGas, gasI) @@ -138,7 +140,7 @@ void Foam::phaseProperties::setGlobalGasIds FatalErrorIn ( - "void Foam::phaseProperties::setGlobalGasIds" + "void Foam::phaseProperties::setGlobalCarrierIds" "(" "const PtrList&" ")" @@ -215,7 +217,7 @@ Foam::phaseProperties::phaseProperties() names_(0), Y_(0), globalIds_(0), - globalGasIds_(0) + globalCarrierIds_(0) {} @@ -226,7 +228,7 @@ Foam::phaseProperties::phaseProperties(const phaseProperties& pp) names_(pp.names_), Y_(pp.Y_), globalIds_(pp.globalIds_), - globalGasIds_(pp.globalGasIds_) + globalCarrierIds_(pp.globalCarrierIds_) {} @@ -252,16 +254,16 @@ void Foam::phaseProperties::initialiseGlobalIds case GAS: { setGlobalIds(YGas); - forAll(globalGasIds_, i) + forAll(globalCarrierIds_, i) { - globalGasIds_[i] = globalIds_[i]; + globalCarrierIds_[i] = globalIds_[i]; } break; } case LIQUID: { setGlobalIds(liquidNames); - setGlobalGasIds(YGas); + setGlobalCarrierIds(YGas); break; } case SOLID: @@ -272,7 +274,7 @@ void Foam::phaseProperties::initialiseGlobalIds "phaseProperties::initialiseGlobalIds(...)" ) << "Assuming no mapping between solid and carrier species" << endl; -// setGlobalGasIds(YGas); +// setGlobalCarrierIds(YGas); break; } default: @@ -383,9 +385,9 @@ const Foam::labelList& Foam::phaseProperties::globalIds() const } -const Foam::labelList& Foam::phaseProperties::globalGasIds() const +const Foam::labelList& Foam::phaseProperties::globalCarrierIds() const { - return globalGasIds_; + return globalCarrierIds_; } diff --git a/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.H b/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.H index be45bc51ca..c87f51b7a0 100644 --- a/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.H +++ b/src/lagrangian/intermediate/phaseProperties/phaseProperties/phaseProperties.H @@ -88,21 +88,21 @@ private: //- Global ids labelList globalIds_; - //- Map to gas global id - labelList globalGasIds_; + //- Map to carrier global id + labelList globalCarrierIds_; // Private member functions - //- Set global ids - specialisation for carrier gas phases + //- Set global ids - specialisation for carrier phases void setGlobalIds(const PtrList& YGas); //- Set global ids - liquid and solid phases void setGlobalIds(const wordList& globalNames); - //- Set global gas ids - attempts to map component names to global + //- Set global carrier ids - attempts to map component names to global // carrier species - void setGlobalGasIds(const PtrList& YGas); + void setGlobalCarrierIds(const PtrList& YGas); //- Check the total mass fraction void checkTotalMassFraction() const; @@ -166,8 +166,8 @@ public: //- Return const acccess to the global ids const labelList& globalIds() const; - //- Return const acccess to the map to the gas global ids - const labelList& globalGasIds() const; + //- Return const acccess to the map to the carrier global ids + const labelList& globalCarrierIds() const; //- Return the global id of a component in the local list by name // Returns -1 if not found diff --git a/src/lagrangian/intermediate/phaseProperties/phaseProperties/phasePropertiesIO.C b/src/lagrangian/intermediate/phaseProperties/phaseProperties/phasePropertiesIO.C index 18da442052..2fbb79039b 100644 --- a/src/lagrangian/intermediate/phaseProperties/phaseProperties/phasePropertiesIO.C +++ b/src/lagrangian/intermediate/phaseProperties/phaseProperties/phasePropertiesIO.C @@ -36,7 +36,7 @@ Foam::phaseProperties::phaseProperties(Istream& is) names_(0), Y_(0), globalIds_(0), - globalGasIds_(0) + globalCarrierIds_(0) { is.check("Foam::phaseProperties::phaseProperties(Istream& is)"); @@ -51,7 +51,7 @@ Foam::phaseProperties::phaseProperties(Istream& is) names_.setSize(nComponents, "unknownSpecie"); Y_.setSize(nComponents, 0.0); globalIds_.setSize(nComponents, -1); - globalGasIds_.setSize(nComponents, -1); + globalCarrierIds_.setSize(nComponents, -1); label cmptI = 0; forAllConstIter(IDLList, phaseInfo, iter) @@ -87,7 +87,7 @@ Foam::Istream& Foam::operator>>(Istream& is, phaseProperties& pp) pp.names_.setSize(nComponents, "unknownSpecie"); pp.Y_.setSize(nComponents, 0.0); pp.globalIds_.setSize(nComponents, -1); - pp.globalGasIds_.setSize(nComponents, -1); + pp.globalCarrierIds_.setSize(nComponents, -1); label cmptI = 0; forAllConstIter(IDLList, phaseInfo, iter) diff --git a/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.C b/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.C index 1bbdc5221f..4336b72baa 100644 --- a/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.C +++ b/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.C @@ -178,6 +178,34 @@ Foam::CompositionModel::componentNames(const label phaseI) const } +template +Foam::label Foam::CompositionModel::globalCarrierId +( + const word& cmptName +) const +{ + forAll(carrierThermo_.composition().Y(), i) + { + word carrierSpecieName = carrierThermo_.composition().Y()[i].name(); + if (cmptName == carrierSpecieName) + { + return i; + } + } + + FatalErrorIn + ( + "Foam::label Foam::CompositionModel::globalCarrierId" + "(" + "const word&" + ") const" + ) << "Unable to determine global id for requested component " + << cmptName << nl << abort(FatalError); + + return -1; +} + + template Foam::label Foam::CompositionModel::globalId ( @@ -241,24 +269,25 @@ Foam::label Foam::CompositionModel::localId template -Foam::label Foam::CompositionModel::localToGlobalGasId +Foam::label Foam::CompositionModel::localToGlobalCarrierId ( const label phaseI, const label id ) const { - label gid = phaseProps_[phaseI].globalGasIds()[id]; + label gid = phaseProps_[phaseI].globalCarrierIds()[id]; if (gid < 0) { FatalErrorIn ( - "Foam::label Foam::CompositionModel::localToGlobalGasId" + "Foam::label " + "Foam::CompositionModel::localToGlobalCarrierId" "(" "const label, " "const label" ") const" - ) << "Unable to determine global gas id for phase " + ) << "Unable to determine global carrier id for phase " << phaseI << " with local id " << id << nl << abort(FatalError); } diff --git a/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.H b/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.H index e45f7d96d0..8fb8762cf0 100644 --- a/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.H +++ b/src/lagrangian/intermediate/submodels/Reacting/CompositionModel/CompositionModel/CompositionModel.H @@ -179,6 +179,9 @@ public: //- Return the list of component names for phaseI const wordList& componentNames(const label phaseI) const; + //- Return global id of component cmptName in carrier thermo + label globalCarrierId(const word& cmptName) const; + //- Return global id of component cmptName in phase phaseI label globalId(const label phaseI, const word& cmptName) const; @@ -188,8 +191,8 @@ public: //- Return local id of component cmptName in phase phaseI label localId(const label phaseI, const word& cmptName) const; - //- Return global gas id of component given local id - label localToGlobalGasId + //- Return global carrier id of component given local id + label localToGlobalCarrierId ( const label phaseI, const label id From 868e2e4096bcd240855b3bab867192998e9fc308 Mon Sep 17 00:00:00 2001 From: andy Date: Tue, 19 May 2009 10:02:53 +0100 Subject: [PATCH 03/10] adding path to meshTools/lnInclude --- .../Lagrangian/uncoupledKinematicParcelFoam/Make/options | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/applications/solvers/Lagrangian/uncoupledKinematicParcelFoam/Make/options b/applications/solvers/Lagrangian/uncoupledKinematicParcelFoam/Make/options index c9727abd52..818e371778 100644 --- a/applications/solvers/Lagrangian/uncoupledKinematicParcelFoam/Make/options +++ b/applications/solvers/Lagrangian/uncoupledKinematicParcelFoam/Make/options @@ -6,7 +6,8 @@ EXE_INC = \ -I$(LIB_SRC)/thermophysicalModels/combustion/lnInclude \ -I$(LIB_SRC)/thermophysicalModels/radiation/lnInclude \ -I$(LIB_SRC)/turbulenceModels/compressible/turbulenceModel \ - -I$(LIB_SRC)/finiteVolume/lnInclude + -I$(LIB_SRC)/finiteVolume/lnInclude \ + -I$(LIB_SRC)/meshTools/lnInclude \ EXE_LIBS = \ -llagrangian \ From 6f68f6fb20b6a4cc96af0173833f37bceba972c6 Mon Sep 17 00:00:00 2001 From: andy Date: Mon, 18 May 2009 19:36:31 +0100 Subject: [PATCH 04/10] typo - missing ()'s --- .../ReactingMultiphaseParcel/ReactingMultiphaseParcel.C | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C index 3ad7743863..7c2fd37583 100644 --- a/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C +++ b/src/lagrangian/intermediate/parcels/Templates/ReactingMultiphaseParcel/ReactingMultiphaseParcel.C @@ -176,7 +176,7 @@ void Foam::ReactingMultiphaseParcel::cellValueSourceCorrection const scalar fCarrier = -1.0/td.constProps().hRetentionCoeff(); const scalar dh = - td.cloud().hsTrans()[cellI] + fCarrier*td.cloud().hcTrans[cellI]; + td.cloud().hsTrans()[cellI] + fCarrier*td.cloud().hcTrans()[cellI]; this->Tc_ += dh/(this->cpc_*massCellNew); } From f2f7b74f0341fe546753ecd3cdb252be5ebd4493 Mon Sep 17 00:00:00 2001 From: andy Date: Mon, 18 May 2009 19:02:16 +0100 Subject: [PATCH 05/10] added pre-factor for reference field --- .../FieldActivatedInjection.C | 3 ++- .../FieldActivatedInjection.H | 20 ++++++++++++------- 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.C b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.C index b6662e0c92..b02e642ff1 100644 --- a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.C +++ b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.C @@ -75,6 +75,7 @@ Foam::FieldActivatedInjection::FieldActivatedInjection ) : InjectionModel(dict, owner, typeName), + factor_(readScalar(this->coeffDict().lookup("factor"))), referenceField_ ( owner.db().objectRegistry::lookupObject @@ -212,7 +213,7 @@ bool Foam::FieldActivatedInjection::validInjection if ( nParcelsInjected_[parcelI] < nParcelsPerInjector_ - && referenceField_[cellI] > thresholdField_[cellI] + && factor_*referenceField_[cellI] > thresholdField_[cellI] ) { nParcelsInjected_[parcelI]++; diff --git a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.H b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.H index e82074bc6b..e28604b0e4 100644 --- a/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.H +++ b/src/lagrangian/intermediate/submodels/Kinematic/InjectionModel/FieldActivatedInjection/FieldActivatedInjection.H @@ -26,15 +26,18 @@ Class Foam::FieldActivatedInjection Description - Injection at specified positions, with the condition that for injection - to be allowed + Injection at specified positions, with the conditions: - referenceField[cellI] >= thresholdField[cellI] + - for injection to be allowed - where: - - referenceField is the field used to supply the look-up values - - thresholdField supplies the values beyond which the injection is - permitted + factor*referenceField[cellI] >= thresholdField[cellI] + + where: + - referenceField is the field used to supply the look-up values + - thresholdField supplies the values beyond which the injection is + permitted + + - limited to a user-supllied number of injections per injector location SourceFiles FieldActivatedInjection.C @@ -66,6 +69,9 @@ class FieldActivatedInjection // Model parameters + //- Factor to apply to reference field + const scalar factor_; + //- Reference field const volScalarField& referenceField_; From c4ac52e6b08f3caebf661545e7021c8f348b56e7 Mon Sep 17 00:00:00 2001 From: andy Date: Tue, 19 May 2009 17:37:04 +0100 Subject: [PATCH 06/10] fix: taking carrier specie id --- .../LiquidEvaporation/LiquidEvaporation.C | 10 +++++----- .../LiquidEvaporation/LiquidEvaporation.H | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.C b/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.C index a9f6e5738a..d0afb84cb0 100644 --- a/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.C +++ b/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.C @@ -81,7 +81,7 @@ Foam::LiquidEvaporation::LiquidEvaporation ) ), activeLiquids_(this->coeffDict().lookup("activeLiquids")), - liqToGasMap_(activeLiquids_.size(), -1), + liqToCarrierMap_(activeLiquids_.size(), -1), liqToLiqMap_(activeLiquids_.size(), -1) { if (activeLiquids_.size() == 0) @@ -98,14 +98,14 @@ Foam::LiquidEvaporation::LiquidEvaporation } // Determine mapping between liquid and carrier phase species - label idLiquid = owner.composition().idLiquid(); forAll(activeLiquids_, i) { - liqToGasMap_[i] = - owner.composition().globalId(idLiquid, activeLiquids_[i]); + liqToCarrierMap_[i] = + owner.composition().globalCarrierId(activeLiquids_[i]); } // Determine mapping between local and global liquids + label idLiquid = owner.composition().idLiquid(); forAll(activeLiquids_, i) { liqToLiqMap_[i] = @@ -159,7 +159,7 @@ void Foam::LiquidEvaporation::calculate // calculate mass transfer of each specie in liquid forAll(activeLiquids_, i) { - label gid = liqToGasMap_[i]; + label gid = liqToCarrierMap_[i]; label lid = liqToLiqMap_[i]; // vapour diffusivity [m2/s] diff --git a/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.H b/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.H index d2a1f903da..9c650f1c2e 100644 --- a/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.H +++ b/src/lagrangian/intermediate/submodels/Reacting/PhaseChangeModel/LiquidEvaporation/LiquidEvaporation.H @@ -60,8 +60,8 @@ protected: //- List of active liquid names List activeLiquids_; - //- Mapping between liquid and carrier gas species - List