pEqn.H
Go to the documentation of this file.
1 {
3  volVectorField HbyA("HbyA", Urel);
5 
8 
9  tmp<volScalarField> rAtUrel(rAUrel);
10 
11  if (simple.consistent())
12  {
13  rAtUrel = 1.0/(1.0/rAUrel - UrelEqn.H1());
14  phiHbyA +=
16  HbyA -= (rAUrel - rAtUrel())*fvc::grad(p);
17  }
18 
19  tUrelEqn.clear();
20 
21  // Update the pressure BCs to ensure flux consistency
23 
24  // Non-orthogonal pressure corrector loop
25  while (simple.correctNonOrthogonal())
26  {
27  fvScalarMatrix pEqn
28  (
30  );
31 
32  pEqn.setReference(pRefCell, pRefValue);
33 
34  pEqn.solve();
35 
36  if (simple.finalNonOrthogonalIter())
37  {
38  phi = phiHbyA - pEqn.flux();
39  }
40  }
41 
42  #include "continuityErrs.H"
43 
44  // Explicitly relax pressure for momentum corrector
45  p.relax();
46 
47  // Momentum corrector
49  Urel.correctBoundaryConditions();
50  fvOptions.correct(Urel);
51 }
fvVectorMatrix & UrelEqn
Definition: UrelEqn.H:11
fvMatrix< scalar > fvScalarMatrix
Definition: fvMatricesFwd.H:37
p
Definition: pEqn.H:50
phiHbyA
Definition: pEqn.H:20
volScalarField rAUrel(1.0/UrelEqn.A())
tmp< surfaceScalarField > flux(const volVectorField &vvf)
Return the face-flux field obtained from the given volVectorField.
tmp< GeometricField< Type, faPatchField, areaMesh > > div(const GeometricField< Type, faePatchField, edgeMesh > &ssf)
Definition: facDiv.C:43
tmp< volScalarField > rAtUrel(rAUrel)
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:82
fv::options & fvOptions
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:81
dynamicFvMesh & mesh
tmp< GeometricField< Type, faPatchField, areaMesh > > laplacian(const GeometricField< Type, faPatchField, areaMesh > &vf, const word &name)
Definition: facLaplacian.C:40
HbyA
Definition: pEqn.H:4
Urel
Definition: pEqn.H:56
tmp< fvVectorMatrix > tUrelEqn(fvm::ddt(Urel)+fvm::div(phi, Urel)+turbulence->divDevReff(Urel)+SRF->Su()==fvOptions(Urel))
adjustPhi(phiHbyA, U, p_rgh)
const scalar pRefValue
const label pRefCell
const dictionary & simple
mesh interpolate(rAU)
constrainPressure(p_rgh, rho, U, phiHbyA, rhorAUf, MRF)
phi
Definition: pEqn.H:18
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > snGrad(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
Definition: fvcSnGrad.C:40
tmp< GeometricField< typename outerProduct< vector, Type >::type, faPatchField, areaMesh >> grad(const GeometricField< Type, faePatchField, edgeMesh > &ssf)
Definition: facGrad.C:51