From e0912a058cb68b0538ef6af6342a98ab1a331b81 Mon Sep 17 00:00:00 2001 From: sergio Date: Fri, 18 May 2018 01:27:13 -0700 Subject: [PATCH] ENH: Adding pressure work terms for compressibleInterFoam Removing temporary fix from compressibleInterDyFOAM to re-calculte Uf with morphing mesh --- .../solvers/multiphase/compressibleInterFoam/TEqn.H | 11 +++++------ .../compressibleInterDyMFoam.C | 6 +----- 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/applications/solvers/multiphase/compressibleInterFoam/TEqn.H b/applications/solvers/multiphase/compressibleInterFoam/TEqn.H index 26f046545e..1561ae35cc 100644 --- a/applications/solvers/multiphase/compressibleInterFoam/TEqn.H +++ b/applications/solvers/multiphase/compressibleInterFoam/TEqn.H @@ -1,16 +1,15 @@ { fvScalarMatrix TEqn ( - fvm::ddt(rho, T) + fvm::div(rhoPhi, T) - - fvm::Sp(contErr, T) + fvm::ddt(rho, T) + fvm::div(rhoPhi, T) - fvm::Sp(contErr, T) - fvm::laplacian(turbulence.alphaEff(), T) + ( - divU*p - + fvc::ddt(rho, K) + fvc::div(rhoPhi, K) + (divU*p)() - contErr/rho*p + + (fvc::ddt(rho, K) + fvc::div(rhoPhi, K))() - contErr*K ) *( - alpha1/mixture.thermo1().Cv() - + alpha2/mixture.thermo2().Cv() + alpha1()/mixture.thermo1().Cv()() + + alpha2()/mixture.thermo2().Cv()() ) == fvOptions(rho, T) diff --git a/applications/solvers/multiphase/compressibleInterFoam/compressibleInterDyMFoam/compressibleInterDyMFoam.C b/applications/solvers/multiphase/compressibleInterFoam/compressibleInterDyMFoam/compressibleInterDyMFoam.C index 8d3d5a2702..816c495443 100644 --- a/applications/solvers/multiphase/compressibleInterFoam/compressibleInterDyMFoam/compressibleInterDyMFoam.C +++ b/applications/solvers/multiphase/compressibleInterFoam/compressibleInterDyMFoam/compressibleInterDyMFoam.C @@ -119,12 +119,8 @@ int main(int argc, char *argv[]) ghf = (g & mesh.Cf()) - ghRef; } - if ((mesh.changing() && correctPhi) || mesh.topoChanging()) + if ((mesh.changing() && correctPhi)) { - // Calculate absolute flux from the mapped surface velocity - // Note: temporary fix until mapped Uf is assessed - Uf = fvc::interpolate(U); - // Calculate absolute flux from the mapped surface velocity phi = mesh.Sf() & Uf;