This repository has been archived on 2023-11-20. You can view files and clone it, but cannot push or open issues or pull requests.
foam-extend4.1-coherent-io/applications/solvers/coupled/pUCoupledFoam/UEqn.H

26 lines
492 B
C++
Raw Normal View History

2016-03-18 11:44:28 +00:00
{
// Momentum equation
fvVectorMatrix UEqn
(
fvm::ddt(U)
+ fvm::div(phi, U)
+ turbulence->divDevReff()
2016-03-18 11:44:28 +00:00
);
2016-03-18 11:44:28 +00:00
rAU = 1.0/UEqn.A();
if (gMin(rAU) < 0)
{
WarningIn(args.executable())
<< "Negative rAU detected. Check mesh and discretisation"
<< endl;
}
// Under-relax momentum. Note this will destroy the H and A
2016-03-18 11:44:28 +00:00
UEqn.relax();
UpEqn.insertEquation(0, UEqn);
# include "addBlockCoupledBC.H"
2016-03-18 11:44:28 +00:00
}