pEqn.H
Go to the documentation of this file.
1 {
3 
5  (
6  "phiHbyA",
7  (
9  + alphacf*rAUcf*fvc::ddtCorr(Uc, Ucf)
10  )
11  );
12 
13  if (p.needReference())
14  {
16  adjustPhi(phiHbyA, Uc, p);
18  }
19 
21 
22  // Update the pressure BCs to ensure flux consistency
24 
25  // Non-orthogonal pressure corrector loop
26  while (pimple.correctNonOrthogonal())
27  {
28  fvScalarMatrix pEqn
29  (
30  fvm::laplacian(alphacf*rAUcf, p)
31  ==
32  fvc::ddt(alphac) + fvc::div(alphacf*phiHbyA)
33  );
34 
35  pEqn.setReference(pRefCell, pRefValue);
36 
37  pEqn.solve(mesh.solver(p.select(pimple.finalInnerIter())));
38 
39  if (pimple.finalNonOrthogonalIter())
40  {
41  phic = phiHbyA - pEqn.flux()/alphacf;
42 
43  p.relax();
44 
45  Uc = HbyA
46  + rAUc
47  *fvc::reconstruct((phicForces - pEqn.flux()/alphacf)/rAUcf);
48  Uc.correctBoundaryConditions();
49 
50  {
51  Ucf = fvc::interpolate(Uc);
52  surfaceVectorField n(mesh.Sf()/mesh.magSf());
53  Ucf += n*(phic/mesh.magSf() - (n & Ucf));
54  }
55 
56  // Make the fluxes relative to the mesh motion
58  }
59  }
60 }
61 
62 #include "continuityErrs.H"
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:42
pimpleNoLoopControl & pimple
p
Definition: pEqn.H:50
phiHbyA
Definition: pEqn.H:20
tmp< GeometricField< Type, fvPatchField, volMesh > > div(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
Definition: fvcDiv.C:47
tmp< GeometricField< typename flux< Type >::type, fvsPatchField, surfaceMesh > > ddtCorr(const GeometricField< Type, fvPatchField, volMesh > &U, const GeometricField< Type, fvsPatchField, surfaceMesh > &Uf)
Definition: fvcDdt.C:170
GeometricField< vector, fvsPatchField, surfaceMesh > surfaceVectorField
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:55
tmp< GeometricField< Type, fvPatchField, volMesh > > laplacian(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
Definition: fvcLaplacian.C:45
tmp< GeometricField< Type, fvPatchField, volMesh > > ddt(const dimensioned< Type > dt, const fvMesh &mesh)
Definition: fvcDdt.C:45
surfaceScalarField rAUcf("Dp", fvc::interpolate(rAUc))
dynamicFvMesh & mesh
fvVectorMatrix UcEqn(fvm::ddt(alphac, Uc)+fvm::div(alphaPhic, Uc) - fvm::Sp(fvc::ddt(alphac)+fvc::div(alphaPhic), Uc)+continuousPhaseTurbulence->divDevRhoReff(Uc)==(1.0/rhoc) *cloudSU)
tmp< volVectorField > constrainHbyA(const tmp< volVectorField > &tHbyA, const volVectorField &U, const volScalarField &p)
Definition: constrainHbyA.C:33
adjustPhi(phiHbyA, U, p_rgh)
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.
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh >> reconstruct(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
surfaceScalarField phic(mixture.cAlpha() *mag(phi/mesh.magSf()))
volVectorField & HbyA
Definition: pEqn.H:13
label pRefCell
Definition: createFields.H:106
void makeAbsolute(surfaceScalarField &phi, const volVectorField &U)
Make the given flux absolute.
Definition: fvcMeshPhi.C:114
constrainPressure(p_rgh, rho, U, phiHbyA, rhorAUf, MRF)
volScalarField rAUc(1.0/UcEqn.A())
surfaceVectorField n(mesh.Sf()/mesh.magSf())
tmp< surfaceScalarField > flux(const volVectorField &vvf)
Return the face-flux field obtained from the given volVectorField.
Definition: fvcFlux.C:32
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
MRF makeRelative(fvc::interpolate(rho), phiHbyA)
surfaceScalarField phicForces(fvc::flux(rAUc *cloudVolSUSu/rhoc)+rAUcf *(g &mesh.Sf()))
scalar pRefValue
Definition: createFields.H:107