pEqn.H
Go to the documentation of this file.
1 volScalarField rAUrel(1.0/UrelEqn().A());
2 volVectorField HbyA("HbyA", Urel);
3 HbyA = rAUrel*UrelEqn().H();
4 
6 (
7  "phiHbyA",
8  (fvc::interpolate(HbyA) & mesh.Sf())
10 );
11 
13 
14 tmp<volScalarField> rAtUrel(rAUrel);
15 
16 if (pimple.consistent())
17 {
18  rAtUrel = 1.0/max(1.0/rAUrel - UrelEqn().H1(), 0.1/rAUrel);
19  phiHbyA +=
21  HbyA -= (rAUrel - rAtUrel())*fvc::grad(p);
22 }
23 
24 if (pimple.nCorrPISO() <= 1)
25 {
26  UrelEqn.clear();
27 }
28 
29 // Non-orthogonal pressure corrector loop
30 while (pimple.correctNonOrthogonal())
31 {
32  // Pressure corrector
33  fvScalarMatrix pEqn
34  (
36  );
37 
38  pEqn.setReference(pRefCell, pRefValue);
39 
40  pEqn.solve(mesh.solver(p.select(pimple.finalInnerIter())));
41 
42  if (pimple.finalNonOrthogonalIter())
43  {
44  phi = phiHbyA - pEqn.flux();
45  }
46 }
47 
48 #include "continuityErrs.H"
49 
50 p.relax();
51 
52 // Momentum corrector
54 Urel.correctBoundaryConditions();
55 fvOptions.correct(Urel);
phi
Definition: pEqn.H:20
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
Urel
Definition: pEqn.H:53
tmp< GeometricField< Type, fvPatchField, volMesh > > laplacian(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
Definition: fvcLaplacian.C:45
tmp< surfaceScalarField > interpolate(const RhoType &rho)
dynamicFvMesh & mesh
const dictionary & pimple
p
Definition: pEqn.H:59
fv::IOoptionList & fvOptions
const scalar pRefValue
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:42
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:52
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
volScalarField rAUrel(1.0/UrelEqn().A())
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
phiHbyA
Definition: pEqn.H:21
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > snGrad(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
Definition: fvcSnGrad.C:45
tmp< volScalarField > rAtUrel(rAUrel)
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:55
adjustPhi(phiHbyA, U, p_rgh)
const label pRefCell
tmp< GeometricField< Type, fvPatchField, volMesh > > div(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
Definition: fvcDiv.C:47
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh >> grad(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
Definition: fvcGrad.C:52
HbyA
Definition: pEqn.H:7
tmp< fvVectorMatrix > UrelEqn(fvm::ddt(Urel)+fvm::div(phi, Urel)+turbulence->divDevReff(Urel)+SRF->Su()==fvOptions(Urel))