FreeFOAM The Cross-Platform CFD Toolkit
pEqn.H
Go to the documentation of this file.
1 rho = thermo.rho();
2 
4 U = invA & UEqn.H();
5 
7 {
9  (
10  "phid",
12  *(
13  (fvc::interpolate(U) & mesh.Sf())
14  + fvc::ddtPhiCorr(rUA, rho, U, phi)
15  )
16  );
17 
18  for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
19  {
20  fvScalarMatrix pEqn
21  (
22  betav*fvm::ddt(psi, p)
23  + fvm::div(phid, p)
25  );
26 
27  pEqn.solve();
28 
29  if (nonOrth == nNonOrthCorr)
30  {
31  phi == pEqn.flux();
32  }
33  }
34 }
35 else
36 {
37  phi =
39  (
40  (fvc::interpolate(U) & mesh.Sf())
41  + fvc::ddtPhiCorr(rUA, rho, U, phi)
42  );
43 
44  for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
45  {
46  fvScalarMatrix pEqn
47  (
48  betav*fvm::ddt(psi, p)
49  + fvc::div(phi)
51  );
52 
53  pEqn.solve();
54 
55  if (nonOrth == nNonOrthCorr)
56  {
57  phi += pEqn.flux();
58  }
59  }
60 }
61 
62 #include "rhoEqn.H"
64 
65 U -= invA & (betav*fvc::grad(p));
66 U.correctBoundaryConditions();
67 
69 
70 // ************************ vim: set sw=4 sts=4 et: ************************ //