DAFoam
v4.0.2
Discrete Adjoint with OpenFOAM
dafoam
src
adjoint
DASolver
DAPimpleDyMFoam
UEqnPimpleDyM.H
Go to the documentation of this file.
1
// Solve the Momentum equation
2
3
if
(hasFvSource_)
4
{
5
// update the actuator source term
6
daFvSourcePtr_->calcFvSource(
fvSource
);
7
}
8
9
tmp<fvVectorMatrix>
tUEqn
(
10
fvm::ddt(
U
)
11
+ fvm::div(
phi
,
U
)
12
+ turbulencePtr_->divDevReff(
U
)
13
-
fvSource
);
14
15
fvVectorMatrix&
UEqn
=
tUEqn
.ref();
16
17
UEqn
.relax();
18
19
if
(
pimple
.momentumPredictor())
20
{
21
// get the solver performance info such as initial
22
// and final residuals
23
SolverPerformance<vector>
solverU
=
solve
(
UEqn
== -fvc::grad(
p
));
24
25
DAUtility::primalResidualControl(
solverU
, pimplePrintToScreen,
"U"
, daGlobalVarPtr_->primalMaxRes);
26
}
27
28
// bound U
29
DAUtility::boundVar(
allOptions
,
U
, pimplePrintToScreen);
U
volVectorField & U
Definition:
createRefsPimpleDyM.H:7
pimple
pimpleControlDF & pimple
Definition:
createRefsPimpleDyM.H:5
solve
nuTilda1Eqn solve(solverDictNuTilda)
solverU
SolverPerformance< vector > solverU
Definition:
UEqnRhoPimple.H:19
UEqn
fvVectorMatrix & UEqn
Definition:
UEqnPimpleDyM.H:15
fvSource
volScalarField & fvSource
Definition:
createRefsHeatTransfer.H:7
p
volScalarField & p
Definition:
createRefsPimpleDyM.H:6
phi
surfaceScalarField & phi
Definition:
createRefsPimpleDyM.H:8
tUEqn
tmp< fvVectorMatrix > tUEqn(fvm::ddt(U)+fvm::div(phi, U)+turbulencePtr_->divDevReff(U) - fvSource)
allOptions
const dictionary & allOptions
Definition:
createRefsPimpleDyM.H:14
Generated by
1.8.17