ENH: twoPhaseEulerFoam: modified noBlending to handle cases where only the segregated model is used

This commit is contained in:
william
2014-02-19 14:19:46 +00:00
committed by Andrew Heather
parent 0aa4d54666
commit 10f31ddaea

View File

@ -88,7 +88,7 @@ Foam::tmp<Foam::volScalarField> Foam::blendingMethods::noBlending::f1
(
"f",
dimless,
phase1.name() == continuousPhase_
phase2.name() != continuousPhase_
)
)
);
@ -101,7 +101,28 @@ Foam::tmp<Foam::volScalarField> Foam::blendingMethods::noBlending::f2
const phaseModel& phase2
) const
{
return f1(phase1, phase2);
const fvMesh& mesh(phase1.mesh());
return
tmp<volScalarField>
(
new volScalarField
(
IOobject
(
"f",
mesh.time().timeName(),
mesh
),
mesh,
dimensionedScalar
(
"f",
dimless,
phase1.name() == continuousPhase_
)
)
);
}