pEqn.H
Go to the documentation of this file.
1 {
3 
5  (
6  "phiHbyA",
7  (
9  + alphacf*rAUcf*fvc::ddtCorr(Uc, phic)
10  )
11  );
12 
13  if (p.needReference())
14  {
15  adjustPhi(phiHbyA, Uc, p);
16  }
17 
19 
20  // Update the pressure BCs to ensure flux consistency
22 
23  // Non-orthogonal pressure corrector loop
24  while (pimple.correctNonOrthogonal())
25  {
26  fvScalarMatrix pEqn
27  (
28  fvm::laplacian(alphacf*rAUcf, p)
29  ==
30  fvc::ddt(alphac) + fvc::div(alphacf*phiHbyA)
31  );
32 
33  pEqn.setReference(pRefCell, pRefValue);
34 
35  pEqn.solve(mesh.solver(p.select(pimple.finalInnerIter())));
36 
37  if (pimple.finalNonOrthogonalIter())
38  {
39  phic = phiHbyA - pEqn.flux()/alphacf;
40 
41  p.relax();
42 
43  Uc = HbyA
44  + rAUc*fvc::reconstruct((phicForces - pEqn.flux()/alphacf)/rAUcf);
45  Uc.correctBoundaryConditions();
46  }
47  }
48 }
49 
50 #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, 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
Calculates and prints the continuity errors.
adjustPhi(phiHbyA, U, p_rgh)
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
constrainPressure(p_rgh, rho, U, phiHbyA, rhorAUf, MRF)
volScalarField rAUc(1.0/UcEqn.A())
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
surfaceScalarField phicForces(fvc::flux(rAUc *cloudVolSUSu/rhoc)+rAUcf *(g &mesh.Sf()))
scalar pRefValue
Definition: createFields.H:107