pEqn.H
Go to the documentation of this file.
1{
3
4 surfaceScalarField phiHbyA
5 (
6 "phiHbyA",
7 fvc::flux(HbyA)
8 + alphacf*fvc::interpolate(rho*rAUc)*fvc::ddtCorr(U, phi)
9 );
10
11 MRF.makeRelative(phiHbyA);
13
14 surfaceScalarField phig
15 (
17 (
18 fvc::interpolate(mixture.sigmaK())*fvc::snGrad(alpha1)
19 - ghf*fvc::snGrad(rho)
20 )*rAUcf*mesh.magSf()
21 );
22
24
25 // Update the pressure BCs to ensure flux consistency
27
28 while (pimple.correctNonOrthogonal())
29 {
30 surfaceScalarField Dp("Dp", alphacf*rAUcf);
31
32 fvScalarMatrix p_rghEqn
33 (
34 fvm::laplacian(Dp, p_rgh)
35 ==
36 fvc::ddt(alphac) + fvc::div(alphacf*phiHbyA)
37 );
38
39 p_rghEqn.setReference(pRefCell, getRefCellValue(p_rgh, pRefCell));
40
41 p_rghEqn.solve(mesh.solver(p_rgh.select(pimple.finalInnerIter())));
42
43 if (pimple.finalNonOrthogonalIter())
44 {
45 phi = phiHbyA - p_rghEqn.flux()/alphacf;
46
47 p_rgh.relax();
48
49 U =
50 HbyA
51 + rAUc*fvc::reconstruct((phig - p_rghEqn.flux()/alphacf)/rAUcf);
52
53 U.correctBoundaryConditions();
54
55 fvOptions.correct(U);
56 }
57 }
58
59 #include "continuityErrs.H"
60
61 p == p_rgh + rho*gh;
62
63 if (p_rgh.needReference())
64 {
65 p += dimensionedScalar
66 (
67 "p",
68 p.dimensions(),
69 pRefValue - getRefCellValue(p, pRefCell)
70 );
71 p_rgh = p - rho*gh;
72 }
73}
surfaceScalarField rAUcf("Dp", fvc::interpolate(rAUc))
volScalarField rAUc(1.0/UcEqn.A())
surfaceScalarField phicForces(fvc::flux(rAUc *cloudVolSUSu/rhoc)+rAUcf *(g &mesh.Sf()))
volScalarField & p_rgh
fv::options & fvOptions
surfaceScalarField & phi
const scalar pRefValue
const surfaceScalarField & ghf
const label pRefCell
IOMRFZoneList & MRF
const volScalarField & gh
pimpleControl & pimple
const volScalarField & alpha1
U
Definition: pEqn.H:72
volScalarField & p
surfaceScalarField phig("phig", -rhorAUf *ghf *fvc::snGrad(rho) *mesh.magSf())
fvVectorMatrix & UEqn
Definition: UEqn.H:13
phiHbyA
Definition: pcEqn.H:73
HbyA
Definition: pcEqn.H:74
dynamicFvMesh & mesh
adjustPhi(phiHbyA, U, p_rgh)
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:83
Info<< "Creating temperaturePhaseChangeTwoPhaseMixture\n"<< endl;autoPtr< temperaturePhaseChangeTwoPhaseMixture > mixture
Definition: createFields.H:39
Calculates and prints the continuity errors.