pEqn.H
Go to the documentation of this file.
1 {
2  volVectorField HbyA("HbyA", Uc);
3  HbyA = rAUc*UcEqn.H();
4 
6  (
7  "phiHbyA",
8  (
10  + alphacf*rAUcf*fvc::ddtCorr(Uc, phic)
11  + phicForces
12  )
13  );
14 
15  // Update the pressure BCs to ensure flux consistency
17 
18  // Non-orthogonal pressure corrector loop
19  while (pimple.correctNonOrthogonal())
20  {
21  fvScalarMatrix pEqn
22  (
23  fvm::laplacian(alphacf*rAUcf, p)
24  ==
25  fvc::ddt(alphac) + fvc::div(alphacf*phiHbyA)
26  );
27 
28  pEqn.setReference(pRefCell, pRefValue);
29 
30  pEqn.solve(mesh.solver(p.select(pimple.finalInnerIter())));
31 
32  if (pimple.finalNonOrthogonalIter())
33  {
34  phic = phiHbyA - pEqn.flux()/alphacf;
35 
36  p.relax();
37 
38  Uc = HbyA
39  + rAUc*fvc::reconstruct((phicForces - pEqn.flux()/alphacf)/rAUcf);
40  Uc.correctBoundaryConditions();
41  }
42  }
43 }
44 
45 #include "continuityErrs.H"
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:42
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:155
const dictionary & pimple
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
Calculates and prints the continuity errors.
constrainPressure(p, rho, U, phiHbyA, rhorAUf, MRF)
const scalar pRefValue
const label pRefCell
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh >> reconstruct(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
volVectorField & HbyA
Definition: pEqn.H:13
volScalarField rAUc(1.0/UcEqn.A())
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< 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()))