Cole.C
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2016-2018 OpenFOAM Foundation
9  Copyright (C) 2018 OpenCFD Ltd.
10 -------------------------------------------------------------------------------
11 License
12  This file is part of OpenFOAM.
13 
14  OpenFOAM is free software: you can redistribute it and/or modify it
15  under the terms of the GNU General Public License as published by
16  the Free Software Foundation, either version 3 of the License, or
17  (at your option) any later version.
18 
19  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22  for more details.
23 
24  You should have received a copy of the GNU General Public License
25  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26 
27 \*---------------------------------------------------------------------------*/
28 
29 #include "Cole.H"
33 #include "ThermalDiffusivity.H"
35 
36 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
37 
38 namespace Foam
39 {
40 namespace wallBoilingModels
41 {
42 namespace departureFrequencyModels
43 {
46  (
48  Cole,
50  );
51 }
52 }
53 }
54 
55 
56 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
57 
58 Foam::wallBoilingModels::departureFrequencyModels::
59 Cole::Cole(const dictionary& dict)
60 :
62 {}
63 
64 
65 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
66 
70 (
71  const phaseModel& liquid,
72  const phaseModel& vapor,
73  const label patchi,
74  const scalarField& dDep
75 ) const
76 {
77  // Gravitational acceleration
78  const auto& g =
79  liquid.mesh().time().lookupObject<uniformDimensionedVectorField>("g");
80 
81  const scalarField rhoLiquid(liquid.thermo().rho(patchi));
82  const scalarField rhoVapor(vapor.thermo().rho(patchi));
83 
84  return sqrt
85  (
86  scalar(4)*mag(g).value()
87  *max(rhoLiquid - rhoVapor, scalar(0.1))
88  /(scalar(3)*dDep*rhoLiquid)
89  );
90 }
91 
92 
93 // ************************************************************************* //
Foam::phaseModel
Single incompressible phase derived from the phase-fraction. Used as part of the multiPhaseMixture fo...
Definition: phaseModel.H:54
Foam::wallBoilingModels::departureFrequencyModel
Base class for bubble departure frequency models for boiling flows.
Definition: departureFrequencyModel.H:57
compressibleTurbulenceModel.H
Foam::tmp
A class for managing temporary objects.
Definition: PtrList.H:61
ThermalDiffusivity.H
Cole.H
Foam::liquid
Generic thermophysical properties class for a liquid in which the functions and coefficients for each...
Definition: liquid.H:54
Foam::phaseModel::thermo
virtual const rhoThermo & thermo() const =0
Access const to phase thermo.
PhaseCompressibleTurbulenceModel.H
Foam::wallBoilingModels::departureFrequencyModels::Cole::fDeparture
virtual tmp< scalarField > fDeparture(const phaseModel &liquid, const phaseModel &vapor, const label patchi, const scalarField &dDep) const
Calculate and return the bubble departure frequency.
Definition: Cole.C:70
Foam::UniformDimensionedField< vector >
Foam::rhoThermo::rho
virtual tmp< volScalarField > rho() const
Density [kg/m^3].
Definition: rhoThermo.C:224
Foam::Field< scalar >
Foam::max
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
Definition: hashSets.C:47
dict
dictionary dict
Definition: searchingEngine.H:14
Foam::dictionary
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:123
addToRunTimeSelectionTable.H
Macros for easy insertion into run-time selection tables.
g
const uniformDimensionedVectorField & g
Definition: createFluidFields.H:26
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::wallBoilingModels::departureFrequencyModels::Cole
A correlation for bubble departure frequency modelling based on Cole (1960) for boiling flows.
Definition: Cole.H:93
Foam::wallBoilingModels::departureFrequencyModels::defineTypeNameAndDebug
defineTypeNameAndDebug(Cole, 0)
Foam::liquid::rho
scalar rho(scalar p, scalar T) const
Liquid density [kg/m^3].
Definition: liquidI.H:28
uniformDimensionedFields.H
Foam::sqrt
dimensionedScalar sqrt(const dimensionedScalar &ds)
Definition: dimensionedScalar.C:144
Foam::mag
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
Foam::wallBoilingModels::departureFrequencyModels::addToRunTimeSelectionTable
addToRunTimeSelectionTable(departureFrequencyModel, Cole, dictionary)