DPMDyMFoam, DPMDyMFoam: Corrected support for closed-domain simulations

Also added support for extrapolated pressure boundary conditions.
This commit is contained in:
Henry Weller
2017-05-04 09:39:23 +01:00
parent 7863708489
commit d26c6c342b
2 changed files with 11 additions and 6 deletions

View File

@ -1,6 +1,5 @@
{
volVectorField HbyA("HbyA", Uc);
HbyA = rAUc*UcEqn.H();
volVectorField HbyA(constrainHbyA(rAUc*UcEqn.H(), Uc, p));
surfaceScalarField phiHbyA
(
@ -8,7 +7,6 @@
(
fvc::flux(HbyA)
+ alphacf*rAUcf*fvc::ddtCorr(Uc, Ucf)
+ phicForces
)
);
@ -19,6 +17,8 @@
fvc::makeAbsolute(phiHbyA, Uc);
}
phiHbyA += phicForces;
// Update the pressure BCs to ensure flux consistency
constrainPressure(p, Uc, phiHbyA, rAUcf);

View File

@ -1,6 +1,5 @@
{
volVectorField HbyA("HbyA", Uc);
HbyA = rAUc*UcEqn.H();
volVectorField HbyA(constrainHbyA(rAUc*UcEqn.H(), Uc, p));
surfaceScalarField phiHbyA
(
@ -8,10 +7,16 @@
(
fvc::flux(HbyA)
+ alphacf*rAUcf*fvc::ddtCorr(Uc, phic)
+ phicForces
)
);
if (p.needReference())
{
adjustPhi(phiHbyA, Uc, p);
}
phiHbyA += phicForces;
// Update the pressure BCs to ensure flux consistency
constrainPressure(p, Uc, phiHbyA, rAUcf);