Commit 898742e6 authored by henry's avatar henry
Browse files

Corrected the update of pd from p in closed-volume cases.

parent 1bc9eea3
......@@ -55,5 +55,6 @@ if (closedVolume)
{
p += (initialMass - fvc::domainIntegrate(thermo->psi()*p))
/fvc::domainIntegrate(thermo->psi());
pd == p - (rho*gh + pRef);
rho = thermo->rho();
}
volScalarField rUA = 1.0/UEqn().A();
U = rUA*UEqn().H();
UEqn.clear();
phi = fvc::interpolate(rho)*(fvc::interpolate(U) & mesh.Sf());
bool closedVolume = adjustPhi(phi, U, p);
phi -= fvc::interpolate(rho*gh*rUA)*fvc::snGrad(rho)*mesh.magSf();
......@@ -46,6 +47,7 @@ if (closedVolume)
{
p += (initialMass - fvc::domainIntegrate(thermo->psi()*p))
/fvc::domainIntegrate(thermo->psi());
pd == p - (rho*gh + pRef);
}
rho = thermo->rho();
......
......@@ -46,6 +46,7 @@ if (closedVolume)
{
p += (initialMass - fvc::domainIntegrate(thermo->psi()*p))
/fvc::domainIntegrate(thermo->psi());
pd == p - (rho*gh + pRef);
}
rho = thermo->rho();
......
......@@ -51,7 +51,7 @@
)
- fvc::domainIntegrate(thermof[i].psi()*thermof[i].p())
)/fvc::domainIntegrate(thermof[i].psi());
pdf[i] == thermof[i].p() - (rhof[i]*ghf[i] + pRef);
rhof[i] = thermof[i].rho();
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment