diff --git a/src/lagrangian/intermediate/parcels/include/makeParcelHeatTransferModels.H b/src/lagrangian/intermediate/parcels/include/makeParcelHeatTransferModels.H index b55cdebd96..3206b1616d 100644 --- a/src/lagrangian/intermediate/parcels/include/makeParcelHeatTransferModels.H +++ b/src/lagrangian/intermediate/parcels/include/makeParcelHeatTransferModels.H @@ -33,7 +33,6 @@ License #include "NoHeatTransfer.H" #include "RanzMarshall.H" -#include "RanzMarshallBirdCorrection.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -52,12 +51,6 @@ License RanzMarshall, \ ThermoCloud, \ ParcelType \ - ); \ - makeHeatTransferModelType \ - ( \ - RanzMarshallBirdCorrection, \ - ThermoCloud, \ - ParcelType \ ); diff --git a/src/lagrangian/intermediate/parcels/include/makeReactingParcelHeatTransferModels.H b/src/lagrangian/intermediate/parcels/include/makeReactingParcelHeatTransferModels.H index e26f99e25c..25843df08e 100644 --- a/src/lagrangian/intermediate/parcels/include/makeReactingParcelHeatTransferModels.H +++ b/src/lagrangian/intermediate/parcels/include/makeReactingParcelHeatTransferModels.H @@ -34,7 +34,6 @@ License #include "NoHeatTransfer.H" #include "RanzMarshall.H" -#include "RanzMarshallBirdCorrection.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -74,13 +73,6 @@ License ThermoCloud, \ ParcelType, \ ThermoType \ - ); \ - makeHeatTransferModelThermoType \ - ( \ - RanzMarshallBirdCorrection, \ - ThermoCloud, \ - ParcelType, \ - ThermoType \ ); diff --git a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.C b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.C index 3db839ea15..45e58352b7 100644 --- a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.C +++ b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.C @@ -33,7 +33,8 @@ Foam::HeatTransferModel::HeatTransferModel(CloudType& owner) : dict_(dictionary::null), owner_(owner), - coeffDict_(dictionary::null) + coeffDict_(dictionary::null), + BirdCorrection_(false) {} @@ -47,7 +48,8 @@ Foam::HeatTransferModel::HeatTransferModel : dict_(dict), owner_(owner), - coeffDict_(dict.subDict(type + "Coeffs")) + coeffDict_(dict.subDict(type + "Coeffs")), + BirdCorrection_(coeffDict_.lookup("BirdCorrection")) {} @@ -81,6 +83,13 @@ const Foam::dictionary& Foam::HeatTransferModel::coeffDict() const } +template +const Foam::Switch& Foam::HeatTransferModel::BirdCorrection() const +{ + return BirdCorrection_; +} + + template Foam::scalar Foam::HeatTransferModel::htc ( @@ -93,7 +102,18 @@ Foam::scalar Foam::HeatTransferModel::htc { const scalar Nu = this->Nu(Re, Pr); - return Nu*kappa/dp; + scalar htc = Nu*kappa/dp; + + if (BirdCorrection_ && (mag(htc) > ROOTVSMALL) && (mag(NCpW) > ROOTVSMALL)) + { + const scalar phit = min(NCpW/htc, 50); + if (phit > 0.001) + { + htc *= phit/(exp(phit) - 1.0); + } + } + + return htc; } diff --git a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.H b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.H index 44cf7c3928..1f9015800c 100644 --- a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.H +++ b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/HeatTransferModel/HeatTransferModel.H @@ -64,6 +64,9 @@ class HeatTransferModel //- The coefficients dictionary const dictionary coeffDict_; + //- Apply Bird's correction to the htc + const Switch BirdCorrection_; + public: @@ -110,6 +113,8 @@ public: ); + // Member Functions + // Access //- Return the cloud dictionary @@ -121,12 +126,15 @@ public: //- Return the owner cloud object const CloudType& owner() const; - - // Member Functions + //- Return the Bird htc correction flag + const Switch& BirdCorrection() const; //- Flag to indicate whether model activates heat transfer model virtual bool active() const = 0; + + // Evaluation + //- Nusselt number virtual scalar Nu ( @@ -134,9 +142,6 @@ public: const scalar Pr ) const = 0; - //- Prandtl number - virtual scalar Pr() const = 0; - //- Return heat transfer coefficient virtual scalar htc ( diff --git a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.C b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.C index 8e9b6e9379..5555bb942a 100644 --- a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.C +++ b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.C @@ -35,8 +35,7 @@ Foam::RanzMarshall::RanzMarshall CloudType& cloud ) : - HeatTransferModel(dict, cloud, typeName), - Pr_(dimensionedScalar(this->coeffDict().lookup("Pr")).value()) + HeatTransferModel(dict, cloud, typeName) {} @@ -63,14 +62,7 @@ Foam::scalar Foam::RanzMarshall::Nu const scalar Pr ) const { - return 2.0 + 0.6*pow(Re, 0.5)*pow(Pr, 0.333); -} - - -template -Foam::scalar Foam::RanzMarshall::Pr() const -{ - return Pr_; + return 2.0 + 0.6*sqrt(Re)*cbrt(Pr); } diff --git a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.H b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.H index f010160c1f..e30c51cef4 100644 --- a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.H +++ b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshall/RanzMarshall.H @@ -40,7 +40,7 @@ Description namespace Foam { /*---------------------------------------------------------------------------*\ - Class RanzMarshall Declaration + Class RanzMarshall Declaration \*---------------------------------------------------------------------------*/ template @@ -48,11 +48,6 @@ class RanzMarshall : public HeatTransferModel { - // Private data - - // Prandtl number - const scalar Pr_; - public: @@ -76,18 +71,23 @@ public: // Member Functions - //- Flag to indicate whether model activates heat transfer model - virtual bool active() const; + // Access - //- Nusselt number - virtual scalar Nu - ( - const scalar Re, - const scalar Pr - ) const; + //- Flag to indicate whether model activates heat transfer model + virtual bool active() const; - //- Prandtl number - virtual scalar Pr() const; + //- Return the Bird correction flag + const Switch& BirdCorrection() const; + + + // Evaluation + + //- Nusselt number + virtual scalar Nu + ( + const scalar Re, + const scalar Pr + ) const; }; diff --git a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshallBirdCorrection/RanzMarshallBirdCorrection.C b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshallBirdCorrection/RanzMarshallBirdCorrection.C deleted file mode 100644 index 9ea771fcc1..0000000000 --- a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshallBirdCorrection/RanzMarshallBirdCorrection.C +++ /dev/null @@ -1,79 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | - \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd. - \\/ M anipulation | -------------------------------------------------------------------------------- -License - This file is part of OpenFOAM. - - OpenFOAM is free software; you can redistribute it and/or modify it - under the terms of the GNU General Public License as published by the - Free Software Foundation; either version 2 of the License, or (at your - option) any later version. - - OpenFOAM is distributed in the hope that it will be useful, but WITHOUT - ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - for more details. - - You should have received a copy of the GNU General Public License - along with OpenFOAM; if not, write to the Free Software Foundation, - Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - -\*---------------------------------------------------------------------------*/ - -#include "RanzMarshallBirdCorrection.H" - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - -template -Foam::RanzMarshallBirdCorrection::RanzMarshallBirdCorrection -( - const dictionary& dict, - CloudType& cloud -) -: - RanzMarshall(dict, cloud) -{} - - -// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * // - -template -Foam::RanzMarshallBirdCorrection::~RanzMarshallBirdCorrection() -{} - - -// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // - -template -Foam::scalar Foam::RanzMarshallBirdCorrection::htc -( - const scalar dp, - const scalar Re, - const scalar Pr, - const scalar kappa, - const scalar NCpW -) const -{ - scalar htc = RanzMarshall::htc(dp, Re, Pr, kappa, NCpW); - - // Bird correction - if (mag(htc) > ROOTVSMALL && mag(NCpW) > ROOTVSMALL) - { - const scalar phit = min(NCpW/htc, 50); - scalar fBird = 1.0; - if (phit > 0.001) - { - fBird = phit/(exp(phit) - 1.0); - } - htc *= fBird; - } - - return htc; -} - - -// ************************************************************************* // diff --git a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshallBirdCorrection/RanzMarshallBirdCorrection.H b/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshallBirdCorrection/RanzMarshallBirdCorrection.H deleted file mode 100644 index e8efca9f58..0000000000 --- a/src/lagrangian/intermediate/submodels/Thermodynamic/HeatTransferModel/RanzMarshallBirdCorrection/RanzMarshallBirdCorrection.H +++ /dev/null @@ -1,101 +0,0 @@ -/*---------------------------------------------------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | - \\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd. - \\/ M anipulation | -------------------------------------------------------------------------------- -License - This file is part of OpenFOAM. - - OpenFOAM is free software; you can redistribute it and/or modify it - under the terms of the GNU General Public License as published by the - Free Software Foundation; either version 2 of the License, or (at your - option) any later version. - - OpenFOAM is distributed in the hope that it will be useful, but WITHOUT - ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - for more details. - - You should have received a copy of the GNU General Public License - along with OpenFOAM; if not, write to the Free Software Foundation, - Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - -Class - Foam::RanzMarshallBirdCorrection - -Description - The Ranz-Marshall correlation for heat transfer with the Bird correction - to account for the local shielding effect due to emitted species. - -\*---------------------------------------------------------------------------*/ - -#ifndef RanzMarshallBirdCorrection_H -#define RanzMarshallBirdCorrection_H - -#include "RanzMarshall.H" - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -namespace Foam -{ -/*---------------------------------------------------------------------------*\ - Class RanzMarshallBirdCorrection Declaration -\*---------------------------------------------------------------------------*/ - -template -class RanzMarshallBirdCorrection -: - public RanzMarshall -{ - -public: - - //- Runtime type information - TypeName("RanzMarshallBirdCorrection"); - - - // Constructors - - //- Construct from dictionary - RanzMarshallBirdCorrection - ( - const dictionary& dict, - CloudType& cloud - ); - - - //- Destructor - virtual ~RanzMarshallBirdCorrection(); - - - // Member Functions - - //- Return heat transfer coefficient - virtual scalar htc - ( - const scalar dp, - const scalar Re, - const scalar Pr, - const scalar kappa, - const scalar NCpW - ) const; -}; - - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -} // End namespace Foam - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -#ifdef NoRepository -# include "RanzMarshallBirdCorrection.C" -#endif - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -#endif - -// ************************************************************************* // diff --git a/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/coalCloud1Properties b/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/coalCloud1Properties index 05909b3b58..f270546201 100644 --- a/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/coalCloud1Properties +++ b/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/coalCloud1Properties @@ -23,7 +23,7 @@ DispersionModel StochasticDispersionRAS; PatchInteractionModel StandardWallInteraction; -HeatTransferModel RanzMarshallBirdCorrection; +HeatTransferModel RanzMarshall; CompositionModel SingleMixtureFraction; @@ -54,7 +54,7 @@ constantProperties cp0 cp0 [ 0 2 -2 -1 0 ] 4187; epsilon0 epsilon0 [ 0 0 0 0 0 ] 1; f0 f0 [ 0 0 0 0 0 ] 0.5; - Pr Pr [ 0 0 0 0 0 ] 1.0; + Pr Pr [ 0 0 0 0 0 ] 0.7; Tvap Tvap [ 0 0 0 1 0 ] 400; Tbp Tvap [ 0 0 0 1 0 ] 400; LDevol LDevol [ 0 0 0 0 0 ] 0; @@ -113,7 +113,7 @@ StandardWallInteractionCoeffs RanzMarshallCoeffs { - Pr Pr [ 0 0 0 0 0 ] 0.7; + BirdCorrection true; } SingleMixtureFractionCoeffs diff --git a/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/limestoneCloud1Properties b/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/limestoneCloud1Properties index 41d8fe294d..a17be1e36f 100644 --- a/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/limestoneCloud1Properties +++ b/tutorials/lagrangian/coalChemistryFoam/simplifiedSiwek/constant/limestoneCloud1Properties @@ -45,7 +45,7 @@ constantProperties cp0 cp0 [ 0 2 -2 -1 0 ] 900; epsilon0 epsilon0 [ 0 0 0 0 0 ] 1; f0 f0 [ 0 0 0 0 0 ] 0.5; - Pr Pr [ 0 0 0 0 0 ] 1.0; + Pr Pr [ 0 0 0 0 0 ] 0.7; } interpolationSchemes @@ -98,7 +98,7 @@ StandardWallInteractionCoeffs RanzMarshallCoeffs { - Pr Pr [ 0 0 0 0 0 ] 0.7; + BirdCorrection false; } diff --git a/tutorials/lagrangian/porousExplicitSourceReactingParcelFoam/filter/constant/reactingCloud1Properties b/tutorials/lagrangian/porousExplicitSourceReactingParcelFoam/filter/constant/reactingCloud1Properties index 434f87c8c1..5c99dbf554 100644 --- a/tutorials/lagrangian/porousExplicitSourceReactingParcelFoam/filter/constant/reactingCloud1Properties +++ b/tutorials/lagrangian/porousExplicitSourceReactingParcelFoam/filter/constant/reactingCloud1Properties @@ -50,6 +50,7 @@ constantProperties cp0 cp0 [ 0 2 -2 -1 0 ] 4100; epsilon0 epsilon0 [ 0 0 0 0 0 ] 1; f0 f0 [ 0 0 0 0 0 ] 0.5; + Pr Pr [ 0 0 0 0 0 ] 0.7; Tvap Tvap [ 0 0 0 1 0 ] 273; Tbp Tvap [ 0 0 0 1 0 ] 373; constantVolume false; @@ -132,7 +133,7 @@ LocalInteractionCoeffs RanzMarshallCoeffs { - Pr Pr [ 0 0 0 0 0 ] 0.7; + BirdCorrection true; } SinglePhaseMixtureCoeffs diff --git a/tutorials/lagrangian/reactingParcelFoam/evaporationTest/constant/reactingCloud1Properties b/tutorials/lagrangian/reactingParcelFoam/evaporationTest/constant/reactingCloud1Properties index 9e5ec5ff8d..95f4df9ceb 100644 --- a/tutorials/lagrangian/reactingParcelFoam/evaporationTest/constant/reactingCloud1Properties +++ b/tutorials/lagrangian/reactingParcelFoam/evaporationTest/constant/reactingCloud1Properties @@ -50,6 +50,7 @@ constantProperties cp0 cp0 [ 0 2 -2 -1 0 ] 4187; epsilon0 epsilon0 [ 0 0 0 0 0 ] 1; f0 f0 [ 0 0 0 0 0 ] 0.5; + Pr Pr [ 0 0 0 0 0 ] 0.7; Tvap Tvap [ 0 0 0 1 0 ] 273; Tbp Tvap [ 0 0 0 1 0 ] 373; constantVolume false; @@ -104,7 +105,7 @@ StandardWallInteractionCoeffs RanzMarshallCoeffs { - Pr Pr [ 0 0 0 0 0 ] 0.7; + BirdCorrection true; } SinglePhaseMixtureCoeffs diff --git a/tutorials/lagrangian/rhoPisoTwinParcelFoam/simplifiedSiwek/constant/thermoCloud1Properties b/tutorials/lagrangian/rhoPisoTwinParcelFoam/simplifiedSiwek/constant/thermoCloud1Properties index 4fb16f370e..67823f6aab 100644 --- a/tutorials/lagrangian/rhoPisoTwinParcelFoam/simplifiedSiwek/constant/thermoCloud1Properties +++ b/tutorials/lagrangian/rhoPisoTwinParcelFoam/simplifiedSiwek/constant/thermoCloud1Properties @@ -45,6 +45,7 @@ constantProperties cp0 cp0 [ 0 2 -2 -1 0 ] 900; epsilon0 epsilon0 [ 0 0 0 0 0 ] 1; f0 f0 [ 0 0 0 0 0 ] 0.5; + Pr Pr [ 0 0 0 0 0 ] 0.7; } interpolationSchemes @@ -97,7 +98,7 @@ StandardWallInteractionCoeffs RanzMarshallCoeffs { - Pr Pr [ 0 0 0 0 0 ] 0.7; + BirdCorrection false; }