18 IOobject::groupName(
"rAU", phase.name()),
22 +
max(phase.residualAlpha() -
alpha, scalar(0))
23 *phase.rho()/runTime.deltaT()
40 autoPtr<PtrList<volVectorField>> Fs =
fluid.Fs();
53 IOobject::groupName(
"phiF", phase.name()),
61 autoPtr<PtrList<surfaceScalarField>> phiDs =
fluid.phiDs(
rAUs);
80 IOobject::groupName(
"phiF", phase.name()),
105 MRF.correctBoundaryFlux(phase.U(), phase.phi());
112 IOobject::groupName(
"HbyA", phase.name()),
121 +
max(phase.residualAlpha() -
alpha, scalar(0))
122 *phase.rho()*phase.U().oldTime()/runTime.deltaT()
132 PtrList<surfaceScalarField> phigFs(
phases.size());
145 -
fluid.surfaceTension(phase)*
mesh.magSf()
184 surfaceScalarField::Boundary& phiCorrCoeffBf =
185 phiCorrCoeff.boundaryFieldRef();
193 || isA<cyclicAMIFvPatch>(
mesh.boundary()[
patchi])
196 phiCorrCoeffBf[
patchi] = 0;
205 IOobject::groupName(
"phiHbyA", phase.name()),
213 MRF.absolute(phase.phi().oldTime())
222 phaseSystem::KdTable,
229 const phasePair& pair(
fluid.phasePairs()[KdIter.key()]);
231 const phaseModel*
phase1 = &pair.phase1();
232 const phaseModel*
phase2 = &pair.phase2();
236 if (phase1 == &phase)
240 *
MRF.absolute(phase2->phi());
245 Swap(phase1, phase2);
276 surfaceScalarField::Boundary
phib(
phi.boundaryField());
281 phib +=
alphafs[
phasei].boundaryField()*phase.phi().boundaryField();
286 p_rgh.boundaryFieldRef(),
289 )/(
mesh.magSf().boundaryField()*rAUf.boundaryField())
293 PtrList<fvScalarMatrix> pEqnComps(
phases.size());
300 if (phase.compressible())
306 IOobject::groupName(
"phid", phase.name()),
315 phase.continuityError()
326 phase.thermo().psi()*
fvm::ddt(p_rgh)
336 pEqnComps[
phasei].faceFluxCorrectionPtr()
338 pEqnComps[
phasei].relax();
347 phase.continuityError()
354 + (alpha*phase.thermo().psi()/
rho)
369 if (
fluid.transfersMass(phase))
371 if (pEqnComps.set(
phasei))
390 while (
pimple.correctNonOrthogonal())
404 if (pEqnComps.set(
phasei))
406 pEqn += pEqnComps[
phasei];
413 mesh.solver(p_rgh.select(
pimple.finalInnerIter()))
418 if (
pimple.finalNonOrthogonalIter())
431 if (pEqnComps.set(
phasei))
433 phase.divU(-pEqnComps[
phasei] & p_rgh);
440 mSfGradp = pEqnIncomp.flux()/
rAUf;
453 phase.U().correctBoundaryConditions();
469 phase.thermo().rho() += phase.thermo().psi()*(p_rgh -
p_rgh_0);
475 p_rgh.correctBoundaryConditions();
tmp< fvMatrix< Type > > correction(const fvMatrix< Type > &)
Return the correction form of the given matrix.
fvMatrix< scalar > fvScalarMatrix
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
multiphaseSystem::phaseModelList & phases
tmp< GeometricField< Type, fvPatchField, volMesh > > div(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
const dictionary & pimple
GeometricField< vector, fvPatchField, volMesh > volVectorField
tmp< GeometricField< Type, fvPatchField, volMesh > > laplacian(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
const surfaceScalarField & ghf
tmp< GeometricField< Type, fvPatchField, volMesh > > ddt(const dimensioned< Type > dt, const fvMesh &mesh)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
PtrList< volScalarField > rAUs(fluid.phases().size())
PtrList< surfaceScalarField > alpharAUfs(phases.size())
forAllConstIter(PtrDictionary< phaseModel >, mixture.phases(), phase)
dimensionedScalar pos0(const dimensionedScalar &ds)
const dimensionedVector & g
dimensionedScalar pMin("pMin", dimPressure, fluid)
word name(const complex &)
Return a string representation of a complex.
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
PtrList< volVectorField > HbyAs(fluid.phases().size())
surfaceScalarField phid("phid", fvc::interpolate(psi) *(fvc::flux(HbyA)+rhorAUf *fvc::ddtCorr(rho, U, phi)/fvc::interpolate(rho)))
PtrList< surfaceScalarField > alphafs(phases.size())
surfaceScalarField rAUf("rAUf", fvc::interpolate(rAU))
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh >> reconstruct(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
surfaceScalarField ghSnGradRho(ghf *fvc::snGrad(rho) *mesh.magSf())
PtrList< fvVectorMatrix > UEqns(fluid.phases().size())
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
setSnGrad< fixedFluxPressureFvPatchScalarField >(p_rgh.boundaryFieldRef(),(phiHbyA.boundaryField() - MRF.relative(phib))/(mesh.magSf().boundaryField() *rAUf.boundaryField()))
const volScalarField & gh
volScalarField p_rgh_0(p_rgh)
PtrList< surfaceScalarField > phiHbyAs(fluid.phases().size())
tmp< GeometricField< Type, fvPatchField, volMesh > > average(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
Area-weighted average a surfaceField creating a volField.
dimensioned< scalar > mag(const dimensioned< Type > &)
tmp< surfaceScalarField > flux(const volVectorField &vvf)
Return the face-flux field obtained from the given volVectorField.
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
const dimensionedScalar alpha
Fine-structure constant: default SI units: [].
void deleteDemandDrivenData(DataPtr &dataPtr)
PtrList< surfaceScalarField > phiFs(phases.size())
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > snGrad(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
const dimensionSet dimArea(sqr(dimLength))
const dimensionSet dimVelocity