Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
9f11d892
Commit
9f11d892
authored
Oct 28, 2019
by
sergio ferraris
Committed by
Andrew Heather
Oct 28, 2019
Browse files
ENH: Update of alphaBoiling BC, Bromley and tutorial
parent
9449d92f
Changes
10
Expand all
Hide whitespace changes
Inline
Side-by-side
applications/solvers/heatTransfer/chtMultiRegionFoam/chtMultiRegionTwoPhaseEulerFoam/derivedFvPatchFields/turbulentTemperatureTwoPhaseRadCoupledMixed/turbulentTemperatureTwoPhaseRadCoupledMixedFvPatchScalarField.C
View file @
9f11d892
...
...
@@ -378,8 +378,11 @@ updateCoeffs()
// TvNbr: vapour Tp
scalarField
c
(
TcNbr
*
KDeltaLiqNbr
+
TvNbr
*
KDeltaVapNbr
);
valueFraction
()
=
KDeltaNbr
/
(
KDeltaNbr
+
KDelta
);
refValue
()
=
c
/
KDeltaNbr
;
//valueFraction() = KDeltaNbr/(KDeltaNbr + KDelta);
//refValue() = c/KDeltaNbr;
scalarField
KDeltaLiqVapNbr
(
KDeltaLiqNbr
+
KDeltaVapNbr
);
valueFraction
()
=
KDeltaLiqVapNbr
/
(
KDeltaLiqVapNbr
+
KDelta
);
refValue
()
=
c
/
KDeltaLiqVapNbr
;
refGrad
()
=
(
qr
+
qrNbr
)
/
kappa
(
Tp
);
if
(
debug
)
...
...
@@ -393,7 +396,7 @@ updateCoeffs()
<<
" walltemperature "
<<
" min:"
<<
gMin
(
Tp
)
<<
" max:"
<<
gMax
(
Tp
)
<<
" avg:"
<<
gAverage
(
Tp
)
<<
" avg:"
<<
gAverage
(
Tp
)
<<
nl
<<
endl
;
}
}
...
...
applications/solvers/heatTransfer/chtMultiRegionFoam/chtMultiRegionTwoPhaseEulerFoam/fluid/createFluidFields.H
View file @
9f11d892
...
...
@@ -21,7 +21,178 @@ const uniformDimensionedVectorField& g = meshObjects::gravity::New(runTime);
PtrList
<
pimpleControl
>
pimpleFluid
(
fluidRegions
.
size
());
// Populate fluid field pointer lists
//Debug Fields
/*
PtrList<volScalarField> faceRegimesFluid(fluidRegions.size());
PtrList<volScalarField> qcFluid(fluidRegions.size());
PtrList<volScalarField> qFilmFluid(fluidRegions.size());
PtrList<volScalarField> htcFilmBoilingFluid(fluidRegions.size());
PtrList<volScalarField> qtbFluid(fluidRegions.size());
PtrList<volScalarField> qSubCoolFluid(fluidRegions.size());
PtrList<volScalarField> CHFtotalFluid(fluidRegions.size());
PtrList<volScalarField> TdnbFluid(fluidRegions.size());
PtrList<volScalarField> phiFluid(fluidRegions.size());
forAll(fluidRegions, i)
{
faceRegimesFluid.set
(
i,
new volScalarField
(
IOobject
(
"faceRegimes",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
qcFluid.set
(
i,
new volScalarField
(
IOobject
(
"qc",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
qFilmFluid.set
(
i,
new volScalarField
(
IOobject
(
"qFilm",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
htcFilmBoilingFluid.set
(
i,
new volScalarField
(
IOobject
(
"htcFilmBoiling",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
qtbFluid.set
(
i,
new volScalarField
(
IOobject
(
"qtb",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
qSubCoolFluid.set
(
i,
new volScalarField
(
IOobject
(
"qSubCool",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
CHFtotalFluid.set
(
i,
new volScalarField
(
IOobject
(
"CHFtotal",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
TdnbFluid.set
(
i,
new volScalarField
(
IOobject
(
"Tdnb",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
phiFluid.set
(
i,
new volScalarField
(
IOobject
(
"phiTb",
runTime.timeName(),
fluidRegions[i],
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
fluidRegions[i],
dimensionedScalar(dimless, Zero)
)
);
}
*/
forAll
(
fluidRegions
,
i
)
{
Info
<<
"*** Reading fluid mesh thermophysical properties for region "
...
...
applications/solvers/heatTransfer/chtMultiRegionFoam/chtMultiRegionTwoPhaseEulerFoam/fluid/setRegionFluidFields.H
View file @
9f11d892
...
...
@@ -56,3 +56,16 @@
pimpleControl
&
pimple
=
pimpleFluid
[
i
];
const
dimensionedScalar
&
pMin
=
pMinFluid
[
i
];
// Debug fields
/*
volScalarField& faceRegimes = faceRegimesFluid[i];
volScalarField& qc = qcFluid[i];
volScalarField& qFilm = qFilmFluid[i];
volScalarField& htcFilmBoiling = htcFilmBoilingFluid[i];
volScalarField& qtb = qtbFluid[i];
volScalarField& qSubCool = qSubCoolFluid[i];
volScalarField& CHFtotal = CHFtotalFluid[i];
volScalarField& Tdnb = TdnbFluid[i];
volScalarField& phiTb = phiFluid[i];
*/
src/phaseSystemModels/reactingEulerFoam/derivedFvPatchFields/alphatWallBoilingWallFunction/alphatWallBoilingWallFunctionFvPatchScalarField.C
View file @
9f11d892
This diff is collapsed.
Click to expand it.
src/phaseSystemModels/reactingEulerFoam/derivedFvPatchFields/alphatWallBoilingWallFunction/alphatWallBoilingWallFunctionFvPatchScalarField.H
View file @
9f11d892
...
...
@@ -224,6 +224,8 @@ SourceFiles
#ifndef compressible_alphatWallBoilingWallFunctionFvPatchScalarField_H
#define compressible_alphatWallBoilingWallFunctionFvPatchScalarField_H
#include
"Function1.H"
#include
"alphatPhaseChangeJayatillekeWallFunctionFvPatchScalarField.H"
#include
"partitioningModel.H"
#include
"nucleationSiteModel.H"
...
...
@@ -287,7 +289,7 @@ private:
phaseType
phaseType_
;
//- dmdt relaxationFactor
scalar
relax_
;
autoPtr
<
Function1
<
scalar
>>
relax_
;
//- Patch face area by cell volume
scalarField
AbyV_
;
...
...
src/phaseSystemModels/reactingEulerFoam/derivedFvPatchFields/wallBoilingSubModels/TDNBModels/Schroeder/Schroeder.C
View file @
9f11d892
...
...
@@ -58,7 +58,7 @@ Foam::wallBoilingModels::TDNBModels::Schroeder::Schroeder
)
:
TDNBModel
(),
kg_
(
dict
.
lookupOrDefault
<
scalar
>
(
"kg"
,
5
/
3
))
kg_
(
dict
.
lookupOrDefault
<
scalar
>
(
"kg"
,
1
.
666
))
{}
...
...
src/phaseSystemModels/reactingEulerFoam/derivedFvPatchFields/wallBoilingSubModels/filmBoilingModels/Bromley/Bromley.C
View file @
9f11d892
...
...
@@ -26,6 +26,9 @@ License
#include
"Bromley.H"
#include
"addToRunTimeSelectionTable.H"
#include
"uniformDimensionedFields.H"
#include
"constants.H"
using
namespace
Foam
::
constant
;
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
...
...
@@ -55,7 +58,9 @@ Foam::wallBoilingModels::filmBoilingModels::Bromley::Bromley
)
:
filmBoilingModel
(),
Cn_
(
dict
.
lookupOrDefault
<
scalar
>
(
"Cn"
,
0
.
62
))
Cn_
(
dict
.
lookupOrDefault
<
scalar
>
(
"Cn"
,
0
.
62
)),
emissivity_
(
dict
.
lookupOrDefault
<
scalar
>
(
"emissivity"
,
1
)),
L_
(
dict
.
get
<
scalar
>
(
"L"
))
{}
...
...
@@ -84,7 +89,11 @@ Foam::wallBoilingModels::filmBoilingModels::Bromley::htcFilmBoil
const
uniformDimensionedVectorField
&
g
=
liquid
.
mesh
().
time
().
lookupObject
<
uniformDimensionedVectorField
>
(
"g"
);
const
scalarField
rhoVapor
(
vapor
.
thermo
().
rho
(
patchi
));
const
fvPatchScalarField
&
rhoVaporw
(
vapor
.
thermo
().
rho
()().
boundaryField
()[
patchi
]
);
const
scalarField
rhoLiq
(
liquid
.
thermo
().
rho
(
patchi
));
const
scalarField
kappaVapor
(
vapor
.
kappa
(
patchi
));
...
...
@@ -93,17 +102,23 @@ Foam::wallBoilingModels::filmBoilingModels::Bromley::htcFilmBoil
const
scalarField
&
CpVapor
=
Cp
.
boundaryField
()[
patchi
];
const
scalarField
muVapor
(
vapor
.
mu
(
patchi
));
const
scalarField
dbVapor
(
vapor
.
d
()().
boundaryField
()[
patchi
]);
//const scalarField dbVapor(vapor.d()().boundaryField()[patchi]);
const
scalarField
htcRad
(
emissivity_
*
physicoChemical
::
sigma
.
value
()
*
(
pow4
(
Tw
)
-
pow4
(
Tsatw
))
/
max
((
Tw
-
Tsatw
),
scalar
(
1e-4
))
);
return
Cn_
*
pow
(
pow3
(
kappaVapor
)
*
rhoVapor
*
(
rhoLiq
-
rhoVapor
)
*
mag
(
g
.
value
())
*
rhoVapor
w
*
(
rhoLiq
-
rhoVapor
w
)
*
mag
(
g
.
value
())
*
(
L
+
0
.
4
*
CpVapor
*
max
((
Tw
-
Tsatw
),
scalar
(
0
)))
/
(
dbVapor
*
muVapor
*
max
((
Tw
-
Tsatw
),
scalar
(
1e-4
))),
/
(
L_
*
muVapor
*
max
((
Tw
-
Tsatw
),
scalar
(
1e-4
))),
0
.
25
);
)
+
0
.
75
*
htcRad
;
}
...
...
@@ -114,6 +129,7 @@ void Foam::wallBoilingModels::filmBoilingModels::Bromley::write
{
filmBoilingModel
::
write
(
os
);
os
.
writeKeyword
(
"Cn"
)
<<
Cn_
<<
token
::
END_STATEMENT
<<
nl
;
os
.
writeKeyword
(
"emissivity"
)
<<
emissivity_
<<
token
::
END_STATEMENT
<<
nl
;
}
...
...
src/phaseSystemModels/reactingEulerFoam/derivedFvPatchFields/wallBoilingSubModels/filmBoilingModels/Bromley/Bromley.H
View file @
9f11d892
...
...
@@ -66,6 +66,12 @@ class Bromley
//- Coefficient for nucleation site density
scalar
Cn_
;
//- Wall emissivity
scalar
emissivity_
;
//- Characteristic lenght-scale
scalar
L_
;
public:
//- Runtime type information
...
...
tutorials/heatTransfer/chtMultiRegionTwoPhaseEulerFoam/solidQuenching2D/0.orig/water/alphat.gas
View file @
9f11d892
...
...
@@ -43,23 +43,13 @@ boundaryField
Cmu 0.09;
kappa 0.41;
E 9.8;
relax constant 1;
partitioningModel
{
type Lavieville;
alphaCrit 0.2;
}
LeidenfrostModel
{
type Spiegler;
Tcrit 647;
}
filmBoilingModel
{
type Bromley;
}
value uniform 0;
value uniform 1e-8;
}
maxY
{
...
...
tutorials/heatTransfer/chtMultiRegionTwoPhaseEulerFoam/solidQuenching2D/0.orig/water/alphat.liquid
View file @
9f11d892
...
...
@@ -43,6 +43,7 @@ boundaryField
Cmu 0.09;
kappa 0.41;
E 9.8;
relax constant 1;
dmdt uniform 0;
partitioningModel
{
...
...
@@ -88,6 +89,7 @@ boundaryField
filmBoilingModel
{
type Bromley;
L 1e-3;
}
value uniform 1e-8;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment