From f45ad46f3723f75cffef9d4bf6714c3164a099a1 Mon Sep 17 00:00:00 2001 From: Will Bainbridge Date: Thu, 3 Feb 2022 14:43:42 +0000 Subject: [PATCH 1/2] sampling: Corrected the order of cell and face points in a line-cell-face sampled set --- src/sampling/sampledSet/sampledSet/sampledSetParticle.C | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/sampling/sampledSet/sampledSet/sampledSetParticle.C b/src/sampling/sampledSet/sampledSet/sampledSetParticle.C index ac5a342f1a..d07c39f071 100644 --- a/src/sampling/sampledSet/sampledSet/sampledSetParticle.C +++ b/src/sampling/sampledSet/sampledSet/sampledSetParticle.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2021 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2021-2022 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -144,8 +144,8 @@ bool Foam::sampledSetParticle::move while (onInternalFace()) { - if (td.storeFaces_) storeFace(cloud, td); if (td.storeCells_) storeCell(cloud, td); + if (td.storeFaces_) storeFace(cloud, td); hitFace(setF_*s, 0, cloud, td); @@ -156,8 +156,8 @@ bool Foam::sampledSetParticle::move if (onFace()) { - if (td.storeFaces_) storeFace(cloud, td); if (td.storeCells_) storeCell(cloud, td); + if (td.storeFaces_) storeFace(cloud, td); hitFace(setF_*s, 0, cloud, td); } From 2fc40b7895363747f6372207cbe6a99bfb056832 Mon Sep 17 00:00:00 2001 From: Will Bainbridge Date: Thu, 3 Feb 2022 15:47:37 +0000 Subject: [PATCH 2/2] multiphaseEulerFoam: blending: Skip coefficient evaluation for constant case --- .../blendingMethod/blendingMethod.C | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/applications/solvers/multiphase/multiphaseEulerFoam/phaseSystems/BlendedInterfacialModel/blendingMethods/blendingMethod/blendingMethod.C b/applications/solvers/multiphase/multiphaseEulerFoam/phaseSystems/BlendedInterfacialModel/blendingMethods/blendingMethod/blendingMethod.C index c635cc1bd1..8e942628b6 100644 --- a/applications/solvers/multiphase/multiphaseEulerFoam/phaseSystems/BlendedInterfacialModel/blendingMethods/blendingMethod/blendingMethod.C +++ b/applications/solvers/multiphase/multiphaseEulerFoam/phaseSystems/BlendedInterfacialModel/blendingMethods/blendingMethod/blendingMethod.C @@ -211,16 +211,19 @@ Foam::tmp Foam::blendingMethod::f { return constant(alphas, 0); } - else + + if (canBeContinuousPhaseSet == canBeContinuousSystemSet) { - return - fContinuous - ( - alphas, - canBeContinuousPhaseSet, - canBeContinuousSystemSet - ); + return constant(alphas, 1); } + + return + fContinuous + ( + alphas, + canBeContinuousPhaseSet, + canBeContinuousSystemSet + ); }